Hello Rich,

Thanx for the reply.
But i should have cheked my code better.
The piece of code was stuck in a for loop that's
why the ',' was removed from every slideimages[$x].

$string = substr($string,1); works great though..:)

grtz,
Thijs

-----Oorspronkelijk bericht-----
Van: Rich Gray [mailto:[EMAIL PROTECTED]
Verzonden: vrijdag 28 maart 2003 12:39
Aan: Thijs Lensselink; [EMAIL PROTECTED]
Onderwerp: RE: [PHP] string replace problem!!


> Good day ,
> 
> I have the following string.
> ,slideimages[0],slideimages[1],slideimages[2]
> Wich starts with a ','. No my problem is i want to strip
> this first and only the first ','.
> 
> i've tried 
> $string = ",slideimages[0],slideimages[1],slideimages[2]";
> $string = preg_replace('/^./','',$string,1);
> 
> wich results in slideimages[0]slideimages[1]slideimages[2]
> Can somebody help me out here??
> 
> thnx
> Thijs

$string = substr($string,1);

Rich

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to