loop through values of hash php

36

foreach ($array as $key => $val) {
    print "$key = $val\n";
}
<?php
    while (list($var, $val) = each($array)) {
        print "$var is $val\n";
    }
?>

Comments

Submit
0 Comments