Jump to content

Need to check if a form has been sumitted.


kevinkhan

Recommended Posts

for the form submit button i have

 

 <input class="send" type="image" src="images/submit.gif" name="submit" /></p> 

 

but when i check for this condition it doesn't recognize it

 

 if(isset($_POST['submit']))

 

Why is this and what other condition could i use..

 

The above works if i change type image to type submit..

you could try adding something to the value attribute of the input. i'm not sure if that would help for an "image" input type. perhaps simply use another one of the form elements? if it's the only form element, you could always add a hidden one.

Just an observation.  you do not have a value for your submit button.  how can you have a post variable if it has no value.....I suppose it is possible it could be NULL or empty......

 

I would try to do this.

 

 <input class="send" type="image" src="images/submit.gif" name="submit" value="submit" />

 

Not sure if that will fix your issue....it might not

Just an observation.  you do not have a value for your submit button.  how can you have a post variable if it has no value.....I suppose it is possible it could be NULL or empty......

 

I would try to do this.

 

 <input class="send" type="image" src="images/submit.gif" name="submit" value="submit" />

 

 

Yes this worked, Thanks... :)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.