Re: php solution to html problem

From: Date: Thu, 25 Aug 2005 08:32:19 +0000
Subject: Re: php solution to html problem
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-221335@lists.php.net to get a copy of this message
Richard Lynch wrote:
PHP's wordwrap function may have an optional argument to FORCE it to never be wider than X characters, but I don't think so...
http://www.php.net/wordwrap string wordwrap (string str [, int width [, string break [, bool cut]]]) "If the cut is set to 1, the string is always wrapped at the specified width. So if you have a word that is larger than the given width, it is broken apart. (See second example)." Example: $string = wordwrap($string, 30, '<br>', true); Jasper

« previous php.general (#221335) next »