Error in page navigation

I have a login page which navigates to the next page ones logged in and i have to validate that only a single user can login i.e, the same username and password is valid. If not an error message is displayed that the login data is not valid. I have done it as below:
if(this.getUserName().getValue()=="abcd" && this.getPassword().getValue()=="1234"){
userName=this.getUserName().getValue().toString();
password=this.getPassword().getValue().toString();
ADFContext.getCurrent().getSessionScope().put("userName",userName);
ADFContext.getCurrent().getSessionScope().put("password",password);
else{
FacesMessage msg = new FacesMessage("Please check your login data");
msg.setSeverity(FacesMessage.SEVERITY_ERROR);
FacesContext.getCurrentInstance().addMessage(null, msg);
But the error message is being displayed in the next page instead of getting displayed in the same login page on hitting the login button. Can any one help me where I am going wrong.? thanks!

i dont know how you perform navigation.
in adfc-config
based some condition you can do that.
<view id="HomePage">
    <page>/HomePage.jspx</page>
  </view>
  <view id="SupplierAppIndex">
    <page>/Index.jspx</page>
  </view>
  <control-flow-rule id="__5">
    <from-activity-id id="__6">HomePage</from-activity-id>
    <control-flow-case id="__7">
      <from-outcome id="__13">success</from-outcome>
      <to-activity-id id="__8">Index</to-activity-id>
    </control-flow-case>
    <control-flow-case id="__14">
      <from-outcome id="__16">error</from-outcome>
      <to-activity-id id="__15">HomePage</to-activity-id>
    </control-flow-case>
  </control-flow-rule>
  <managed-bean id="__1">
    <managed-bean-name id="__3">HomePage</managed-bean-name>
    <managed-bean-class id="__2">com.rits.suplr.view.backing.HomePage</managed-bean-class>
    <managed-bean-scope id="__4">session</managed-bean-scope>
    <!--oracle-jdev-comment:managed-bean-jsp-link:1HomePage.jspx-->
  </managed-bean>
  <managed-bean id="__10">
    <managed-bean-name id="__12">Index</managed-bean-name>
    <managed-bean-class id="__9">com.rits.suplr.view.backing.Index</managed-bean-class>
    <managed-bean-scope id="__11">backingBean</managed-bean-scope>
  </managed-bean>here can see homepage dologin() methods return value "success" means it return index or else stay in homepage.

Similar Messages

  • CrystalReportViewer - Setting parameter throws ancestor error on page navigation

    We are having web application reports in the application using BO-XI SDK Viewer API. This API approach was working fine earlier. We upgrade our reporting component to SAP BO-4 (Crystal Server 2011) due to EOL of BOXI.
    We have updated new API’s provided by SAP as per guide.
    We updated web based Crystal Report Viewer (DHTML Viewer). The crystalreportviewer folder coming with SAP CS 2011.
    We applied updated patch set upto last patch released CS2011 SP4 Patch4.
    We still facing issue while viewing report in DHTML viewer provided by SAP. Please advice on below.
    In our web application we do have updated folder for /crystalreportviewer.
    We dynamically creating enterprise session object to get client document which explained as below –
    IEnterpriseSession es = null;
    try{
    es = sm.logon(mUser, mPassword, mAPSName, mAuthType);
    }catch(Exception e){
    // request dispatched to error page
    // Get the Report Application Factory service from Crystal Enterprise
    IReportAppFactory rptAppFactory = (IReportAppFactory)es.getService("", "RASReportService");
    // Get the InfoStore service from Crystal Enterprise
    IInfoStore infoStore = (IInfoStore)es.getService("", "InfoStore");
    IInfoObjects oInfoObjects = infoStore.query(“Select * From CI_INFOOBJECTS…for RPT File.”);
    ReportClientDocument clientDoc = rptAppFactory.openDocument((IInfoObject)oInfoObjects.get(0), 0, objLocale);
    Setting parameter
    // Setting Parameter to clientDoc
    Object[] parameters = { 
                                                    parseDate(fromDate),
                                                    parseDate(endDate),
                                                    getLanguageID(request),
                                                    reportName,
                                                    getLanguageID(request)
    Fields parameterFields = clientDoc.getDataDefController().getDataDefinition().getParameterFields();
    for(int index=0; index < parameters.length; index++){
                    ParameterField oldParameter = (ParameterField)parameterFields.getField(index);
                    ParameterField newParameter = (ParameterField) oldParameter.clone(true);
                    newParameter.getCurrentValues().removeAllElements();                                                   
                    ParameterFieldDiscreteValue newDiscreteValueObj = new ParameterFieldDiscreteValue();
                    newDiscreteValueObj.setValue(parameters[index]);
                    newParameter.getCurrentValues().add(newDiscreteValueObj);
                    ParameterFieldController paramController = clientDoc.getDataDefController().getParameterFieldController();
                    paramController.modify(oldParameter, newParameter);
    // Create an  Viewer
    CrystalReportViewer viewer = new CrystalReportViewer();
    //Set the name for the interactive viewer
    viewer.setName("Crystal_Report_Viewer");
    viewer.setDisplayPage(true);
    //Set Navigation button false
    viewer.setHasHistoryNavigationButtons(false);
    //Set best fit to page true
    viewer.setBestFitPage(true);
    // Set reuse parameter on referesh
    viewer.setReuseParameterValuesOnRefresh(true);
    // Set Own Page true
    viewer.setOwnPage(true);
    // Enabled export and print button
    viewer.setHasExportButton(true);
    viewer.setHasPrintButton(true);
    // Group Tree Removed
    viewer.setDisplayGroupTree(false);
    // Toggle group false
    viewer.setHasToggleGroupTreeButton(false);
    //viewer.refresh();
    // Removed refersh button
    viewer.setHasRefreshButton(false);
    viewer.setPrintMode(CrPrintMode.ACTIVEX);
    // Set the source for the interactive viewer to the client documents report source
    viewer.setReportSource(clientDoc.getReportSource());
    // Retain parameter and set again for pagination in viewer
    setReportURL(viewer,request);
    // Process the http request to view the report
    viewer.processHttpRequest(request, response, getServletConfig().getServletContext(), out);
    //response.flushBuffer();
    // Close client document
    clientDoc.close();
    // Dispose of the viewer object
    viewer.dispose();
    es.logoff();
    Issue we faced?
    a) On Pagination thorws exception in webreportinglog as
    [@APPNAME@] ERROR [[ACTIVE] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'] WebReportLogger.error(62) | Unable to set the ancestors
    com.businessobjects.report.web.json.JSONException: JSONObject["ancestors"] is not a JSONArray.
                    at com.businessobjects.report.web.json.JSONObject.getJSONArray(JSONObject.java:456)
                    at com.businessobjects.report.web.shared.JSONParameter.getDiscreteValueFromJSON(JSONParameter.java:670)
                    at com.businessobjects.report.web.shared.JSONParameter.getValueFromJSON(JSONParameter.java:609)
                    at com.businessobjects.report.web.shared.JSONParameter.jsonToDefaultFieldValues(JSONParameter.java:587)
                    at com.businessobjects.report.web.shared.JSONParameter.getDefaultValues(JSONParameter.java:474)
                    at com.businessobjects.report.web.shared.JSONParameter.toParameterField(JSONParameter.java:872)
                    at com.businessobjects.report.web.shared.ParametersHelper.jsonToFields(ParametersHelper.java:309)
                    at com.businessobjects.report.web.state.ViewerState.restoreCommonState(ViewerState.java:2838)
                    at com.businessobjects.report.web.state.ViewerState.restore(ViewerState.java:2741)
                    at com.businessobjects.report.web.component.ViewerContainer.restoreState(ViewerContainer.java:210)
                    at com.businessobjects.report.web.WorkflowController.loadViewState(WorkflowController.java:418)
                    at com.businessobjects.report.web.WorkflowController.init(WorkflowController.java:393)
    b) On Export / print button nothing happened even request didn’t passed.
    WEB-INF/web.xml entry as below.
    <?xml version="1.0"?>
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
                    <context-param>
            <param-name>crystal_document_view</param-name>
                                    <!-- weblayout : Fills the entire report view pane with the report. There is no grey background -->
            <param-value>weblayout</param-value>
                    </context-param>
                    <context-param>
                                    <param-name>crystal_exception_log_file</param-name>
                                    <param-value>webreportingexception.log</param-value>
                    </context-param>
                    <context-param>
            <param-name>crystal_exception_info</param-name>
                                    <!-- long - Displays the exception information with the accompanying stack trace. -->
            <param-value>long</param-value>
                    </context-param>
                    <context-param>
                                    <param-name>crystal_image_uri</param-name>
                                    <param-value>/TangibleWebApp/crystalreportviewers</param-value>
                    </context-param>
                    <context-param>
            <param-name>crystal_image_use_relative</param-name>
            <param-value>webapp</param-value>
                    </context-param>
                    <context-param>
                                    <param-name>crystal_processing_indicator_delay</param-name>
                                    <param-value>100</param-value>
                    </context-param>
                    <context-param>
                                    <param-name>crystal_use_asynchronous_requests</param-name>
                                    <param-value>false</param-value>
                    </context-param>
                    <context-param>
                                    <param-name>crystal_servlet_uri</param-name>
                                    <param-value>/TangibleWebApp/CrystalReportViewerHandler</param-value>
                    </context-param>
                    <servlet>
            <servlet-name>CrystalReportViewerServlet</servlet-name>
            <servlet-class>com.crystaldecisions.report.web.viewer.CrystalReportViewerServlet</servlet-class>
                    </servlet>
                    <servlet-mapping>
                                    <servlet-name>CrystalReportViewerServlet</servlet-name>
                                    <url-pattern>/TangibleWebApp/CrystalReportViewerHandler</url-pattern>
                    </servlet-mapping>
                    <servlet>
                                    <servlet-name>document</servlet-name>
                                    <servlet-class>com.oreilly.servlet.OpenDoc</servlet-class>
                    </servlet>
                    <servlet>
                                    <servlet-name>InitialServlet</servlet-name>
                                    <servlet-class>com.servlet.InitialServlet</servlet-class>
                                    <load-on-startup>1</load-on-startup>
                    </servlet>
                    <servlet>
                                    <servlet-name>FactorsLogo</servlet-name>
                                    <servlet-class>com.servlet.FactorsLogo</servlet-class>
                    </servlet>
                    <servlet-mapping>
                                    <servlet-name>FactorsLogo</servlet-name>
                                    <url-pattern>/servlet/FactorsLogo</url-pattern>
                    </servlet-mapping>
                    <servlet-mapping>
                                    <servlet-name>document</servlet-name>
                                    <url-pattern>/servlet/document</url-pattern>
                    </servlet-mapping>
                    <session-config>
                                    <session-timeout>30</session-timeout>
                    </session-config>
                    <welcome-file-list>
                                    <welcome-file>/tangible/index.jsp</welcome-file>
                    </welcome-file-list>
                    <listener>
                                    <listener-class>com.common.util.applistener.AppListener</listener-class> 
                    </listener>
    </web-app>
    Thanks in advance for your advice / suggestions.

    Am I right in guessing that you were previously using the ActiveX viewer?
    Currently your code is closing the document and logging off Enterprise.  Pretty much any action that is done in the DHTML viewer will cause a postback to the server which will no longer have the document or session available with your current code which will cause all sorts of problems.  You need to persist these objects, and only clean them up once you are completely finished with them.

  • Error on page when navigating with in webdynpro applications

    Hi All,
    I have developed 5 different webdynpro applications. I need to navigate between these webdynpro applications. I am handling the navigation with in the webdynpro applications.
    The problem is after some time ( after navigating to the second or third level) when I try to click on the tabs(top level navigation), the JAVA SCRIPT ERROR is coming.
    And any other tabs are not coming.
    ERROR is: 'Error on page'
    ERROR Description is:'Problems with the web page might prevent it from being displayed properly or functioned properly'
    Any suggestions are appreciated.
    Thanks & Regards,
    Seshu

    Hi !,
    Please can you tell me what to do if you DO NOT want to destroy the source application when navigating away from it?
    For example...  Webdynpro App #1 calls Webdynpro App #2,
    Webdynpro App #1 will always stay visible and available to the user in there toolbar in the portal.  However after I click "Go" to trigger the navigation to Webdynpro App #2, then the next time I hit "Go", Webdynpro Application was destroyed out of memory I believe.

  • Error on page from BW 3.5's default web template

    Hi Guru's,
    We have a problem in our new BWD BW 3.5 environment where we are getting the "error on page" error from SAP-generated code and we aren’t sure why.
    On our old BWT BW 3.0b platform, we have been using a modified version of the 0query_template called Z_QUERY_TEMPLATE. We did a system copy of BWT to BWD, our new BW 3.5 platform. At that point in time we would see our old BW 3.5 default template for queries that we ran. We wanted to see what the new default web template looked like in BW 3.5. We found where we could remove the Z_QUERY_TEMPLATE from the Web Adhoc Analysis web template setting so we could see the new features of the BW 3.5 default BEx query designer template instead of our old BW 3.0b default template.
    Now when we run a query through the BW 3.5 query designer on BWD, we are using BW3.5’s default template. The prompt web page is fine. No errors on page messages.
    However, the initial presentation of the query results displays okay, but shows "error on page" in the message bar at the bottom of the displayed page. As soon as we do any navigation on those query results that error on page goes away. If we navigate back to the initial presentation, all is still okay. If we use the context menu to go back to start, we again get the error on page.
    This error on page does not happen in BQ2 (our new BW 3.5 QA environment copied from our old BW 3.0b QA environment where we had not yet changed the default BEx Query Designer template to be Z_QUERY_TEMPLATE). We have tried several queries and in each case, we get errors on page in BWD, but not in BQ2. We used ultraedit to compare the view source output from the equivalent web pages from BWD and BQ2 and the only difference is the validity date of the data. There are no other differences in the javascript code generated by BW in the two platforms.
    The statement that Internet Explorer is saying is the problem is the same in each of the cases we have checked and that is:
    SAPBWSetFocus(anchor);
    Error: Object expected
    Code: 0
    It’s in the set_tab() function.
    <script type="text/javascript">
    <!--
    /* Calls the online Documentation via technical QueryName */
    function callquerydoc() {
      var docustart= '/sap/bw/doc/meta/fldmeta/default?tlogo=elem&objnm=' + document.getElementById('querydoc').innerHTML;
      SAPBWOpenWindow(docustart,'Documentation',800,600);
    /* Sets the displayed tab */
    /* Check, which items of the Array check_items  is not hidden.
        Change the style of the HTML tag with id Group+Area/Group+Link */
    function set_tab() {
         if (!(navigator.appVersion.substring(0,1) == '4' && navigator.appName == 'Netscape')) {
           var check_items = new Array('GR1Toolbar','GR2Chart','GR3TECommon','GR4Broadcaster');
        for (i=0;i<check_items.length;i++) {
                        hidden = true;
                       prop = SAPBWGetItemProp(check_items<i>);
                       if (prop != null){
                                           for(j=1;j<prop.length;j++){
                                                      if (prop[j][0] == "HIDDEN")  hidden = (prop[j][1] == "X");
                   anchor_item = document.getElementById(check_items<i>.substring(0,3)+'Area').firstChild;
                    if (hidden) {
                        document.getElementById(check_items<i>.substring(0,3)+'Area').className='SAPBEXTbsTab';
                        anchor_item.title = 'Inactive Tab Page:' + ' ' + anchor_item.title; 
                    else {
                        document.getElementById(check_items<i>.substring(0,3)+'Area').className='SAPBEXTbsTabSel';
                        anchor_item.title = 'Active Tab Page:' +' ' + anchor_item.title; 
              } /* if */
          }   /* for */
        /* Set the BexHeader invisible when running as IView */
            if (SAPBWGetProperty('RUNS_AS_IVIEW')) {
                               document.getElementById('bexheader').style.visibility='hidden';
                               document.getElementById('bexheader').style.display='none';
              anchor = window.location.hash.substring(1,50);
              <b>SAPBWSetFocus(anchor);</b>
      }  /*function */
    -->
    </script>
    Because the error goes away as soon as we navigate I’m thinking some object isn’t being created or initialized, but since the view source code of these pages are identical I’m wondering if there is some code that should be executing before this page that is not happening in BWD for some reason.
    Any help will be much appreciated.
    Thanks,
    Jeri

    Heike,
    Thanks for your help in this. BWD and BQ2 are both on the same SP. SAP_BW release 350 level 10 (SAPKW35010) with BI_CONT at release 352 level 5 (SAPKIBIEP5).
    I invalidated the server cache following your instructions and tried again, but am still having the same problem in BWD. The initial display gets the "Done, but with errors on page" message until any navigation is done.
    I am using IE 6.0.2900.2180.xpsp_sp2_rtm.040803-2158 when I execute queries on both BWD and BQ2.
    Please, do you have any other suggestions?
    Thanks,
    Jeri

  • 11i Login Page is showing 'Error on Page' while using IE 7

    Hi DBAs,
    I am using Oracle 11.5.10.2 with DB 10.2.0.4 (Single Instance). The EBS is on RUP6 and using JDK 1.6.0_12.
    I was using Firefox and not getting any issue. I used first time IE-7 (7.0.5x) to access the application. I noticed that Pressing the 'Login' button on Login Page , it was saying in the left bottom of the IE says 'Error on page' and was not navigate to any page or did not perform any action.
    I verified all the services and everything was OK. While using Firefox , I was able to navigate the application w/o any issue.
    Using IE 7 , I am able to access
    http://host.domain:8000/OA_HTML/fndvald.jsp?username=sysadmin&;password=sysadmin
    Most of the stuff seems to be working fine while logging in using above URL but the 'GO' buttons are throwing same error in IE 'Error on page'. Rest of the Bottons like 'Edit Navigator' , 'Edit Favorites' are working fine but when on any Page I press the 'Go' button then IE showing Error. It seems to me that when a button need to navigate to next page then IE saying 'Error on page' but when a button have to lunch a new page it is working fine.
    All the responsibilities and links are working fine. Application Navigation using Firefox is working absolutely fine.
    Seeking your advise and suggestions to resolve the issue.
    Thanks
    -Samar-

    Hi Samar,
    You can clear the cache as follows (login as applmgr user, and source the application env file):
    $ cd $COMMON_TOP/_pages
    $ rm -R *
    ML Note: 285218.1 is not helpful as I am on later version of EBS (11.5.10.2 with RUP6 and Developer6i Patchset 19). At Client side I am using Windows XP SP3 with IE 7.0.5.x with JInit 1.3.21 and JRE 1.6.0.12.Did you review the steps under "Recommended MSIE Browser Settings" section?
    Can you reproduce the issue with JInitiator? If yes, any errors in the JInitiator console window? Enable debug (you may also enable trace for Sun JRE) and see if any errors are reported there.
    Note: 549423.1 - How to enable tracing and logging for Sun JRE (Native Plug-in)
    https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=549423.1
    Regards,
    Hussein

  • Print, Export and Page Navigation Buttons in the Report

    When I view a report through CR4E, the generated report has 3 buttons namely Print, Export and Page Navigation buttons. But when I click on either of the buttons I get a &#39;null pointer exception&#39;. This is a critical error as I am unable to navigate past the first page. Do I have to add code to these buttons? If not, why am I getting an error? Kindly solve my problem as soon as possible.

    <p>Looking at your code it appears that you are storing the ReportSource in session prior to passing in the ResultSet. This will create a problem when a postback is made on  the viewer page (which all of the viewer actions do). If you look at the sample code which is generated when you use the JSP Page Wizard you will notice that the ResultSet is passed to the ReportClientDocument object prior to it being stored in session. Then, when the page is called again this object is retrieved and the ReportSource is used by the viewer. You can quickly run the test using one of our sample reports to see what I am talking about. The code below was generated using the Consolidated Balance Sheet.rpt and did not experience any problems doing any of the viewer actions.</p><%@page import="com.businessobjects.samples.JRCHelperSample,<br />com.crystaldecisions.report.web.viewer.CrystalReportViewer,<br />com.crystaldecisions.reports.sdk.ReportClientDocument,<br />com.crystaldecisions.sdk.occa.report.application.OpenReportOptions,<br />com.crystaldecisions.sdk.occa.report.lib.ReportSDKExceptionBase,<br />com.crystaldecisions.sdk.occa.report.reportsource.IReportSource,<br />java.sql.Connection,<br />java.sql.DriverManager,<br />java.sql.ResultSet,<br />java.sql.SQLException,<br />java.sql.Statement"%><%<br /><br /><br />    try {<br /><br />        String reportName = "Sample Reports/Consolidated Balance Sheet.rpt";<br />        ReportClientDocument clientDoc = (ReportClientDocument) session.getAttribute(reportName);<br /><br />        if (clientDoc == null) {<br /><br />            clientDoc = new ReportClientDocument();<br />            <br />            // Open report<br />            clientDoc.open(reportName, OpenReportOptions._openAsReadOnly);<br /><br />  <br />            {<br />                // **** POPULATE MAIN REPORT ****<br />                {<br />                     // Connection Info for fetching the resultSet<br />                    String connectStr = "jdbc:derby:classpath:/Xtreme";<br />                    String driverName = "org.apache.derby.jdbc.EmbeddedDriver";<br />                    String userName = "dbuser";        // TODO: Fill in database user<br />                    String password = "dbpassword";    // TODO: Fill in valid password<br /><br />                    String query = "SELECT CUSTOMER_NAME FROM APP.CUSTOMER WHERE COUNTRY = &#39;Australia&#39;";<br /><br />                    <br />                    String tableAlias = "FINANCIALS";        // TODO: Change to correct table alias<br /><br />                     <br />                    JRCHelperSample.passResultSet(clientDoc, fetchResultSet(driverName, connectStr, userName, password, query),<br />                        tableAlias, "");<br />                }<br /><br /><br />            }<br />        <br />            // Store the report document in session<br />            session.setAttribute(reportName, clientDoc);<br /><br />        }<br /><br /><br />            {<br />                // Create the CrystalReportViewer object<br />                CrystalReportViewer crystalReportPageViewer = new CrystalReportViewer();<br /><br />                //    set the reportsource property of the viewer<br />                IReportSource reportSource = clientDoc.getReportSource();                <br />                crystalReportPageViewer.setReportSource(reportSource);<br /><br />                // set viewer attributes<br />                crystalReportPageViewer.setOwnPage(true);<br />                crystalReportPageViewer.setOwnForm(true);<br /><br />                // Process the report<br />                crystalReportPageViewer.processHttpRequest(request, response, application, null); <br /><br />            }<br />            <br /><br />    } catch (ReportSDKExceptionBase e) {<br />        out.println(e);<br />    } <br />    <br />%><%!<br />// Simple utility function for obtaining result sets that will be pushed into the report.  <br />// This is just standard querying of a Java result set and does NOT involve any <br />// Crystal JRC SDK functions. <br /><br />    private static ResultSet fetchResultSet(String driverName,<br />            String connectStr, String userName, String password, String query) throws SQLException, ClassNotFoundException {<br /><br />        //Load JDBC driver for the database that will be queried    <br />        Class.forName(driverName);<br /><br />        Connection connection = DriverManager.getConnection(connectStr, userName, password);<br />        Statement statement = connection.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE, ResultSet.CONCUR_READ_ONLY);<br /><br />        //Execute query and return result sets<br />        return statement.executeQuery(query);<br /><br />}%><p>Try using the code generated from the wizard to see if it works for you as well. </p><p>Regards,<br />Sean Johnson (CR4E Product Manager) </p>

  • JSF 2.0 page navigation vs direct page access

    I've been experimenting with JSF for some time now and I still don't understand the page navigation part. I know that in JSF, if you aren't using the redirect option in navigation that the URL is one page behind the page you are on.
    I've seen articles where people say you should put your pages in a directory under WEB-INF to protect against directly accessing the page. I don't understand how you can create an application that is multiple pages using that option, because won't you run into the problem of having a form with an action URL of WEB-INF/somepage.xhtml?
    I've also read articles that say the way to fix this is to add security-constraints to web.xml that prevent "direct access" to pages, when you want your user to follow a page flow, such as start on page1.xhtml, then page2.xthml, then end on page2.xhtml. If page3.xhtml depends on page2.xhtml, the articles I've read say that a security constraint prevents users from simply requesting page3.xhtml out of sequence.
    And what happens if the page you are on encounters an error or the session times out, which page handles that? The one you're on, or the one from before that forwarded you to the page you're on?
    In this example, should page2.xhtml and page3.xhtml go in the root of the webapps directory, or in a directory under WEB-INF?
    Webapps
      index.xhtml
      page1.xhtml
      page2.xhtml
      page3.xhtml
      WEB-INF
        faces-config.xml
        web.xml
        page-directory
          page2.xhtml
          page3.xhtml

    A session timeout should actually net a view expiry exception.
    You do know that JSF 2.0 made page navigation that bit easier by not requiring you to do the XML configuration? There is now a convention built in plus some new components to add GET enabled requests to the JSF lifecycle (notably h:button and h:link). If you have an action method that returns the following:
    public String doSomething(){
      return "something";
    }then JSF will by default want to render a view 'something.xhtml' when you don't define any navigation rules. If you want to make that a redirect you can do this:
    public String doSomething(){
      return "something?faces-redirect";
    }(of course this is a prime target to turn into a utility method on a backing bean base class).
    Navigation rules are still necessary when you want to put views in a subdirectory, but at least this way you can greatly simplify general cases. Other than that I can only say: research research research because this material is vital to understand if you want to be productive using the framework; navigation and the 6 JSF lifecycle phases are two items you should put on the top of your list to hammer out until you really get it. A good JSF book will help you immensely there. Balusc's blog is also a good source of deeper understanding:
    http://balusc.blogspot.com/
    Most of his articles are on JSF 1.2 but most of the information still applies.
    Oh and its no surprise that you're a bit confused - this framework is not easy to pick up especially when you don't know any other web frameworks. If you keep running into a wall you should consider checking out something else like Wicket or Play framework. It might just be that JSF simply isn't the tool for the job you're trying to do.

  • Page navigation or Auto_incremental php url

    I need a page navigation with links to first previous next and last i know that there is an option to add page navigation through dreamweaver from the inset data tab
    But the problem is that when ever I add the navigation bar to the page and view it in the browser it gives an error with the number of the line which caused the error and when I view that line I find that the codes which were there are deleted.
    the line actually contains some recordset codes which I can't remove as I have worked hard to make them do a specific thing.
    So I decided to creat a navigation bar myself the and i made a url parameter to do that here it is
    .index.php?categories_id=1&pageNum_Recordset1=1
    this link causes the page to show the next set of posts but the problem is it just shows all the posts on the second page as the value of pageNum_Recordset1 on the first page is zero(0)
    Now the portion in the red is the problem I want it to be auto_incremental such that the value of pageNum_Recordset1 should change from 1 to 2 to 3 and so on plz help I thins its qute easy but I m not getting it and I have tried my best to explain the problem but if u r not able to then let me know I will explain again.

    Several components are action components. You can associate these components with action methods. When a user clicks on the action component the page is submitted to the server and the associated action method (if any) is called and the result of that action method (the return value) determines where to go next.
    The hyperlink offers the option of a url or an action handler . If you specify an action handler then the hyperlink works like any action component, as described above.
    However, if you specify a url instead, then the page is not submitted. The server simply serves up the page specified by the url.
    Because the page is not submitted, no action methods or any other methods get invoked.
    Have I explained that clearly?
    If not, here is more information: http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/about_components.html#action
    Chris

  • "Errors on page" with simple JSF page

    Hi
    I wrote a very simple JSF page as shown below. It works as is with MyFaces. Now I tried to make it work with Sun RI as well.
    Here's the problem: The page appears perfectly fine (it shows two columns of links). Only one single link works, though: the first one in the left column.
    When I click on that first link, the action handler method ("userClick") is called and executed fine.
    But when I click on any other link, the method is not called at all. All I get is an "error on page" message in the browser status bar. No log message on the command line or log file.
    Am I doing something wrong? With MyFaces it works fine.
    ===============================
    Here's the page:
    ===============================
    <%@ page language="java" pageEncoding="UTF-8"%>
    <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
    <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
    <f:view>
         <f:loadBundle basename="ca.gc.nrc.iit.eConservatoire.frontend.bundles.MessageBundle" var="bundle" />
         <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
         <html>
              <head>
                   <title><h:outputText value="#{bundle.menu_frame}" /></title>
                   <link rel="stylesheet" href="style.css">
              </head>     
              <body>
                   <h:panelGrid border="1" columns="2" columnClasses="td">
                        <h:dataTable value="#{MenuBackingBean.menuTabItems}" border="0" var="menuTabItem" >
                             <h:column>
                                  <h:form>
                                       <h:commandLink action="#{MenuBackingBean.userClick}" >
                                            <h:outputText value="#{menuTabItem.itemName}" />
                                            <f:param name="itemID" value="#{menuTabItem.itemID}" />
                                       </h:commandLink>
                                  </h:form>
                             </h:column>
                        </h:dataTable>
                        <h:dataTable value="#{MenuBackingBean.menuItems}" border="0" var="menuItem" >
                             <h:column>
                                  <h:form>
                                       <h:commandLink action="#{MenuBackingBean.userClick}" >
                                            <h:outputText value="#{menuItem.itemName}" />
                                            <f:param name="itemID" value="#{menuItem.itemID}" />
                                       </h:commandLink>
                                  </h:form>
                             </h:column>
                        </h:dataTable>
                   </h:panelGrid>
              </body>
         </html>
    </f:view>
    ==================================
    Here's the faces-config
    ==================================
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN" "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
    <faces-config >
         <application>
              <locale-config>
                   <default-locale>en</default-locale>
                   <supported-locale>en</supported-locale>
                   <supported-locale>de</supported-locale>
              </locale-config>
              <message-bundle>ca.gc.nrc.iit.eConservatoire.frontend.bundles.MessageBundle</message-bundle>
         </application>
         <managed-bean>
              <managed-bean-name>DetailsBackingBean</managed-bean-name>
              <managed-bean-class>ca.gc.nrc.iit.eConservatoire.frontend.DetailsBackingBean</managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
         </managed-bean>
         <managed-bean>
              <managed-bean-name>MenuBackingBean</managed-bean-name>
              <managed-bean-class>ca.gc.nrc.iit.eConservatoire.frontend.MenuBackingBean</managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
         </managed-bean>
         <managed-bean>
              <managed-bean-name>ContentBackingBean</managed-bean-name>
              <managed-bean-class>ca.gc.nrc.iit.eConservatoire.frontend.ContentBackingBean</managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
         </managed-bean>
         <navigation-rule>
              <from-view-id>/menu.jsp</from-view-id>
              <navigation-case>
                   <from-outcome>showDetails</from-outcome>
                   <to-view-id>/details.jsp</to-view-id>
              </navigation-case>
              <navigation-case>
                   <from-outcome>menu</from-outcome>
                   <to-view-id>/menu.jsp</to-view-id>
              </navigation-case>
         </navigation-rule>
         <navigation-rule>
              <from-view-id>/details.jsp</from-view-id>
              <navigation-case>
                   <from-outcome>showMenu</from-outcome>
                   <to-view-id>/menu.jsp</to-view-id>
              </navigation-case>
              <navigation-case>
                   <from-outcome>showContent</from-outcome>
                   <to-view-id>/content.jsp</to-view-id>
              </navigation-case>
         </navigation-rule>
         <navigation-rule>
              <from-view-id>/content.jsp</from-view-id>
              <navigation-case>
                   <from-outcome>showMenu</from-outcome>
                   <to-view-id>/menu.jsp</to-view-id>
              </navigation-case>
         </navigation-rule>
    </faces-config>
    =======================================
    I don't think I need to show the backing bean with the userClick() method since the error is that this method is not even called (I added a system.out.println() to this method - which is never executed)
    So the problem must be before
    BTW I am using Sun RI 1.1.01 as shipped with the MyEclipseIDE extensions.
    Thanks a lot for your very much appreciated help
    scrut

    The problem is that you have two forms. Put a single form.

  • Error 404 : page not found

    hi all
    i try to make like this demo:
    http://download.oracle.com/otn_hosted_doc/jdeveloper/11/demos/overview/JDeveloperOverview.html
    i do very thing like it except the change in JavaServiceFacade becaus I don't add any query, only I want insert some data in a table
    the problem :
    when i ry to run my faces the browser display ERROR 404 Page Can't Found
    Any body can help me

    Hi!
    Try selecting some JSPX page in navigator and then click Run (or right click and then select Run). If you edited that facade bean it is big chance that you started Model project instead View.

  • Portlet Page Navigation

    Hi,
    Can we have page navigation in portlet? What I mean to say is, can we have a link inside a WSRP portlet page (A JSF page actually) to navigate to a different JSP/JSF page within the same portlet container? Seems like it only refreshes the same page.
    I am using Oracle WebCenter 11G and created a portlet application and consumed it inside webcenter. The portlet itself works fine, but when I am trying to click on a command link on the same page, it only refreshes the portlet, the actual page transition does not happen.
    Please help.
    Thank you,
    Kanchan Upadhyay

    Hi Yannick,
    I would like to express my gratitude for helping so much!! Following your suggestion ("Performance issue"), I have started using the taskflow thru WebCenter extended application and not as a portlet. I have created .jsff pages (just copied the contents of my old JSPs to them) and created all navigation rules the way a bounded taskflow would expect to be (task-flow-definitions.xml). Finally I created a JSP page and dragged and dropped the taskflow file on the JSP to create a region and use it inside that.
    Now, when I run it, I get the following exception..
    path:/PollingPortlet-PollViewController-context-root spec-version:2.5]] Servlet failed with Exception
    java.lang.NullPointerException
         at oracle.adfinternal.view.faces.renderkit.rich.FormRenderer.encodeAll(FormRenderer.java:234)
         at oracle.adf.view.rich.render.RichRenderer.encodeAll(RichRenderer.java:1369)
         at org.apache.myfaces.trinidad.render.CoreRenderer.encodeEnd(CoreRenderer.java:335)
         at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:751)
         at org.apache.myfaces.trinidad.render.CoreRenderer.encodeChild(CoreRenderer.java:415)
         at oracle.adf.view.rich.render.RichRenderer.encodeChild(RichRenderer.java:2572)
         at org.apache.myfaces.trinidad.render.CoreRenderer.encodeAllChildren(CoreRenderer.java:432)
         at oracle.adfinternal.view.faces.renderkit.rich.DocumentRenderer.encodeAll(DocumentRenderer.java:1066)
         at oracle.adf.view.rich.render.RichRenderer.encodeAll(RichRenderer.java:1369)
         at org.apache.myfaces.trinidad.render.CoreRenderer.encodeEnd(CoreRenderer.java:335)
         at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:751)
         at org.apache.myfaces.trinidad.component.UIXComponentBase.__encodeRecursive(UIXComponentBase.java:1501)
         at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeAll(UIXComponentBase.java:771)
         at javax.faces.component.UIComponent.encodeAll(UIComponent.java:942)
         at com.sun.faces.application.ViewHandlerImpl.doRenderView(ViewHandlerImpl.java:271)
         at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:202)
         at javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:189)
         at org.apache.myfaces.trinidadinternal.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:193)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._renderResponse(LifecycleImpl.java:710)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:273)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:205)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:266)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:191)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:97)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:420)
         at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:420)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:247)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:157)
         at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.wls.DMSServletFilter.doFilter(DMSServletFilter.java:326)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3592)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2202)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2108)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1432)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    SUBSYSTEM = HTTP USERID = <WLS Kernel> SEVERITY = Error THREAD = [ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)' MSGID = BEA-101020 MACHINE = TN-WS722-122 TXID = CONTEXTID = TIMESTAMP = 1269955815847
    WatchAlarmType: AutomaticReset
    WatchAlarmResetPeriod: 30000
    Can you please guide me on this? I am totally clueless as the exception is not coming from any of my class!!
    Another problem that I am facing is, how can I validate users in such applications? What I mean to say is, if a user is logged in webcenter, and is trying to access my application exposed as a taskflow, that user's login information should automatically propagate in my application. For example, I may have an admin link in my application, that should only be available to admin user's and no other user should be able to check it. I am unable to implement such functionality. If you can guide on this, that would be helpful too.
    Many thanks in advance!!
    Thank you,
    Kanchan

  • Previous page navigation after on click of cancel button of a form in adf

    Hi,
    Can any one tell how previous page navigation works in adf?
    I am working on a portal page which is having a common footer for all jspx pages.This footer contains a golink for feedback form.
    so the problem is when I Navigate to any page (# page 1)and then Navigate to some other page (#page 2) and on click of Feedback link displayed on footer of page 2 Feedback form is displayed. and on Click of Cancel button of the form.
    Expected Result:
    User should be navigated to the page that they were on. (i.e., Page 2)
    Actual Result:
    User is navigated to page 1 instead of page 2
    i.e it is taking browser previous url.
    I am using the following code for the cancel button
    <af:commandLink text="Cancel" id="cl5">
    <af:clientListener method="goBack" type="click"/>
    </af:commandLink>
    java script....
    function goBack()
    window.history.back()
    Edited by: 993530 on Apr 23, 2013 3:35 AM

    Hi,
    Immediate = true is already been set for cancel button
    The problem is when i come back to the 1st page vo is getting executed again and is taking lot of time.. i need to see that vo does not get executed again
    in the vo for view criteria -- query execution mode , i have made as in memory and now it has become fast on click of cancel button. But i am getting the following error when i perform search in the first page
    Missing FROM in a SELECT statement
    An unexpected expression token is found.
    Thanks,
    .

  • Error changing pages in default viewer

    I have a simple Struts2 application on which there is a button, which when pressed causes the app to display a report in a viewer.
    Since the application existed already, I added CR using the option in CR4E.  I also used the menu option with default options to create the viewer JSP.  When I go to the page, the report displays, however, when you click on the page navigation control to change pages you get the following error message:
    Unable to process your request
    And the details for this are:
    name: SyntaxError message: Syntax error number: -2146827286 description: Syntax error
    When I use the report in a simple application created from the CR4E wizard, it works just fine.
    Any ideas???
    Edited by: Mike Burroughs on Apr 13, 2009 8:36 AM

    Ok.
    So for your application following things maty help you
    1. Verify that crystalreportviewers/ is accessible to your WebApp and is the correct path to the viewer resources.
    2. You may customize this location by altering the crystal_image_uri and crystal_image)use_relative properties in web.xml.
    3.Validate that the file crv.js exists at  crystalreportviewers/js/crviewer/crv.js
    Thanks,
    Tej

  • Page Navigation Woes

    So I love this tool, and desperately need it for my project. I'm a huge fan.
    BUT - I have troubles with what appeared to me to be a JSF idiom re: navigation.
    I have had to add by hand (in the source view) of my page navigation something like:
    <navigation-rule>
    <from-view-id>*</from-view-id>
    <navigation-case>
    <from-outcome>Home</from-outcome>
    <to-view-id>/index.jsp</to-view-id>
    </navigation-case>
    <And So On... I have several and they are well formed...>
    but in the graphical layout, there is a little red box with an "x" in it, indicating badness.
    Is this:
    a) a bug (it don't do that)
    b) a missing feature (it'll be in version 2.3.4.5)
    c) a bad idea all around (because you shouldn't do it for moral/idealogical reasons)
    Help? Opinions?
    Now the real reason for this (idiomatic mechanism) is to be able to create pages later that can rely on a jspf called something like "MajorLeftMenu.jspf" which has these ActionLinks that can point to the well-known pages in the app that lets you get somewhere directly without having to have explicit links in the page navigation file. Seems like a reasonable design to me, simplifies the page nav file and relies on existing machinery in the built-in nav structure.
    Cheers.

    It does appear to work at deploy (the Fragment stuff I posted is what's holding me up from testing for sure.). Even if there was a glyph that was what you intend to use when you get it enabled that might be better than the error glyph?
    Geary/Horstmann's book Core JSF uses this as a common idiom... (the wildcard in the from-view-thingie)

  • Customer self service form gives the error of  "Page cannot be displayed"

    Hi All,
    Customer self service form from Navigation: Recievables -> Customers --> Standard gives the error of "Page cannot be displayed" but the same form gets opened when i navigate that from Order Management responsibility
    Thanks&Regards,
    APPS DBA

    Hi All,
    I have been trying to install the EBS 11i in configured system core 2 duo with 1 gb ram and 250 gb HDD,
    have been following the below steps to install the EBS 11i,
    1.installed Win20003 server edition
    2.VC++ and copyind the link file into windows\system32,
    3.GNU make done the path set everything,
    4.MKS tool kit,
    5IP config and installing MS loopback,
    started the installtion direct from the DVDs,
    Pre-Installtion everything was OK,
    but after done everything I got struck last min, where the popup window appeared as login page responding but i did wait for 30 min and nothing has happened.
    So closed and I restarted the System and I have restarted process putting 1st DVD and given the command rapidwiz -restart.from command prompt.
    and Again its started as a new installtion, and preinstatltion wizard has came.
    where I haeve commited the mistake i did not understand...?
    Please guide me
    regards
    Satya

Maybe you are looking for