Introduction
In this article I describe the PHP string functions quotemeta, rtrim and setlocal. To learn some other math functions, go to:
- String Functions in PHP: Part1
- String Functions in PHP:Part2
- String Functions in PHP:Part3
- String Functions in PHP:Part4
- String Functions in PHP:Part5
- String Functions in PHP:Part6
- String Functions in PHP:Part7
- String Functions in PHP:Part8
- String Functions in PHP:Part9
- String Functions in PHP:Part10
- String Functions in PHP:Part11
- String Functions in PHP:Part12
PHP quotemeta() Function
The PHP string quotemeta() function returns the string with meta characters quoted or say it adds backslashes in front of some predefined characters in a string.
Syntax
| quotemeta(string) |
Parameter in quotemeta Function
The parameters of the quotemeta function is:
| Parameter | Description |
| strings | It specifies the string to check. |
Example
An example of the quotemeta function is:
<?php
$str = "Mcn Solution. (PVT LTD)";
echo quotemeta($str);
?>
Output
PHP rtrim() Function
The PHP rtrim function will remove whitespace or other characters from the end of the string.
Syntax
| rtrim(string,charlist) |
Parameter in rtrim Function
The parameters of the rtrim function are:




Join the conversation! Your thoughts help the community grow.