THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
JBoss Portal front page
MyPortlet portlet page
Next step
Anchor | ||||
---|---|---|---|---|
|
Next, let's do something a bit more interesting, namely create a simple form and display a result page. Let's start by creating our JSP that displays our form. Create a new file, 'helloForm.jsp' in the WEB-INF/pages/view/ folder. We will use the WebWork tag library to build the form on our page. The form itself will ask the user for a first name and last name, something like this:
Code Block | ||
---|---|---|
| ||
<%@ taglib uri="/webwork" prefix="ww" %>
<H2>Hi there! Please enter your name</H2>
<ww:form action="helloWorld" method="POST">
<ww:textfield label="First name" name="firstName" value="%{firstName}"/>
<ww:textfield label="Last name" name="lastName" value="%{lastName}"/>
<ww:submit value="Say hello!"/>
</ww:form>
|