Current Location: Home> Function Categories> strval

strval

Get the string value of the variable
Name:strval
Category:Variable processing
Programming Language:php
One-line Description:Returns the string value of the variable.

Definition and usage

strval() function returns the string value of the variable.

Example

Returns string values ​​for different variables:

 <?php
$a = "Hello" ;
echo strval ( $a ) . "<br>" ;

$b = "1234.56789" ;
echo strval ( $b ) . "<br>" ;

$c = "1234.56789Hello" ;
echo strval ( $c ) . "<br>" ;

$d = "Hello1234.56789" ;
echo strval ( $d ) . "<br>" ;

$e = 1234 ;
echo strval ( $e ) . "<br>" ;
?>

Try it yourself

grammar

 strval ( variable ) ;
parameter describe
variable Required. Specifies the variable to check.
Similar Functions