Tools, FAQ, Tutorials:
Removing Leading and Trailing Spaces in PHP
How To Remove Leading and Trailing Spaces from User Input Values?
✍: FYIcenter.com
If you are taking input values from users with a Web form, users may enter extra spaces at the beginning and/or the end of the input values. You should always use the trim() function to remove those extra spaces as shown in this PHP script:
<?php
$name = $_REQUEST("name");
$name = trim($name);
# $name is ready to be used...
?>
⇐ Remove Trailing New Line Character in PHP
2016-10-13, ∼3380🔥, 0💬
Popular Posts:
How to use "link" command tool to link objet files? If you have object files previously compiled by ...
Where to find tutorials on OpenID? Here is a large collection of tutorials to answer many frequently...
What are "*..." and "**..." Wildcard Parameters in Function Definitions? If you want to define a fun...
How to login to Azure API Management Publisher Dashboard? If you have given access permission to an ...
How to add an API to an API product for internal testing on the Publisher Portal of an Azure API Man...