Welcome Guest, Not a member yet? Register   Sign In
looping through entire multidimensional array passed to view
#1

[eluser]jordantkj[/eluser]
Hi,
What I'm trying to do is use a foreach to loop through all arrays and their values. Is there some way to simply loop through all of them without specifically using the array name (fpc1 and pic1)?

Code:
foreach($??? as $att1) {
   echo '<td>' . $att1 . '</td>';
}

Please see the array below:

Array
(
[fpc1] => Array
(
[0] => FPC
[1] => 0
[2] => 710-013052
[3] => 3
[4] => JJ8912
[5] => T320-FPC3-E
[6] => E-FPC Type 3
)

[pic1] => Array
(
[0] => PIC
[1] => 0
[2] => 750-009567
etc...

Thanks,
-T


Messages In This Thread
looping through entire multidimensional array passed to view - by El Forum - 01-30-2012, 02:00 PM



Theme © iAndrew 2016 - Forum software by © MyBB