Page 1 of 1
help for html spaces..
Posted: Mon Aug 11, 2003 1:45 pm
by BRk
Does anyone know a function or other way in php to display strings with spaces and line returns,in html code ?¿
thAnkS!

Posted: Mon Aug 11, 2003 11:07 pm
by trollll
Well, for line breaks you should check out
this function in the php manual. You may want to just
bookmark the manual, I did the first time I saw it and use it at
least daily.
thanks !
Posted: Mon Aug 11, 2003 11:29 pm
by BRk
I just bookmart it ! thanks! U just save me from doing stupid and hard work, the thing is do you have a way of doing the same thing but with spaces ??
If not , thanks anyway..

ThAnKs trollll !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Posted: Mon Aug 18, 2003 3:31 am
by derek
1)If you talk about HTML then you can use <br> tag
2) And in PHP you can use nl2br() to inserts a break. But remember don't use nl2br() if you want to save data in a database.
Posted: Mon Aug 18, 2003 4:54 am
by Wayne
for the spaces ....
str_replace(" " , " ", $str);
Posted: Mon Aug 18, 2003 8:55 am
by m3rajk
trollll wrote:Well, for line breaks you should check out
this function in the php manual. You may want to just
bookmark the manual, I did the first time I saw it and use it at
least daily.
php.net is the first place i went when wnating php. bookmarked that and find it the best ref when trying to find a function and found this place through them. it's beent he best with getting help