I found one way I can do the following

eval("\$val=\$".$variation.";");
echo $val;

Is there a better way?
Henry

"Henry" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Dear All,
>
> $variablename="variable";
> eval("\$".$variablename."=13;");
> echo $variable;
>
> This works fine!! It echoes "13";
>
> But this doesn't ->
>
> echo eval("\"$variablename\"");
>
> Why??
>
>
> Henry
>
>
>



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to