I am trying to collect all the variables I have from a form using the post method.
I have used this code numerous times before.
For some bizarre reason, when using the foreach statement to gather the POST variables into an array, it automatically turns the value of each peice of the an array to the value 'S'. I have absolutely no understanding why.
below is my code with commented output:
echo "Post: ". $_POST['title']; // outputs correct Title from form.
foreach($_POST as $varname => $value){
$sermon[$varname] = $value;
}
echo "sermon: " .$sermon['title']; // outputs: S
Thank-you,
Tim