Remove First Character From A String in PHP
remove first letter php
<?php
echo substr('abcdef', 1); // bcdef
?>
Output
bcdef
cut the first character in php
$str = '::f:o:';
$str = ltrim($str, ':');
var_dump($str);
Output
'f:o:'
<?php
echo substr('abcdef', 1); // bcdef
?>
$str = '::f:o:';
$str = ltrim($str, ':');
var_dump($str);
In this page (written and validated by A. Gawali) you learned about . What's Next? If you are interested in completing PHP tutorial, we encourage you simply to start here: PHP Tutorial.
Share On: |