|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Other - Document.formname.submit() not working sometimes....
Hi All,
I have a problem while submitting using Code:
document.formname.submit(). Well i will first go through the problem. My Application is in JSP(Java in Html) front end and Java servlets as controller and deployed in weblogic 8.1 application sever. I have one jsp file called "TopFrame.jsp " which in turn has with it called "ChildFrame.jsp". TopFrame.jsp is top frame or parent frame for the ChildFrame.jsp. In chilframe onClick of one button a javascript function called as logff() is called. The contents of this function is as follows.. Code:
<script>
function logoff(){
top.close();
}
</script>
The above function is in Childframe.jsp So this function tries to close the parent frame i.e., in this case Topframe.jsp... In this jsp in the body unload method is a follows Code:
<body onUnload="logOffAll()"> <form name="mainform" action="Loggingout.jsp"> ... </form> </body> The code for function log off is as follows: Code:
<sciript>
function logOffAll(){
document.mainform.action="/LogoutServlet";
document.mainform.submit();
}
</script>
I need to have a different action in the logOffAll() method, ie., different from the one in form action. The problem here is sometimes the document through the submit action gets submitted but some it doesnt get submitted.. Wat would be source of the problem ...Hoping for reply ASAP... |
|
#2
|
|||
|
|||
|
If the form values are submitted atleast once, it means the error probably does not lie in the form.
Are you sure the mouse click buttons are working well? I had a similar problem which was due to mouse buttons not being clicked properly. |
![]() |
| Viewing: Dev Articles Community Forums > Programming > JavaScript Development > Other - Document.formname.submit() not working sometimes.... |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|