Is their a function for this?

From: Date: Thu, 05 Apr 2001 04:17:25 +0000
Subject: Is their a function for this?
Groups: php.general 
Request: Send a blank email to php-general+get-47167@lists.php.net to get a copy of this message
Basically I have array variables, lets say: ------------------------------------------- $folder[0] = "basic"; $folder[1] = "standard"; $folder[2] = "knowledge"; Fruther down in the code: ------------------------------------------- $totalsub_basic = "10"; $totalsub_standard = "24"; $totalsub_knowledge = "12"; Everything runs fine until "$total_count" how do I take the value of $folder[$i], lets say "standard" append that to "totalsub" and get the value of "$totalsub_standard"????? ------------------------------------------- $i = 0; while($i < $level_0_links) { echo "First While Loop"; if (ereg("^/$folder[$i]?", $PHP_SELF)) { $a = 0; $total_count = (eval("$totalsub_$folder[$i]")); <------- while ($a < $total_count) { echo "$a"; $i++; } } $i++; } Thanks Everyone!

« previous php.general (#47167) next »