Answers for "how to remove text at the last of php"

PHP
27

php remove last character in string

//Remove the last character using substr
$string = substr($string, 0, -1);
Posted by: Guest on April-02-2020
1

php remove last character from string

$newarraynama = rtrim($arraynama, ", ");
Posted by: Guest on September-23-2021

Code answers related to "how to remove text at the last of php"

Browse Popular Code Answers by Language