#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2013
    Posts
    2
    Rep Power
    0

    After Document.location cannot find the form


    My current javascript function is throwing me JS error.

    I used "document.location=document.location;" to refresh/reload my page with the changes made by viewer. This is all working in IE and Sarfari. However, I have error in Firefox, it seems to unload the form on the page, and claim the form doesn't exist. See error message below:-


    "A JavaScript exception was caught during execution of HyperEvent:
    TypeError: form is undefined
    .....
    .... (details of the form it try to submit) ...."


    My script is something like this:-

    Code:
    functin A {
    form_save();
    document.location=document.location;
    }
    
    function B {
    ....
    ...
    form_save();
    ....
    ....
    }
    
    <input id="12345" type="text" onBlur='A("4567",this);B("TESTelem","1112",this.value);' name="1112">
    Do anyone has any idea to over come this Firefox issue?

    Thank you in advance.
    Last edited by BrightYellow; March 7th, 2013 at 05:41 AM. Reason: add code tag

IMN logo majestic logo threadwatch logo seochat tools logo