Re: chop x amount of characters from the begining of a string
| From: | Jochem Maas | Date: | Wed, 03 May 2006 12:44:59 +0000 |
| Subject: | Re: chop x amount of characters from the begining of a string | ||
| References: | 1 2 3 4 5 6 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-235355@lists.php.net to get a copy of this message | ||
Richard Lynch wrote:
On Tue, May 2, 2006 3:44 pm, Wolf wrote:<muppet-comment> nah - if you really too much time you would have mimplemented some kind of interface that takes batch input from a cheap-ass laborer on the other side of the planet who sits there flipping a british fifty pence coin aqnd logging the result. (everyone knows 50p's are the most statically fair as far as coins are concerned). </muppet-comment> :-PSomeone has way too much time on his hands... :)If they REALLY had too much time on their hands, they'd have rtfm and used mt_rand() instead. :-)
Rory Browne wrote:function chop_two_or_3_characters_from_front_of_string($str){ $cut = rand(2, 3); return substr($str, $cut); } On 5/2/06, Jochem Maas <jochem@iamjochem.com> wrote:-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.phpBrad Bonkoski wrote:Perhaps this will work.. http://www.php.net/manual/en/function.substr.phpit's a long shot brad ;-)Ross wrote:fromI have a word say 'example' I want to chop of two or 3 chactersdo this?the front to leave 'ample' or 'mple'. Is there a php function to-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.phpRoss