Nested (echoed) php running wrong script


Posted on 16th Feb 2014 07:03 pm by admin

Got a problem with a php website I'm creating.

In a nutshell, the first page is entirely html and calls a php script to process an uploaded file and some form fields using POST. After validating the uploaded file the script echos a new page with a new form containing hidden inputs to carry forward the extra information provided in the original form (this was easier than getting my head around cookies). It works, because when I view the generated source all of the hidden input values have been populated with the correct information.

Did you know?Explore Trending and Topic pages for more stories like this.
The problem I am having is with the next part of the process - the echoed page includes a new button that is supposed to call a separate php script, using the new form values. But when the button is clicked, it executes the existing php script again (and fails on the validation) instead of running the correct script as referenced in the onClick attribute of the button.

Any idea what I'm doing wrong? or why it is behaving like this?
No comments posted yet

Your Answer:

Login to answer
348 Like 15 Dislike
Previous forums Next forums
Other forums

PHP and SMS
Hi all forum members. I am new here and am unsure what category shoild I post this in.
Moderator

if php cookie set, show code...
Hi all.. I need to figure out this little snippet right quick.. seems like it should be easy enough

update post issues
I am trying to create an update to a post function, while the update does occur, the page routing an

Help to integrate whois Domain Details to website
Hi,

can i know is their any php script r methods to add domain details to my website.

Structure Question - One Table or One Table Per Record Set?
I have a web app (mySQL and PHP) which allows people to create an item with up to 200 records which

IF Statement & Two Tables With Different Echoes
I'm retrieving two tables in a single query using UNION ALL, like so:

Code: $query = "SE

How to form a xml form table with a single sql statement..?
Hi everyone,
I don't know if this is going to be a duplicate thread but i couldn't

Exporting new records
Trying to figure out the best way to set this up.

People register my site.

Their prof

unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_
Can anyone view my code and tell me why im getting the error:
Parse error: syntax error, unexpect

OOP help
okay so i have a class im making it has everything setup i just need to randomize the 2 variables an

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash