1.

How To List All Values Of Submitted Fields?

Answer»

If you want list all values of submitted FIELDS, you can write a simple LOOP to retrieve all ENTRIES in the $_REQUEST array. Below is an improved version of processing_forms.php to list all submited input values:
<?php
PRINT("<html><pre>");
$count = count($_REQUEST);
print("NUMBER of values: $count\n");
foreach ($_REQUEST as $key=>$value) {
print(" $key = $value\n");
}
print("</pre></html>\n");
?>

If you want list all values of submitted fields, you can write a simple loop to retrieve all entries in the $_REQUEST array. Below is an improved version of processing_forms.php to list all submited input values:
<?php
print("<html><pre>");
$count = count($_REQUEST);
print("Number of values: $count\n");
foreach ($_REQUEST as $key=>$value) {
print(" $key = $value\n");
}
print("</pre></html>\n");
?>



Discussion

No Comment Found