I am trying to write a simple script that displays the variable names and the values of the variables posted to a php page. My hope is that someone can take any form and change the action to the url of this php script. I would be able to know all the information about the form. This is what I was trying but this code does not work. Any ideas?
<?php
foreach($_POST as $theKey => $theValue){
echo "The posted variable name is: " . $theKey . ".<br/>";
echo "The value of ". $theKey." is: " . $theValue . ".<br/>"; }
echo sizeof($_POST) . ' is the number of items posted';
?>
Thanks;
Wade