Two Identical forms on the same JSP page.???

Hi want to have two identical submit forms on the same form but for some reason a get a javascript error when i add the second form to the JSP page... can you help me...

I assume you meant "two identical submit buttons", instead of "two identical submit forms". Seeing your description of the problem, I believe you can reproduce it with a pure .html page, that is, a page containing not JSP code. So it is not a problem in JSP domain proper.
I was going to direct you to the Technologies>>Internet>>Dynamic Services forum at
http://forums.oracle.com/forums/thread.jsp?forum=95
Then I found you have posted the same question as thread 298169 there.

Similar Messages

  • I want to post the values of the form in the same Jsp Page

    I want to post the values of the form in the same Jsp page.

    Was that a question? Or are you just informing the world of your grand intentions?
    But yeah, all you need to do is direct your action to the same page you're in. So, if this is your foo.jsp, it'd be something like...
    <%
    if(request.getParameter("bar") != null) out.println("Hello");
    %>
    <form method="post" action="foo.jsp">
       <input type="text" name="bar" value="baz">
       <input type="submit">
    </form>When you submitted your form, it would post the value to the same JSP page as you're already in, and print out Hello to the screen. "Hello" would not print out on the first visit, as the request would obviously not contain the parameter "bar" yet.

  • Linking between two IFRAME tags on the same JSP page

    I have a JSP (lets call it �PAGE_A.jsp�) that contains a table� the <TD> tags hold IFRAME tags with an initial �src� referencing a �blank.jsp��

    <!-- Report View Table-->
    <table width="100%">
    <tr>
    <td>
    <iframe id='report_view' name="report_view" width='60%' height="500" frameborder="0" src='blank.jsp'>
    </td>
    <td align="left">
    <iframe id='drilldown_view' name="drilldown_view" width='40%' height="500" frameborder="0" src='blank.jsp'>
    </td>
    </tr>
    </table>

    At a point, the user initiates a call to a servlet, and the output (PAGE_B.jsp) is returned to the first IFRAME �report_view�.
    PAGE_B.jsp contains HTML anchor tags that call the servlet again, this time the return target is the second IFRAME �drilldown_view� :
    ( Some Text).
    Clicking the link produces the desired page to be generated and displayed in the correct IFRAME running IE 5.5, however, the same code under NETSCAPE 7.x causes the �linked� page to open in a new browser window.
    I have deduced that this effect may be due to the NETSCAPE browser �thinking� that the targeted IFRAME (�drilldown_view�) should be a �child� of the IFRAME that contains the link (�report_view�), instead of another IFRAME belonging to PAGE_A.jsp. Under this circumstance, NETSCAPE cannot find the �target�, and thus redirects to a new browser window.
    Q: Is there a way to specify the �parent� of the �iframe� in the anchor�s �target� attribute?

    target in a link shouldn't care, as long as the IFRAME is in the same window... It should be able to find it.
    Otherwise, you could explore using Javascript to get a reference to the object by specifying the path:
    var oIFrame = top.document.getElementById('drilldown_view');
    oIFrame.src = 'somepage.html';
    that could work.. I've used that type of thing before.

  • Regarding incorporate the two page nations in the same JSP page

    Hi folks,
    i am unable to do two page nations in the same JSP page using paging tag libray,I am getting the follwoing problem while setting the offset value to the Pager.offset.
    I have written the code like this.
    <pg:pager items="<%=size%>" export="sreenyOffset=offset, currentPageNumber=pageNumber;" isOffset="true" scope="request">
         <pg:index export="totalItems=itemCount">
         <% System.out.println("Before currentPageNumber:"+currentPageNumber); %>
         <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" nowrap>
              <tr class="pagenation" >
                   <td width="1%">&nbsp<br><br></td>
                   <td width="40%" align="left"> 
                        <pg:page export="firstItem, lastItem">Displaying results <strong><%= firstItem %>-<%= lastItem %></strong> of <strong><%=      totalItems %></strong> found</pg:page></td>
                             <td width=20%></td>
                        <pg:prev export="pageUrl,firstItem" >
                             <td width="5%" align="right" height="22">
                             <a href="javascript:submitSearchForm(document.organizationForm,'<%= firstItem %>')"><b>Previous</b></a></td>
                        </pg:prev>
                        <pg:pages export="pageUrl,firstItem,pageNumber">
                        <%
                             System.out.println("pageNumber :"+pageNumber+"^currentPageNumber:"+currentPageNumber);
                        %>
                             <% if (pageNumber == currentPageNumber) { %>
                                       <td width="2%" align="right" height="22"><font color=#FFFFFF><%= pageNumber %></font></td>
                             <% } else { %>
                             <td width="2%" align="right" height="22">
                                       <a href="javascript:submitSearchForm(document.organizationForm,'<%= firstItem %>')"><font color=#415481> <%= pageNumber %> <font></a>
                   </td>
                        <% } %>
                        </pg:pages>
                        <pg:next export="pageUrl,firstItem" ifnull="<%= true %>">
                             <% if (pageUrl != null) { %>
                   <td width="5%" align="right" height="22">
                        <a href="javascript:submitSearchForm(document.organizationForm,'<%= firstItem %>')"><b>Next</b></a></td>
                        <% } %>
                        </pg:next>
              </tr>
         </table>
         </pg:index>
              <html:hidden property="offset" value="0"/>
              <html:hidden property="pager.sreenyOffset" value="0"/>
    </pg:pager>
    I need some clarification for following things.
    1)i have given the export like this
    export="sreenyOffset=offset, currentPageNumber=pageNumber;"
         but while setting the offest for pager, i am doing like this
                   <html:hidden property="pager.sreenyOffset" value="0"/>
         can i customize the pager.offset to pager.(someting) like that.
    2)if i use pager.offset for two page nations in the same page pager.offset value is overriding,So i am unable to maintian the page nations.
    3)i can change the offset value into sreenyoffset in the export property of pager tag,if iam able to change the pager.offset value to customized value my problem will solve.
    4)
    can i declare the export property like this.
    <pg:pager items="<%=size%>" export="sreenyOffset=offset, currentPageNumber=pageNumber;" isOffset="true" scope="request">
    Please give me your valuable suggestions,it will be very helpful to me.
    Also give me some suggestions how to do the two page nations in the same page.I am desperately waiting for response.
    Thanks & Regards,
    Sreeny Reddy.

    Hi,
    I was trying the pagination concept in jsp. I am getting a lot of errors. Can u help me for displaying this pagination.i need to display dynamic records according to search criteria. In search criteria, an area is selected and the data related to that area should be displayed from a table in mysql . It has 100+ records each
    with 6 columns, each page should be displaying 10 records, what we call pagination. I was trying this(in java jsp)( should not do in struts, should be done only in jsp) for a long time. By ur faq, i understood u hava already done it. Pls try to help me. Can u pls send me a sample program regarding this?
    I would be very grateful if u help me.
    thanks in advance,
    regards,
    mv.

  • More than one business component (views) in the same JSP page

    Hi, I am trying to have more than one business component (views) in the same JSP page as Input Form.
    For example:
    There are two BC4J:
    Person:
    Code.
    Name.
    Address:
         Person_code
         Street.
         City.
    There is a master detail relationship between them and there is a link between both views in the application module.
    I want to create a JSP page with an Input form for both views. When the user decides to create a Person, I need to insert in both tables.
    Insert code and name into Person table.
    Insert Person_code, Street and City into Address table.
    It is possible to do in Forms but I am not sure if I can be able to do this in JDeveloper 10G.
    Thanks

    Sorry I lost the tabs
    Person has two attributes Code and Name.
    Address has three attributes Person_coden Street, City.

  • Error while trying to open the same JSP page.

    Hi partners,
    After solving some issues with JSP deployment, we are getting another error message.
    This is when we try to open the same JSP page at the same time.
    500 Internal Server Error
    javax.servlet.jsp.JspException: oracle.express.idl.util.OlapiException: ORA-22275: invalid LOB locator specified at oracle.dss.addins.jspTags.PresentationTag.doStartTag(PresentationTag.java:194) at Principal.jspService(_Principal.java:68) [SRC:/Principal.jsp:6] at com.orionserver[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].http.OrionHttpJspPage.service(OrionHttpJspPage.java:56) at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:349) at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:509) at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:413) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java(Compiled Code)) at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java(Compiled Code)) at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java(Compiled Code)) at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java(Compiled Code)) at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:112) at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186) at java.lang.Thread.run(Thread.java:513)
    I mean this is a concurrency problem.
    Any information about this will be really appreciated.
    Best regards!!!!!
    Francisco Mtz.

    After running the BI_Checkconfig tool I got an inconsistent OLAP API Metadata
    result, it was because a partner was modifying the OLAP metadata without saving
    the changes.
    After saving the changes in the OLAP metadata, I ran the BI_Checkconfig tool
    again with success (no metadata errors).
    Now the pages are displayed without any error message.
    Best regards!!!!
    Francisco Mtz.

  • I want to display many records in the same jsp page

    Hi,
    i want to display many records with in the same jsp page providing the next,previous,first last .
    give me clear idea how to do that one
    note :only using servlets,jsp,jdbc and javascript

    I believe that this is the fourth time this question has been asked by the same person
    http://forum.java.sun.com/thread.jspa?threadID=720977&messageID=4159465#4159465
    http://forum.java.sun.com/thread.jspa?threadID=720945&messageID=4159338#4159338
    http://forum.java.sun.com/thread.jspa?threadID=720919&tstart=0

  • Two Flex app on the same web page + BlazeDS

    Hi,
    On our welcome page, we have two small apps that display advertisement; they are both identical and use BlazeDS. When the welcome pas shows, I always have one of the app that receives this fault :
    [RPC Fault faultString="Detected duplicate HTTP-based FlexSessions, generally due to the remote host disabling session cookies. Session cookies must be enabled to manage the client connection correctly." faultCode="Server.Processing.DuplicateSessionDetected" faultDetail="null"]
    I feel the problem comes from the fact that two apps from the same page access the same service at the same time. Am I wrong?

    Hi. I believe you are right. Using a HTTP sniffer such as Charles to look at the HTTP headers would tell us exactly what is happening but I think we can assume that you are in the ballpark.
    If the server gets a request with no session cookie header, I think it will create a new session and then send a Set-Cookie header on the response with the new session id. It is likely that if both your apps are making their initial requests to the server at roughly the same time that neither of the requests has a session cookie header. In that case the server is probably creating two sessions, one for each request and that is likely causing problems.
    While I haven't tested this particular scenario, I have been doing some testing around session cookie handling in BlazeDS recently. I would see if you can workaround this problem by already having a HTTP session established with the server before either of your apps runs. One way to do this would be by having a jsp page redirect to your welcome page. The call to the jsp page would cause a session to get created on the server. The server would return a Set-Cookie header with the new session id. The browser would then request the welcome page sending a session cookie header on the request. Your apps would load. Each app would make its initial request to the server only this time the requests would contain a session cookie header for the same valid HTTP session. . . and you would avoid getting duplicate session detected errors. . . at least that's I hope would happen.
    If I have some free time I will try running through this scenario (having two small apps on the same page) and report back.
    Hope that helps.
    -Alex

  • Two tabular form on the same page

    Hi,
    There is a tutorial or a standard way to build two tabular form on same page?
    thanks in advance
    lukx

    Hi,
    You can see this example also.
    http://htmldb.oracle.com/pls/otn/f?p=31517:163:1033737280330848:::RP,::
    Thanks
    Tauceef

  • How to load the same jsp page and set user id to 0 when checkbox is selecte

    I hope this question isn't too amateurish to answer, but it is something that has been troubling me.
    I have a jsp page page that display information about a user and has the userID passed in the link. So something like user.jsp?userID=12 for example.
    On the same page I have a form with a checkbox, and a submit button, the html code is as follows:
    <form name="form1" method="get" action="user.jsp">
    <p><input name="userID" id="userID" type="checkbox" value="0"></p>
    <p><input name="Submit" type="submit" value="Submit"></p>
    </form> What I want to do is, if a user ticks the checkbox and presses Submit, I want to load the same page again, but
    set the userID to zero and so the top url has the following: user.jsp?userID=0
    How can I achieve this.
    Thanks for all the help
    Zub

    actually I need a check code which on submit checks if the checkbox is ticked then set the value of UserID to zero. so when I press submit and before the page loads to simply does a check if its ticked? I can write the if statment but I do not know what how to check if the checkbox is ticked and were to include the code

  • Two people working on the same IWeb-page and still keep our own work saved.

    Hi! I work together with a girlfriend buliding webpages in IWeb. Is it possible for us to exchange work when both of us is edithing the same webpage - and both of us have other pages one our own that we rader not share/update/change/edit/overwrite/delete,...?

    Yes. Are you referring to pages in the same site or separate sites?
    For separate sites the shared site would need to be it in its own domain.site2 file. Then follow the directions in this MacWorld online article: Managing an iWeb site from multiple Macs
    The important caveat to this is that both of you cannot work on the site at the same time and plenty of time must pass between one of you finishing their work and the other starting up. It's just the nature of the beast. Otherwise you would have to pass the domain.sites2 file/package back and forth between your two Macs.
    If your two Macs are connected together on the same LAN you could place the domain file on an external HD attached to one of the Macs so both would have access to the same file. Again, both of you could not work on the site at the same time.
    The other sites would then be in a separate domain file.
    If you're referring to pages in the same site it can be done by having the jointly managed pages in one site and your pages in a separate site and her pages in a separate site.
    Then in the joint site add blank pages representing your pages and her pages. In each blank page put the following code in an HTML snippet:
    <script type="text/javascript">
    parent.window.location = "URL TO PAGE ON SITE YOU WANT TO REDIRECT TO"; </script>
    Thanks to Cyclosaurus for this code
    On each of your sites you would add blank pages representing the joint page and each other pages with the same redirect code.
    Now you can edit and change your pages at any time, publish as she can also with her pages. For the joint pages you will have to use one of the methods I described above for separate site.
    See this demo page for more about the Redirect method: Redirect.
    OT

  • How can I use two tabular forms on the same page.

    I have create one tabular form in page and try to create second tabular form so
    it gives below error.
    1 error has occurred Updatable SQL Query already exists on page XXXXX.
    You can only add one updatable SQL query per page. Select a different page.

    I can get this to work but the page is submitted, either when I use a button with URL link or from a link on a display only text field.
    Is this how it is supposed to work? I thought it was supposed to work just on the browser so it is fast.
    IGNORE THIS!
    =============================
    I resolved it easily by modifying the URL from f?p=blah blah to #LINK_NAME
    Message was edited by:
    user530800

  • How to get error message on the same jsp

    Hi guys,
    I have a login.jsp page and I want an error message to be printed "login failed" in the same jsp page when the user enters the wrong credentials.
    Any ideas on how to do that is highly appreciated.
    Thanx in advance.sri

    If you use struts it would have been a lot easier and better than only JSP.
    In struts :
    Add this line in ur JSP page
    <html:errors/>
    In ur Action servlet ex: LoginAction.java add thsi code extract in the appropriate position ...
    ActionErrors errors = new ActionErrors();
    errors.add(ActionErrors.GLOBAL_ERROR, new ActionError("error.user.wrong"));
    if (!errors.isEmpty())
    saveErrors(request, errors);
    But in JSP do something like this:-
    If authentication fails then post to the same JSP and put this code in the reqd position...
    <%
    String postFlag=request.getParameter("postFlag");
    if(postFlag.equals("FAILED"))
    %>
    LOGIN FAILED
    <%
    %>
    So for JSp simply set the request parameter  (postFlag)  to SUCCESSFUL/FAILED  from your servlet.

  • Two AM's with the same name but different forms causes Deployment problems

    Two Masters forms, DOC & PM are cloned except for the "where clause" in the View's query and the titles in their JSP's.
    DOC workspace has a BC project and a BC4JSP Project. The BC project comprises of the EO and VO named ComVsStaticValue. In the Edit prop-> query for the VO I have specified the "where clause" as VSSV_VS_CODE='DOCTOR'.
    In Java Webserver :-
    The JSP's are located in C:\source\Doctor\ .. and the *.xml and *.class files generated by the BC proj is in C:\source\Doctor\pol_ValueSet\..
    If I execute Doctor in JWS the records are getting filtered properly.
    PM workspace has a BC project and a BC4JSP Project. Again The BC project comprises of the EO and VO named ComVsStaticValue. In the Edit prop-> query for the VO I have specified the "where clause" as VSSV_VS_CODE='PAY_MODE'.
    In Java Webserver :-
    The JSP's are located in C:\source\PMode\ .. and the *.xml and *.class files generated by the BC proj is in C:\source\PMode\pol_ValueSet\..
    If I execute PM in JWS, the PM's JSP comes (the title is correct) but the records pertaining to DOC appears. I checked the View's xml file in C:\source\PMode\pol_ValueSet\ the "where clause" is correct. The xml & classes have the same name but their contents are different.
    I want to know whether this problem is because both have the same name for the AM and the BC4JSP's property file.
    Please clarify.

    Deploying two app modules with the same name will definitely cause problems.
    The JSPs use the information in the properties file to connect to the application module and get the data they need from the appropriate View Objects in those app modules. If you have two app modules with the same name, when a JSP tries to connect, it has no way of knowing which one of the app modules to connect to if they both have the same name.
    You could:
    1. Just use one application module that contains all the View Objects you need to access.
    or
    2. Rename one of the application modules or the package it is located in so the names are distinct. If you choose this method, you will also need to update the JSPs (specifically the 'registerApplicationFrompPopertyFile' method call), and your JSP project's appmodule property file.

  • Two managed beans in same jsp page

    Hello
    First this could be a stupid question, but i just can't find a solutions on this problem.
    I wondering that could it be a two managed beans in same jsp page, here is a example:
    index.jsp
    <t:commandLink disabled="#{listBean.currentPage == 1}" id="previous2" type="button" immediate="true" style="font-size:small" action="#{listBean.previousPage}">
    <h:outputText value="Edellinen" id="prev"/>
    </t:commandLink>
    <t:commandLink disabled="#{listBean.currentPage == listBean.totalPages}" id="next2" type="button" immediate="true" style="font-size:small;" action="#{listBean.nextPage}">
    <h:outputText value="Seuraava" id="next"/>
    </t:commandLink>
    then i have a dataTable like this:
    <t:dataTable value="#{customerListBean.customerBeans}"
    binding="#{customerListBean.dataTable}" preserveDataModel="true" style="text-align:left">
    My problem is that when i push a commandLink it doesn't refresh a dataTable. Does anyone know a solution here or is this just a impossible way to do it?
    Thanks for help.

    when i push nextPage (commandLink) it's call action
    and count a new range of dataset and after that it's
    calls a method which is declared on subClass and that
    method get a new data of database on given params.
    and put it on DataTable.
    So listBean is upper class and customerListBean
    extends on ListBeanNo, it doesn't work that way as you expected. You have created two independent instances. They doesn't communicate automatically with each other or so. Just use one CustomerListBean instance and call the inherited methods of ListBean on the #{customerListBean} managed bean instance.

