note 18176 deleted from ref.strings by irc-html

From: Date: Sun, 13 Jan 2002 02:58:12 +0000
Subject: note 18176 deleted from ref.strings by irc-html
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-24766@lists.php.net to get a copy of this message
A simple function to reverse the order of a string follows: function str_rev($str){ for ($x = strlen($str) - 1; $x >= 0; --$x) { $reversestr .= $str[$x]; } return ($reversestr); } When called as print str_rev(1234567890); prints out 0987654321

« previous php.notes (#24766) next »