I have a client that has a huge form (60+ values) is there any way to make a script that will take all of those form values and put them into an array??
Thanks
form values into an array
Moderator: General Moderators
-
kettle_drum
- DevNet Resident
- Posts: 1150
- Joined: Sun Jul 20, 2003 9:25 pm
- Location: West Yorkshire, England
Code: Select all
$myOwnArray = $_POST;
$myOwnArray = $_GET;so will creating the array this way keep me from having to manually enter:
it will do that for me??
Code: Select all
<?php
$myArr = array('$_POST[var1]', '$_POST[var2]'.....);
?>-
kettle_drum
- DevNet Resident
- Posts: 1150
- Joined: Sun Jul 20, 2003 9:25 pm
- Location: West Yorkshire, England
Yeah. It will copy everything that is in $_POST.
Test it for yourself 
Code: Select all
$myOwnArray = $_POST;
print_r($_POST);
print_r($myOwnArray);