I guess this is simple but I've been looking for the answer all day.
I want to take some input from an HTML form, then using javascript validate it and then calculate a key that I need to pass on to my next PHP page.
I can see how I pass input fields using <form action="mypage.php" method="post"> but can't figure out how I can also pass data returned from a javascript function. It is imperative that the end user cannot see this data.
post non input variables to next php page
Moderator: General Moderators
Re: post non input variables to next php page
Easiest way is to include a hidden input field in your form. <INPUT Type='hidden' ID='something' Name='whatever'>
Populate that input field with your Javascript.
Populate that input field with your Javascript.
Re: post non input variables to next php page
It's easy when you know how eh?
Thank you very much.
Mike
Thank you very much.
Mike