oracle259 Posted November 5, 2006 Share Posted November 5, 2006 How can i submit a form using a text link Quote Link to comment Share on other sites More sharing options...
tet3828 Posted November 5, 2006 Share Posted November 5, 2006 What sort of data are you trying to submit? Where do you want the data to be sent to? a different page or the one you are working on? Quote Link to comment Share on other sites More sharing options...
oracle259 Posted November 5, 2006 Author Share Posted November 5, 2006 just a regular for with a text, password and hidden fields. the data is being sent to a different page Quote Link to comment Share on other sites More sharing options...
tet3828 Posted November 5, 2006 Share Posted November 5, 2006 Im a noobie to but this worked for me:(this code needs to be within the <?php ?> brackets)echo "<a href=yoururl.php?id='$varaibleYouWantToPass' />type your link text here</a>";yoururl.php is where you put the location and file name you want to pass your data to. $varaibleYouWantToPass is the varaible you want to pass. Quote Link to comment Share on other sites More sharing options...
oracle259 Posted November 5, 2006 Author Share Posted November 5, 2006 no no I want to know if i can submit a form using a text link similar to how a submit button does it Quote Link to comment Share on other sites More sharing options...
alpine Posted November 5, 2006 Share Posted November 5, 2006 You can do that by using javascript:[code]<s c r i p t type="text/javascript" language="javascript">function submitform(){ document.my_form.submit();}</s c r i p t><form method="post" name="my_form" action="handle.php"><input type="text" name="name"><a href="javascript: submitform()">Submit</a></form>[/code](compress "s c r i p t" and remove the spaces - due to posting restrictions on this board) Quote Link to comment Share on other sites More sharing options...
oracle259 Posted November 5, 2006 Author Share Posted November 5, 2006 Thanks this helps more than u know Quote Link to comment 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.