faqts : Computers : Programming : Languages : PHP

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

1 of 1 people (100%) answered Yes
Recently 1 of 1 people (100%) answered Yes

Entry

How would you use the string variable created in the assignment expression $my_var + ‘dynamic”;to create a “variable” variable,assigning the integer 4 to it

Mar 22nd, 2008 21:11
ha mo, Himanshu Jain,


You can set a “variable”variable using a dollar sign followed by a 
string variable.You can access a “variable”variable directly,or by 
using a string variable.
$my_var = “dynamiic”;
$$my_var = 4:
print $dynamic;
print “${$my_var}”;
http://www.tantofa.com
http://www.fantofa.com
http://www.mantofa.com
http://www.tanpola.com
http://www.tampola.com
http://www.yamot.com
http://www.mozmar.com
http://www.templatestemp.com