<Script> code is getting ignored in few cases

Discussion in 'Javascript' started by suresht.rsl, Mar 22, 2006.

  1. suresht.rsl

    suresht.rsl Guest

    Hi All,

    I am having a JSP file which is making call to a CORBA function. After
    getting the response if there is no error, <SCRIPT> code is there
    which is responsible for opening another window and display the result.
    CORBA function is used for placing some orders.
    Just before <SCRIPT> code I am printing JSP log and in script code I
    have put an alert msg.
    In normal situation log is getting printed and also alert msg is
    coming, so new window is getting opened. But it seems like when when
    order to be placed is big and taking long time to get it done, only log
    is getting printed but no alert msg and no new window.
    One more point I would like to tell is this problem is occuring on few
    systems (not every systems) when I am trying these two seperate
    situation from one more machine it is running very smoothly.
    I am not sure whether it is because of some <SCRIPT> timeout or browser
    setting. Please help me in this. I am putting part of the code here.

    if (!tmp_svc_desig_type.equals("CORE-T3") &&
    (!tmp_svc_desig_type.startsWith("CCAPT3") &&
    !tmp_svc_desig_type.startsWith("CTT3"))) {
    System.out.println("Opening Order Response Window"); /*log getting
    printed each time */
    %> //immediate line is <SCRIPT> code
    <script>
    // problem with this script, sometimes
    and on some machines it is
    // getting executed and sometime getting
    ignored
    alert("just before calling display result javascript method");
    displayResult();
    </script>
    <% }

    // here is the implementation of script method
    <script>
    function displayResult() {
    document.proces.action =
    "CNIOrdResponse.jsp";
    document.proces.target = "_blank";
    document.proces.submit();
    }
    </script>
     
    suresht.rsl, Mar 22, 2006
    #1
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.