-
Little Help!
I created a VIP Area and the registration folder contains 3 pages, each page has labels or fields if you wanna say, the problem is that i only got the last page infos, yet the first n' second one i dont receive its infos if someone's registered on it,
i used the method of POST, $_POST
For example :
(PAGE 1)
PHP Code:
<input name="firstname" maxlength="20" size="20" class="form-input" type="text" validate="required:true , number:true" />
(PAGE 2)
PHP Code:
<?
$FirstName .= $_POST['firstname'];
?>
<form method="POST" action="PAGE3.php">
<input type="hidden" name="firstname" value="<?php echo($FirstName); ?>">
(PAGE3)
the same again with page 3 fields
PHP Code:
<?
$FirstName .= $_POST['firstname'];
?>
<form method="POST" action="PAGE3.php">
<input type="hidden" name="firstname" value="<?php echo($FirstName); ?>">
Finally I got only the Page3 Posted fields, non of Page1 or Page2 been recieved at all, it comes empty
PHP Code:
$message .= "First Name: ".$_POST['firstname']."\n";
Please help me to fix this..
-
Re: Little Help!
First off, unless you have short php tag turned on in your configuration file, your <? ... ?> is not even going to be interpreted. Always use <?php ... ?>.
Second, there is no validate attribute for the <input> tag.
Third, you should not be using .= unless you're concatenating variables. In your example, you're just creating them. So just set them as equal.
Last, why do you have page 3 redirecting to page 3 again?
-
Re: Little Help!
Well I guess you didn't understand because I didn't put the whole source code, wait for me i'll upload it for ya
-
Re: Little Help!
Yes, I did understand. And I replied by helping you correct some code. Apparently you did not understand.
Also, why are you using echo like you do? Here's the proper way...
PHP Code:
<?php echo 'Text to be outputted'; // notice no parenthesis ?>
-
Re: Little Help!
Well I'm sorry then :)
I'm just asking if there's a good way to get Forms result in 3 pages or even 4 pages, i mean each page contains a form and when u go to the next step which is page 2 you will find another form and the same thing with the next steps until u finish them, you must receive the full results of that forms. the question is what methods is good and easy to make it :) u got me now?
-
Re: Little Help!
Use sessions to carry data across multiple sessions...not back to back forms.