Welcome to collectivesolver - Programming & Software Q&A with code examples. A website with trusted programming answers. All programs are tested and work.

Contact: aviboots(AT)netvision.net.il

Prodentim Probiotics Specially Designed For The Health Of Your Teeth And Gums

Instant Grammar Checker - Correct all grammar errors and enhance your writing

Teach Your Child To Read

Powerful WordPress hosting for WordPress professionals

Disclosure: My content contains affiliate links.

31,167 questions

40,724 answers

573 users

How to convert a value of a variable to a string using strval() in PHP

1 Answer

0 votes
$var = 3.14;  
var_dump($var);
echo "<br />";

$str = strval ($var);  

var_dump($str);

/*
run:
    
float(3.14) 
string(4) "3.14" 
    
*/

 





answered Jul 20, 2016 by avibootz

Related questions

2 answers 96 views
1 answer 69 views
2 answers 94 views
5 answers 168 views
1 answer 25 views
...