I have the result of $_POST that looks like this:
print_r($_POST):
yields the following:
Array ( [aid] => 361 [comment] => Array ( [1286] => [1288] => test [1283] => [1284] => [1289] => ) [Complete] => Array ( [1288] => 6 ) )
what i need to do is get the result of [comment] where the key is equal to the key of [Complete]
In this case [Complete] = 1288
so I want value of [comment] where it's key is [1288] also which would yield => test
Is this possible? If so how would you do it?
Thanks,
Slamman
Solution:
$Comment_array = array($_POST['Comment']);
$comm = $Comment_array[0];
while (list($key, $val) = each($comm)) {
if ($key == $cond_id) {
$comment = $val; }
}