I have an array and looped through it setting the name= part of the form , now what i want to be able to do is say
Code: Select all
foreach($arr as $val)
$newval = $_POST['$val'];I am really stuck so any help would be greatly appreciated.
Moderator: General Moderators
Code: Select all
foreach($arr as $val)
$newval = $_POST['$val'];Code: Select all
foreach($arr as $val) {
$newval = $_POST[$val];
//Do whatever with the new value
}Code: Select all
foreach($arr as $val)
$newval = $_POST[$val];Code: Select all
foreach($arr as $val) {
$$newval = $_POST["$val"];
}Code: Select all
extract($_POST);