Maybe you are looking for

  • The work area itab is not enough

    HI all, i have written the following code to print data from yemptab But i'm gettin an error saying that "the work are itab is not enough ". can anyone please guide me here. i'm a fresher in abap. REPORT  YEMPDETAILS. TABLES: YEMPTAB. DATA:  BEGIN OF

  • Mass Download of Originals

    Hi all Is there any way to mass download the Originals from the following scenario - from cv04n by selecting multiple DIRs Regards Aby

  • Lens Profile Creator and Astronomical Telescopes

    I'm interested in using the Lens Profile Creator with astronomical telescopes for astrophotography. Using the checkerboard to create a profile would be problematic because you can't come to focus on close objects and really need to be focused at infi

  • 27" iMac stability issues, also stuck on 10.6.3, won't upgrade to 10.6.4

    Hi, we have a 27" iMac that is running 10.6.3 and is having stability issues. It's the Core i7 model, 8GB RAM, 1TB HDD - real nice machine. It was purchased this summer - but it's *not the absolute latest* model. The issues revolve mostly around iPho

  • Zones jumpstart

    is there a possibility to jumpstart zones? Say, I want to run a hosting with root access, Is it possible to create a zone, preconfigure it, install additional apps, and the to copy it? Is there a migration mechanism for zones? Can I save a zone on on