Webmaster's Community
Designing and Development => Programming => Topic started by: Rahul Kaushik on April 17, 2012, 02:17:16 PM
-
Hi,
Some one make me clear that what is difference between $var and $$var.
Thanks in advance
-
Hello Rahul,
I think you will understand with this example so look at the code
$var = 'hello';
$$var = 'word';
echo $hello;
For example, the code creates a variable called $hello and outputs the string 'world'. The double dollar sign declares that the value of $var should be used as the name of newly defined variable.
Hope this will help you....!!!!!
-
HI,phpdeveloper.
Thank you for Replay........ :-*