January 26, 2015
Hot Topics:

Implementing AJAX Components in the JWL Framework

  • April 17, 2008
  • By Aleksey Shevchenko
  • Send Email »
  • More Articles »
  1. Run this page on the server (make sure you are running under Websphere 6.1 or higher).

  2. Click here for a larger image.

    Figure 15: Running the Example on the Server

  3. Test your code.

  4. Click here for a larger image.

    Figure 16: AjaxSubmitRequest Example Output

Listing 7 is the full source code of what you have just gone through. You can find full source code as an attachment at the end of this article.

Listing 7: AjaxSubmitRequest Full Source Code

   <hx:scriptCollector id="scriptCollector1">
      <h:form id="form1" styleClass="form">
         <h:inputText id="text1"
         <h:inputText id="text2"
         <h:inputText id="text3"

         <hx:commandExButton type="button"
            <hx:behavior behaviorAction="get;stop"
                         targetAction>="group1" >

         <h:panelGroup id="group1" styleClass="panelGroup">
            <h:outputText id="text4"

         <hx:ajaxRefreshSubmit id="ajaxRefreshSubmit1"
                               target="group1" >

Get External Content <hx:ajaxExternalRequest>

<hx:ajaxExternalRequest> defines how content from a different page replaces the content of the parent tag. Content is retrieved using HTTP GET method. This tag is useful when you want to place one JSP into the content of another one.

The following steps describe how this tag is used:

  1. Create a new JSF page, ajaxExternalRequestExample.jsp, by clicking File → New → Other → Web → Web Page.
  2. Create a new JSF page, externalPage.jsp, by clicking File → New → Other → Web → Web Page. In the page, type "External Page is Loaded!".

  3. Click here for a larger image.

    Figure 17: Creating a New AjaxExternalRequestExample.jsp Page

Page 5 of 6

Comment and Contribute


(Maximum characters: 1200). You have characters left.



Enterprise Development Update

Don't miss an article. Subscribe to our newsletter below.

Sitemap | Contact Us

Thanks for your registration, follow us on our social networks to keep up-to-date
Rocket Fuel