Navigate between pages in JSP

i have multiple .jsp pages. in the sequence of
login.jsp-->DiaryPages.jsp-- EITHER-Open.jsp OR read.jsp
now what i get is i am able to go to "DiaryPages.jsp" from 'logIn.jsp" using <jsp:forward page = "DiaryPages.jsp"> but in "DiaryPages.jsp" when i use <jsp:forward page = "Open.jsp"> or <jsp:forward page = "Read.jsp"> to go to either of these pages ,depending upon a few conditions , i still get redirected back to log in page
so forward tag is kinda working here like a toggle here between first two pages and it's completely ignoring the forward tag in the second file, what am i doing wrong here ? any help --------------Please

One suggestion - consider using Struts framework. You can control the flow of the application from an XML configuration file and don't have to have such logic in the JSP itself.

Similar Messages

  • View Link and and navigate between pages problem...

    Hi, everyone! Hope someone can help with my problem. In DB I have one table with informationa about Employees and Jobs. From this one table I made one EO from which I made 2 VO - EmployeeVO and JobsVO. I link these two VO with ViewLink - EmpJobVL (1 to 1 realtionship).
    Then I created 2 .jspx pages. In one page I droped EmployeeVO but in second page I droped JobsVO. In page template I put button with which I can navigate between these two pages.
    The problem is... when I run my employee page and navigate to correct record with "next" button and then try to navigate to jobs page then in jobs page I can't see correct record. I always see there first record. Why it is so and what can I do?
    Hope that someone helps me,
    Best regards, Debuger!

    Hi Debuger,
         No probs, U can keep ur Jspx as such u just need to clean up ur PageDefs..... Dont struggle more urself its such a easy job...
         Delete all ur page def entries and then have a copy of ur jspx coding in a notepad and delete that too....
    make ur jspx and page def a fresh one re-drag ur VOs and paste ur jspx codings again
    Ur VOs will get binded automatically......... :)
    Regards,
    Suganth.G

  • Oracle OAF Row Reference when navigate between Pages

    Hi,
    I have a requirement where i have PAGE A with multiple rows.For each row there is a button, when i click the button i am calling the PAGE B.
    On PAGE B i am entering some values ,on returning to the PAGE A i need to assign those values(Entered on PAGE B) to the row from where i called the PAGE B
    Code in PFR
    =============
    I am using the below lines  under the Click even of the PAGE A Button
               String rowref = pageContext.getParameter(OAWebBeanConstants.EVENT_SOURCE_ROW_REFERENCE);
                 OARow ref_row = (OARow)am.findRowByRef(rowref);
    But how i can refer this  in the Process Request of the PAGE A when i return from PAGE B?
    Thanks
    Kiran

    Hi,
    This you may have to track the row which you have updated based on some unique id in the vo and for the same id once you come back..you need to populate the VO.
    But my question..cant you handle the first page VO in the second page itself and populate/update the required vo attributes and save.
    So automatically it will come in the first page.
    Thanks
    Bharat

  • Teamviewer changing lists as navigate through pages-probl for anyone else?

    Hi All,
    We're using R/3 4.7, ESS 50.4 and MSS 6.1.20.  After much correspondence with SAP we have discovered that the teamviewer does not behave the way we thought/want it to.
    Basically as the teamviewer is applied on a page basis, each page gets their own teamviewer.  In our teamviewer we have 3 distinct lists of employees.  So if on one page you were looking at list 2 and you navigate to a different page, we expected to be on the same list.  Unfortunately, if the teamviewer on the new page was previsouly looking at a different list, say list 3, the employees for list 3 would be displayed.
    This is not what we want.  In essence we want the teamviewer to work off the MY Staff workset, so that when you navigate between pages, the teamviewer will remain on the same employee in the same list.  This to me is the most user friendly way and the way that makes the most sense. 
    If a manager wanted to view data for a single employee from a number of pages, (s)he could quite possibly have to reset the teamviewer on each page and select the employee again.  This is totally unacceptable..
    Has anyone else been bothered by this?  Did anyone come up with a solution?  I can't believe that this issue has not arisen before.  I would be interested to hear similar stories.
    Many Thanks,
    Liz.

    After much correspondence with sap, this is infact the expected behaviour on the team viewer

  • SWF flickers/flashes when moving between pages

    IDCS4 export to SWF with page transitions. Not sure if anyone else is having this problem, but when I navigate between pages, the interactive items/buttons seem to flash or flicker once after each transition.
    Does anyone know how to resolve? I'm building a small booklet in IDCS4. Nothing fancy about it, just a few pages that I want the viewer to be able to navigate through. The flickering is driving me nuts and I can't seem to figure out why it's happening. I've tried just about every setting, searched the net and have found nothing on the subject.
    Any help would be greatly appreciated. Thanks in advance!
    Mark

    Happens with all transitions. Seems to be a bug and I've sent my notes to Adobe. Other posting can be found
    here.
    Hopefully they'll fix it in the future, 'cause it's a great feature.

  • How to open and navigate between human task forms in a same page?

    Hi
    I use Oracle BPM 11.1.1.5
    I have a question about taskflows in BPM Application.
    In ADF web application, I create a sipmle task flow and insert view id and bind these to jspx pages, my pages are opend in same page when
    return an outcome.
    For exapmle I have three pages like A,B,C.
    In task flow, insert three view ids and bind to A,B,C.
    My first pages is A, and when outcome is B navigate to B, when my outcome is C then navigate to C in a same page not separate pages.
    But my problem is here.. in BPM Application when create task forms, every task has a separate task flow that there exist a single view id and a wild card flow in it.
    In BPM workspace when initiate human task form is closed, I should press refresh button to see next human task form in task list table.
    I tried to create a simple task flow and insert human task forms in it and navigate between these.. but show human task form in wrong display and don`t show some component and human task payload.
    Now, my question : How to open and navigate between human task forms in a same page like software installation?

    Having a separate Data Control for each human task is normally the case. There is a way to assign multiple human tasks to a single data control (and one task flow), but I don't think that this is going to help you with what I think you're trying to do.
    If your human task is called "EmployeeDetail", then you'd use the data control associated with this for the UI pages in the task flow diagram that is associated with this human task. For example, you might have a first page that has just the basic employee information - the fields (at least the ID field) would come from the EmployeeDetail data control. When the end user clicks "Next", you might have this UI page flow to a second UI page in the task flow diagram that has the employee's address information. You might place the address fields from the EmployeeDetail data control onto this second UI page.
    You might be asking how the work item instance can automatically flow to the next interactive activity in the process while staying inside the first interactive activity's human task's task flow diagram. This is not how it works - the task flow diagram models the end user interaction while inside a single human task that is tied to a specific interactive activity in the process. If you want a the end user to be able to move the instance through multiple interactive activities in the process in one interaction, look at "Activity Guides". Activity Guides do a nice job of this.
    Dan

  • About navigate between ie pages in web dynpro for abap

    hi, all
      I want navigate between views, but the view in two ie page.
      How can i do it?
      Thanks for your help!

    hai Sapian,
    To navigate between two views you have to create navigation link between two views.First create inbound and outbound plugs for two views.
    Then in the window u embed the two views.u have to right click the outbound plug of first view and create navigation link.In the information box that comes u give the inboung plug of second view.Now the navigation link is created.
    Then suppose u design like, on clicking a button in first view u want to navigate to second view.For that button, create action.In the method that comes automatically after u create action, u just create a code, by code wizard for calling the second view.
    In the action method u click code wizard and check start navigation .select the outbound plug of first view and enter. code is written automaticaaly to call second view.The generated code will look similar to this.
    WD_THIS->FIRE_TORESULT_PLG(
    Reward me if helpful
    S.Ramesh

  • Difference between page and include in jsp

    difference between <%@ page import="foo.*"%> and <%@include file="foo.*"%> in jsp

    The one imports a class for the code and the other includes a resource for the output. Those are in no way comparable with each other.

  • Propagation of ctx between EJB and JSP

    Hello,
    Does anybody know how to propagate the Security
    Context between EJB and JSP so that when I login in my JSP page the user will be after recognized in my EJB system ?
    Thanks
    Francesco

    try this...as a test..
    take a simple Contact ejb (as simple as you can make it, just a name and email address). In the ejb-jar.xml set up a role, for example, user, and restrict the access to only this role for all methods.
    try to access the ejb from a jsp, and you should get the login form identified in your web.xml file.
    make sure that the ejb is noted in the web.xml file, also.
    this should work...
    no try this...identify a role in your web.xml file, (user, for example) and restrict the access to the a particular jsp which is not calling the ejb. IF you navigate to this jsp, you should get the login prompt...
    this should work....
    now the tough part
    in your application.xml create a role with the same name, user. By doing this, you have created a global role, and connect the two together.
    Now point your browser to the restricted jsp with no calls to the ejb...you should get the login, so login in.
    now navigate to your jsp which is unrestricted, but calls the restricted ejb...
    there should now be no login prompt.
    This should work.

  • When clicking on links that open in a new window, the links don't open and Firefox freezes in a way. I can navigate the page I am on but cannot click to open a new tab or bookmark.

    When navigating the internet, if I come across a web page that has a link to open a picture or program in a new window, if I click on it, it does not open. Firefox immediately looses functionality in that I cannot open a new tab with the mouse wheel, right click to open a new tab, or use my bookmarks in either the drop down or toolbar to navigate away. I can usually still navigate the page that I am on, for example, (https://loanconsolidation.ed.gov/AppEntry/apply-online/appindex.jsp), when it freezes I cannot click on any of the content at the center of the page but I can still use the links from the list on the far left. For an example of the pictures, (http://www.insect-sale.com/), if you click on "New Arrivals" at the top of the page it takes you to a list of products that can only be viewed by clicking on them. Usually a picture of the item would open in a small window but it does not and Firefox freezes. This has also happen when I try a view a degree audit on a school's website where a program would usually open in a new window. The only thing I have been able to find that still functions properly when this happens is the home page button. I can click on it or use the wheel to open it in a tab just fine, but if I try and go anywhere else I cannot. The only way I can get Firefox back to normal is to use the Task Manager and end the process. Another thing I have noticed, that may or may not be related; is that my Norton Internet Security toolbar, that should show up below the bookmarks toolbar and above the tabs, only shows up about 1 out of every 10 times I open Firefox. Some days it doesn't show up at all. If it does show up and I log into Identity Safe, the autofill for the programed website works, even if the toolbar doesn't show up the next time I open Firefox.

    Go to Tools->Options->Apps
    Here you should see two columns: Content Type on the left, Actions on the right.
    Find and select excel spreadsheet or any other content type in the left column. There should be a corresponding action in the right column. What is it? You can use the drop-down list to select the option you want:
    Always Ask - Firefox will ask each time: What do you want to do with this file?
    Save file - Firefox will save this file to your computer
    Use - Firefox will give this file to the program to open it
    In case of saving, Firefox will either prompt you every time where you want the file to be saved, or save it to the default location. It depends on the preference in
    Tools->Options->General->Download

  • Right way to jump between pages?

    I am in trouble to find the correct way to jump between pages,I have a page alluser.jsp,
    in which all usergroups and users are displayed,corresponding to every user's item,I
    place a link to delete this user,as below:
    <a href="removeuser.jsp?userName=<%=userName%>">delete</a>
    in removeuser.jsp,after I have completed the task of deleting this user from database,I
    want the client go back to alluser.jsp,where he can find that user has been removed,
    but I have tried three different ways,the first,
    response.sendRedirect("alluser.jsp"),but It displays the old page,seemingly not following
    the logic of alluser.jsp:to fetch data from NOW_BE database,but just displays from the browser's
    cache;
    the second,
    <jsp:forward page="alluser.jsp"/>,but it will forward the parameter userName onto the
    alluser.jsp,which doesn't need any parameters,as result,in browser's location bar,I see
    ..../alluser.jsjp?userName=...,now I cannot refresh the page,because the browser will
    prompt me whether to resend the request info to refresh the page;
    the third,I simply use
    javascript:location="alluser.jsp",but I got the same result as the first approach
    now I have been driven crazy,on earth what is the good way to do these?
    Please help me,thanks in advance

    Instead of having 2 jsp forms, the processing can be done in the same form - "alluser.jsp".
    The code below explains as to how this can be implemented.
    The ResultSet gets updated without the deleted user.
    <%
    String message="";
    String userid =request.getParameter("USER_ID");
    if(userid == null)
    userid="";
    else
    int delusercon=user.del_user_con(userid);
    int deluser=user.del_user(userid);
    String username=request.getParameter("username");
    message=username + " "+ "has been cancelled!";
    list=user.get_pendinguser();
    }%>
    <form>
    <%=message%>
    <%while(list.next()){%>
    <table><tr><td>
    <div align="center"><a href="alluser.jsp?USER_ID=<%=list.getString( userid)%>&username=<%list.getString(username)%>">
    <B><FONT FACE="Verdana, Arial, Helvetica, sans-serif" SIZE="2">
    Deny</FONT></B></a></div>
    </td></tr></table>
    <%}%>
    </form>
    Hope this helps!!

  • Pass values between pages

    Hello experts!
    I am trying to pass value between two pages without page submit.
    I set item value from first page to session state by dynamic action. Then I am trying to pass this value to second page, I use button which redirects to second page and sets item value on second page with value from first page.
    But approach this does not woks as I expected. The value from the first page is not passed to the second page when I click on button. Value is passed to the second page only if I:
    1. set some value to item on first page (e.g. XX);
    2. click on button which redirects to the second page;
    3. get back to first page;
    4. set some new value to the item (e.g. YY);
    5. click on button;
    6. then the first value from session state is passed to sthe econd page (value XX)
    Could anybody tell me where I make a mistake, or what is wrong in my solution?
    Test appl.
    www.apex.oracle.com
    http://apex.oracle.com/pls/apex/f?p=9027:LOGIN_DESKTOP:6946284921064
    workspace: kurintest
    username: [email protected]
    passwd: kurintest
    appl: 9027 pass_value
    Thanks in advance!
    Jiri

    Jiri N. wrote:
    Hello experts!
    I am trying to pass value between two pages without page submit.
    I set item value from first page to session state by dynamic action. Then I am trying to pass this value to second page, I use button which redirects to second page and sets item value on second page with value from first page.
    But approach this does not woks as I expected. The value from the first page is not passed to the second page when I click on button. Value is passed to the second page only if I:
    1. set some value to item on first page (e.g. XX);
    2. click on button which redirects to the second page;
    3. get back to first page;
    4. set some new value to the item (e.g. YY);
    5. click on button;
    6. then the first value from session state is passed to sthe econd page (value XX)
    Could anybody tell me where I make a mistake, or what is wrong in my solution?A redirect button and it's target URL&mdash;including items to be set and their values&mdash;are rendered on page show, in this case before <tt>P2_ITEM1</tt> has a value. Look at the page source when the page is first rendered:
    <input type="button" value="Button1"onclick="apex.navigation.redirect(&#x27;f?p=9027:3:11397156385140::NO:RP,3:P3_ITEM1:&#x27;);" id="P2_BUTTON1"  />No value substituted for <tt>&P2_ITEM1.</tt> in the URL.
    Why do you want to navigate between these pages without a page submit? As APEX has to render page 3 anyway, why not submit and branch?

  • Navigation between pages

    Dear All,
    A few days ago i started to work with webcenter portal and i have a problem:
    My use case:
    I have 2 pages(both based on default template), each of them contains single task flow with single page fragment:
    page1 - contains task flow tf1.xml with page fragment view1.jsff
    page2 - contains task flow tf2.xml with page fragment view2.jsff
    I need to navigate between this 2 pages with custom buttons(or links) which have to be created inside page fragments.
    I added both pages to default-navigation-model.xml and after running the application i am able to navigate between them using links, which template creates dynamiclly(taking all the default-navigation-model's content into iterator and creating navigation links on page load).
    The code from template file(skipping the iterator):
    <af:commandLink id="pt_cl1" text="#{node.title}"
    inlineStyle="font-size:small;#{node.selected ? 'font-weight:bold;' : ''}"
    action="pprnav"
    disabled="#{not node.navigable}"
    actionListener="#{navigationContext.processAction}"
    clientComponent="#{node.attributes['Target'] == '_popup' ? true : false}">
    <!-- pass node to processAction for setting current selection and navigation -->
    <f:attribute name="node" value="#{node}"/>
    all this works just fine.
    Now i need to create a button in my view1.jsff(page fragment from first task flow on page1) , which would navigate me to my second page.
    I am able to do this with goLink setting
    navigate="#{naviagtionContext.defaultNavigationModel.node[page2].goLinkPrettyUrl}", but this reloads the whole template what i don't need, and also i would like to add some actionListener to this link or button later so i need to navigate using commandLink or commandButton.
    The example from page template doesn't work for my pages:
    My commandLink looks like this:
    <af:commandLink id="pt_cl1" text="Go page 2"
    action="pprnav"
    actionListener="#{navigationContext.processAction}"
    clientComponent="false">
    <f:attribute name="node" value="#{navigationContext.defaultNavigationModel.node['page2']}"/>
    </af:commandLink>
    but second line - action="pprnav" throws some empty screen and nothing else happens(guess it's because there is no partial page refresh in this case).
    Without this line it works, i was able to insert some output text fields in my page and see, that the value of
    #{navigationContext.defaultNavigationModel.currentSelection.title} is changing properly(when i removed the action="pprnav" line, of couse without it navigation itself does not happen).
    If i drop taskflows into my default-navigation-model.xml, skipping the pages action="pprnav" work fine(no empty screens appear and navigation happens), but i need to use the pages.
    Is there any replacement to action="pprnav", to be able to navigate between these two pages?
    Or may be there is another method to do this, which i couldn't find in Google?
    BR,
    Artur

    It's an old thread, but I keep running into this issue every now and then.
    The clue is:
    Any task flow that uses the navigation model to trigger navigation within an application must include a parent-action activity named "wcnav_parentAction" in the task flow definition that propagates the "wcnav_outcome" to the root level, as follows:
    <parent-action id="wcnav_parentAction">
    <root-outcome>wcnav_outcome</root-outcome>
    </parent-action>
    See the following Support note:
    Invoking A WebCenter Page From ADF Taskflow Failing In WebCenter 11.1.1.6 and Opens an Empty Popup Window [ID 1450568.1]
    Jaap

  • Switching between Design and JSP tabs add code?

    I am new to SJSC and I am taking the time to go through all of the little odds & ends of the IDE.
    I was looking at:
    http://blogs.sun.com/roller/page/tor?entry=computing_html_on_the_fly
    And I decided to try this.
    When I add the following in the JSP tab:
    <h:outputText binding="#{Page1.tableHtml}" id="outputText1"/>Save.
    Then click on the Design tab, then go back to the JSP tab, I now have:
    <h:outputText binding="#{Page1.tableHtml}" id="outputText1"/>
    <h:outputText binding="#{Page1.outputText1}" id="outputText1"/>It's late here, but this doesn't make any sense, why would switching between Design and JSP tabs add code?
    Thanks,
    --Todd                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    Girish: I followed these steps:
    1.) Downloaded:
    Sun Java Studio Creator 2, Multilanguage creator-2-windows-ml.exe 254.23 MB
    2.) When I started the install, I received the message:
    Welcome to Sun Java(TM) Studio Creator 2! You are installing: Sun Java Studio Creator 2 development environment Sun Java System Application Server Platform Edition 8.1 2005Q1 Update Release 2 Bundled database
    3.) Installed version:
    Product Version: Java Studio Creator 2 (Build 060120)
    IDE Versioning: IDE/1 spec=5.9.1.1 impl=060120
    Also, Under, the Palette window: Standard component list, there is a component labeled Output Text.
    When placed on a jsp, the following code is produced:
    <h:outputText binding="#{Page1.outputText1}" id="outputText1" style="position: absolute; left: 24px; top: 48px"/>Thanks,
    --Todd                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Navigate between records, ViewLink problem...

    Hi, all! I will try to explain my problem. If something is not clear the pleas let me know.
    So, I have two VO: UzglabasanasDati and VidesDati. These VO have related with VL (UzglabasanasDati_VidesDati1) with 1 to 1 relationship. When I open UzglabasanasDati VO then I can navigate records, please see: http://my.jetscreenshot.com/2677/20110427-gqjl-85kb
    But when I open VidesDati VO the I can't navigate between records, pleas see: http://my.jetscreenshot.com/2677/20110427-6dvw-89kb
    In my case I need that when I open UzglabasanasDati Form (jspx page) then I can navigate records and then go to the correct VidesDati Form (jspx page) record (this I can do with my created VL UzglabasanasDati_VidesDati1) BUT I also need to navigate on the other hand - open my VidesDati Form, navigate between records and then go to UzglabasanasDati Form correct record. (This I can't do with the same VL UzglabasanasDati_VidesDati1).
    I do not understand where I am wrong? :( And what to do to resolve this problem? If You need more information, let me know.
    Hope for Your help, best regards, Debuger!

    Hi,
    I think that things are bit confused here,
    First of all if you are already filter VidesDati from UzglabsanasDati, you cannot see other rows than the ones pointing to UzglabsanasDati.
    That is why you cannot do the opposite filter. The first is already filtered.
    To my Opinion, you need Another Two different ViewObjects with the opposite Link.
    With Both Links on the same VOs, you will always have a VO filtered as a child.
    Hope this Will Help You
    Regards,
    Dimitris.

Maybe you are looking for