Maniacility Posted August 6, 2009 Share Posted August 6, 2009 Hey, i'm integrating paypal into my website. To buy something there is a "Buy Now" button which you click then a form submits. I want to remove this button and just have an onClick on the table cell that submits instead. E.g. <td onClick="submit_paypal_form">paypal form here</td> i've tried several ways all that didn't work so now i'm hoping someone else can help me. i'm not fussed where it goes or how it functions, just want it to submit using the table cell if it's possible, thanks! Quote Link to comment https://forums.phpfreaks.com/topic/169033-solved-submit-a-form-using-a-table-cell/ Share on other sites More sharing options...
haku Posted August 6, 2009 Share Posted August 6, 2009 Why do you want to do this? There are a whole lot of reasons you shouldn't do this, which is why I ask. Quote Link to comment https://forums.phpfreaks.com/topic/169033-solved-submit-a-form-using-a-table-cell/#findComment-891819 Share on other sites More sharing options...
Maniacility Posted August 6, 2009 Author Share Posted August 6, 2009 Why do you want to do this? There are a whole lot of reasons you shouldn't do this, which is why I ask. well, the way my site is layed out is usually without buttons if possible, its easier and better looking (in my opinion) to have table cells that onhover change color, then they just click, then an "are you sure" prompt will appear to confirm then it will submit, but i've used $_GET for all my other submits as the end source is on my own site, however this isn't possible because i need to submit the details of this form and then go to paypal (if that makes sense). hense why I need it to submit the form using an onclick. unless theres another alternative that use table cells that can submit it. Quote Link to comment https://forums.phpfreaks.com/topic/169033-solved-submit-a-form-using-a-table-cell/#findComment-891821 Share on other sites More sharing options...
haku Posted August 6, 2009 Share Posted August 6, 2009 There isn't. You can do this using submit(). You really shouldn't though. Quote Link to comment https://forums.phpfreaks.com/topic/169033-solved-submit-a-form-using-a-table-cell/#findComment-891825 Share on other sites More sharing options...
Maniacility Posted August 6, 2009 Author Share Posted August 6, 2009 There isn't. You can do this using submit(). You really shouldn't though. Done it myself, thanks! Quote Link to comment https://forums.phpfreaks.com/topic/169033-solved-submit-a-form-using-a-table-cell/#findComment-891832 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.