In this case, will the text sent to two files at once?
<form method="post" action="file1.htm"> <form method="post" action="file2.htm"> <input type="text" id="text" value="12345"> <input type="submit" value="Отправить"> </form> </form> In this case, will the text sent to two files at once?
<form method="post" action="file1.htm"> <form method="post" action="file2.htm"> <input type="text" id="text" value="12345"> <input type="submit" value="Отправить"> </form> </form> It is impossible, because the form method="post" , and there is a transition to the link specified in action="" . And during the transition, all functions specified after the code document.getElementById("form").submit() are not read. This operation would be possible in method="get" , because switching to another page does not occur, and all codes are read.
Source: https://ru.stackoverflow.com/questions/395841/
All Articles