adicrst Posted January 14, 2008 Share Posted January 14, 2008 How can i use a submitting link instead of a button ? here is the simple form <form action="submit.php" method="post"> Name: <input type="text" name="name"> Age: <input type="text" name="age"> <input type="submit" name="send"> </form> nou instead of the button send i want a link to send the informations to the submit.php page Link to comment https://forums.phpfreaks.com/topic/85878-submit-link-instead-of-a-button/ Share on other sites More sharing options...
phpSensei Posted January 14, 2008 Share Posted January 14, 2008 http://www.thesitewizard.com/archive/textsubmit.shtml How hard is it to find this? http://www.google.ca/search?hl=en&q=Javascript+link+for+submit&meta= Link to comment https://forums.phpfreaks.com/topic/85878-submit-link-instead-of-a-button/#findComment-438438 Share on other sites More sharing options...
interpim Posted January 14, 2008 Share Posted January 14, 2008 <a title="Submit" onclick="document.FORM-ID.submit();" id="text_link" href="#">Click here to submit</a> Link to comment https://forums.phpfreaks.com/topic/85878-submit-link-instead-of-a-button/#findComment-438440 Share on other sites More sharing options...
adicrst Posted January 14, 2008 Author Share Posted January 14, 2008 but i dont want a javascript. I want a pure PHP and i remember it was something like <a href="submit.php?SOMETHING HERE">link Link to comment https://forums.phpfreaks.com/topic/85878-submit-link-instead-of-a-button/#findComment-438442 Share on other sites More sharing options...
phpSensei Posted January 14, 2008 Share Posted January 14, 2008 but i dont want a javascript. I want a pure PHP and i remember it was something like <a href="submit.php?SOMETHING HERE">link Javascript, php won't submit a form for you. Link to comment https://forums.phpfreaks.com/topic/85878-submit-link-instead-of-a-button/#findComment-438443 Share on other sites More sharing options...
phpQuestioner Posted January 14, 2008 Share Posted January 14, 2008 you could use the cURL method. Link to comment https://forums.phpfreaks.com/topic/85878-submit-link-instead-of-a-button/#findComment-438579 Share on other sites More sharing options...
phpQuestioner Posted January 14, 2008 Share Posted January 14, 2008 oh and to do this: <a href="submit.php?SOMETHING HERE">link</a> you would need to set-up a predefined form variable; like so: <a href="submit.php?name=John&age=30">link</a> you will need javascript even for that and if you didn't want to do this with javascript. why did you post this thread in the javascript forum and not in the php forum? ??? Link to comment https://forums.phpfreaks.com/topic/85878-submit-link-instead-of-a-button/#findComment-438580 Share on other sites More sharing options...
adicrst Posted January 18, 2008 Author Share Posted January 18, 2008 i did posted in the php forum but it was moved here by a mod thanks for the reply Link to comment https://forums.phpfreaks.com/topic/85878-submit-link-instead-of-a-button/#findComment-443014 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.