Hoping someone can help me with this. Below I have an example of what 
I'm trying to accomplish.
Bottom line.. I need to print out $variable3[0] and $variable4[0]
and my problem is that I'm trying to generate the variable name. I can 
get this to work with $variable1 and $variable2 which are not arrays, 
however that doesn't help me much.

Any suggestions would be appreciated.

Kevin



<?
        $variable1="one";
        $variable2="two";
        $variable3[0]="three";
        $variable4[0]="four";
        
        $j=1;
        while($j<5){
                print("${variable.$j} <BR>");
                $j++;
        }


        $j=1;
        while($j<5){
                $k="\$variable".$j."[0]";
                print("$k <BR>");
                print("${variable.$k} <BR>");
                $j++;
        }
?>


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

Reply via email to