Re: Strange string stuff -- maybe everything is ending...
| From: | Stefan Wixfort | Date: | Sun, 23 Dec 2012 03:29:02 +0000 |
| Subject: | Re: Strange string stuff -- maybe everything is ending... | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-319946@lists.php.net to get a copy of this message | ||
On 22.12.2012 00:31, Bastien wrote:
On 2012-12-21, at 5:05 PM, Ken Robinson <kenrbnsn@rbnsn.com> wrote:Yes, it should be implode(). StefanA much easier way to do this would be to use a temporary array and then explode: $tmp = array();Shouldn't that be implode to convert the array to string with the delimiter? Bastienwhile($row = mysql_fetch_array($result)) // pulling stuff from a database { $tmp[] = $row['category']; }$topic = explode('~',$tmp); // put the delimiter between each entry echo($topic); // this result is used in an AJAX script