Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...


•How can we submit a form without a submit button

Answers were Sorted based on User's Feedback



•How can we submit a form without a submit button..

Answer / sei thu htun

You can use single button and use javascript for submit
eg.
<script type="text/javascript">
function submitform()
{
document.getElementById("your_form_id").submit();
}
</script>

//in html form
<input type="button" value="Submit" onclick="submitform();"/>

Is This Answer Correct ?    22 Yes 2 No

•How can we submit a form without a submit button..

Answer / creatore

simple use javascript
document.form_name.submit();

Is This Answer Correct ?    12 Yes 2 No

•How can we submit a form without a submit button..

Answer / bharat pradhan

<script type="text/javascript">
function pick()
{
document.form1.action="submit.php";
document.form1.submit();
}
</script>


<form name="form1" id="form1" method="post" onsubmit="pick()">
<input type="text" name="T1" id="T1">
</form>

Is This Answer Correct ?    8 Yes 3 No

•How can we submit a form without a submit button..

Answer / prantik gautam

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html lang="en">
<head>
<title>submit a form without a button</title>
</head>
<body ondblclick="document.frm_nm.submit();">
<form action="" method="post" name="frm_nm">
<input type="text" id="txt" size="25"/>
</form>
</body>
</html>

Is This Answer Correct ?    3 Yes 1 No

•How can we submit a form without a submit button..

Answer / tejash gajjar

You can use single button and use javascript for submit
eg.
<script type="text/javascript">
function submitform()
{
document.getElementById("your_form_id").submit();
}
</script>

//in html form
<input type="button" value="Submit" onclick="submitform
();"/>

Is This Answer Correct ?    2 Yes 1 No

Post New Answer



More PHP Interview Questions

What is member function?

0 Answers  


Explain PHP?

0 Answers  


What is the use of $_request variable?

0 Answers  


Does jwt protect against csrf?

0 Answers  


What is the different between cookies and session in php?

13 Answers  






How to retrieve the original query string?

0 Answers  


How do I end a php session?

0 Answers  


What is the use of post in php?

0 Answers  


How many types of php frameworks are there?

0 Answers  


What is the use of "enctype" attribute in a html form?

0 Answers  


What is the major php security hole? How to avoid?

0 Answers  


How many escape sequences are recognized in double-quoted strings in php?

0 Answers  






Categories