note 48536 deleted from faq.html by didou
| From: | didou@php.net | Date: | Wed, 29 Dec 2004 12:58:35 +0000 |
| Subject: | note 48536 deleted from faq.html by didou | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-82454@lists.php.net to get a copy of this message | ||
Note Submitter: bagpipeboy
----
You can avoid to use the "my_parameter[]" form-element names by generating your HTML form
inputs like this:
<form>
<?php for ($n=0; $n<10; $n++) { ?>
<input type="hidden" name="elem_<?= $n ?>">
<?php } ?>
</form>
And you access your data like this:
<?php
$arr = array();
for ($m=0; $m<10; $m++) {
$arr[$m] = $_REQUEST["elem_$m"];
}
?>
Nobody will know that you use PHP and in my opinion it is the most proper way.