note 105046 added to function.ltrim
| From: | dzek dot remove_this at dzek dot eu | Date: | Mon, 25 Jul 2011 08:27:23 +0000 |
| Subject: | note 105046 added to function.ltrim | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-181818@lists.php.net to get a copy of this message | ||
Guys, if += 0 is producing wrong values sometimes, and preg_replace is cpu consuming, then just
stick to the main function described on that page, and use:
<?php
$value = ltrim($value, '0');
?>
should be the fastest and most reliable.
I think all those comments can be misleading for begginers checking this page - it's sort of
using magic tricks to reinvent the wheel.
----
Server IP: 69.147.83.197
Probable Submitter: 83.26.241.153
----
Manual Page -- http://www.php.net/manual/en/function.ltrim.php
Edit -- https://master.php.net/note/edit/105046
Del: integrated -- https://master.php.net/note/delete/105046/integrated
Del: useless -- https://master.php.net/note/delete/105046/useless
Del: bad code -- https://master.php.net/note/delete/105046/bad+code
Del: spam -- https://master.php.net/note/delete/105046/spam
Del: non-english -- https://master.php.net/note/delete/105046/non-english
Del: in docs -- https://master.php.net/note/delete/105046/in+docs
Del: other reasons-- https://master.php.net/note/delete/105046
Reject -- https://master.php.net/note/reject/105046
Search -- https://master.php.net/manage/user-notes.php