How to get form id in javascript function?
-
Hi.. How can i get form id of form from which request is sent? Actually I have menu file which is created in javascript and I want to redirect to the home page of second application. I m calling the PostPage function on click of that menu. But this menu can be clicked from any form of the 1st application. So please tel me how can i do this task? function PostPage() { document.form1.action = "http://Ip-address/issuetracker/"; document.form1.method = "POST"; document.form1.submit(); return }
Gurudatta B. Shelke
-
Hi.. How can i get form id of form from which request is sent? Actually I have menu file which is created in javascript and I want to redirect to the home page of second application. I m calling the PostPage function on click of that menu. But this menu can be clicked from any form of the 1st application. So please tel me how can i do this task? function PostPage() { document.form1.action = "http://Ip-address/issuetracker/"; document.form1.method = "POST"; document.form1.submit(); return }
Gurudatta B. Shelke
rather than form ID use forms[0] like this document.forms[0].action =".."
Nobody is perfect i'm Nobody