Question:Why substr() is used?
Answer Ans: The substr() function is used to return the part of a string located between a predefined starting offset and length position.
Its prototype follows:
string substr(string str, int start [, int length])
+ Report
Why substr() is used?