string substr ( string string, int start [, int length] )
$str= "Hello, how are you today? I am fine!";
if (strlen ($str) >= 30){
echo substr ($str,0,29);
} else {
echo $str;
}
More......
$str= "Hello, how are you today? I am fine!";
if (strlen ($str) >= 30){
echo substr ($str,0,29);
} else {
echo $str;
}
More......
Comments
Post a Comment