Home >>PHP String Functions >PHP hebrev() Function

PHP hebrev() Function

PHP hebrev() Function

PHP hebrev() function is used to reverse any given Hebrew Text. Hebrew text is read from right-to-left, that means by using this hebrev() function in PHP we make the text read from left-to-right. We can also sat that using this hebrev() function we convert the given logical Herrew text to the resultant visual test.

The function move the full-stop from the left end of the sentence(in Hebrew) to the right end of the sentence. We can also say that the hebrev() function changes the flow of the Hebrew text from a right-to-left flow to a left-to-right flow.

Syntax

hebrev($string, $maxcharline);

$string is the given input Hebrew text that will be reversed by the function and the $maxcharline is an optional parameter that defines the maximum number of characters that can be returned in each line.

Here is an example of hebrev() function in PHP :

<html>
<body>

<?php
echo hebrev("Some example Hebrew text here.");
?>

</body>
</html>
Output:
.Some example Hebrew text here

Example 2

<html>
<body>

<?php
echo hebrev("á çùåï äúùñâ.");
?>

</body>
</html>
Output:
.âñùúä ïåùç á

Popular Tutorials