Parameter Styles

Parameter styles are custom widgets which allow you to present portlet parameter using something other than the default input text box control. These widgets can be as simple as text area control or as complex as a pop up calendar control. In this tutorial, you will learn how to:

  • 1. Write a simple parameter style
  • 2. Modify the stock quote portlet from the VelocityPortlet tutorial to use parameter styles

Let's get started. From the JPortal distribution root directory, type:

maven -Dtutorial=12 jetspeed:deploy

Recommend bringing up these files in your editor:

  • 1. webapp/WEB-INF/conf/t12-portlets.xreg
  • 2. webapp/WEB-INF/conf/templates/vm/parameters/html/InputWithHelp.vm
  • 3. webapp/WEB-INF/conf/templates/vm/portlets/html/tutorial-stock-quote.vm
  • 4. webapp/src/java/org/apache/jetspeed/tutorial/modules/actions/portlets/TutorialStockQuoteAction.java

since we will refer to them in Tutorial 12.