3 Replies Latest reply: Sep 6, 2007 9:50 AM by 528699 RSS

    Providing an ADF faces application with help

    57430
      We have an application made with adf faces and we would like to provide it with that nice OHW help. Can someone direct me to some simple example of preparing the help and incorporating in into the application.
      Thanks in advance.
      Tzvetan
        • 1. Re: Providing an ADF faces application with help
          266674
          Hi Tzvetan,
          If you are using Oracle JDeveloper (for example, version 10.1.3.2.0), this is very easy.

          First, you configure your application to be aware of the OHW servlet. You do this by adding an oracle-help-servlet-url element in your adf-faces-config.xml file that points to your OHW URL like this:
          <oracle-help-servlet-url>http://localhost:8888/ohw-demo/mykillercontent/</oracle-help-servlet-url>

          Then, on each page, you can bind links to a specific topicid in your help system. For example, if you want to create a global Help link to all your application's pages, you can create a JSF page called foo.jspx and drag an ADF Faces Core panelPage component onto it. On this page template you can add a menuButtons component to the menuGlobal facet and drop a goMenuItem on top of the menuButtons component.

          Next, set the destination for your goMenuItem (or any other component for which you can specify a destination) to any topicid in your helpsystem by invoking the Bind to Data editor and drilling down into adfFacesContext.helpTopic. A sample destination could be adfFacesContext.helpTopic.foo (where foo is the topicid of your specific topic).

          When you run the page and click on the Help link (the goMenuItem), it will bring up the help topic in OHW. You can save this as a template that you can use for other pages in your application.

          Hope this helps.

          Regards,
          Peter
          • 2. Re: Providing an ADF faces application with help
            528699
            Peter,

            Your answer is really useful for me.
            I am using Oracle JDeveloper 10.1.3.2.0.
            But I have some question need your help:

            1. It seems there is a help system in somewhere (“http://localhost:8888/ohw-demo/mykillercontent/”)
            I will appreciate if you can give the step to build the help system.
            2.It seems the help system need to be startup separately with the web application.
            3. If the ADF web application is deployed to Oracle Application Server, do I need to deployed the help system to the same server also?
            4.How can I integrate the Help System with the ADF web application?

            Peter Moh
            Thanks.
            • 3. Re: Providing an ADF faces application with help
              528699
              I have add a helpset into demo-bundle's helpset (Also I add it into ohwconfig.xml under helpbooks).
              I test the help system with (url http://http://172.21.111.191:8888/ohw-demo/help/). The new added helpset works correctly.
              Then I add "<oracle>
              http://localhost:8888/ohw-demo/help/?topic=ohff_ohw_convert_html
              </oracle-help-servlet-url>"
              into my application's adf-faces-config.xml. And I add a goMenuItem into an exist menuBar.
              I set the destination for the goMenuItem to #{adfFacesContext.helpToipc}

              When I run the application, it starts. But when I clicking on the goMenuItem, the browser's address changes to
              "http://172.21.111.191:8992/RDR-ViewController-context-root/faces/app/j_security_check"

              Errors message displays:

              500 Internal Server Error
              java.lang.ClassCastException: oracle.adfinternal.view.faces.el.HelpProvider$HelpSystemMap     
              at oracle.adfinternal.view.faces.uinode.bind.URLBoundValue.getValue(URLBoundValue.java:31)     
              at oracle.adfinternal.view.faces.uinode.UIXComponentUINode.getAttributeValueImpl(UIXComponentUINode.java:392)     
              at oracle.adfinternal.view.faces.uinode.UIXComponentUINode.getAttributeValue(UIXComponentUINode.java:127)
              ......