webwork/src/resources/web/template/xhtml checkbox.jsp,NONE,1.1 combobox.jsp,NONE,1.1 controlfooter.jsp,NONE,1.1 controlheader.jsp,NONE,1.1 label.jsp,NONE,1.1 password.jsp,NONE,1.1 radiomap.jsp,NONE,1.1 select.jsp,NONE,1.1 selectcascading.jsp,NONE,1.1 selectgroupmap.jsp,NONE,1.1 selectmap.jsp,NONE,1.1 styles.css,NONE,1.1 tabbedpane.jsp,NONE,1.1 table.jsp,NONE,1.1 text.jsp,NONE,1.1 textarea.jsp,NONE,1.1
[email protected] Mon, 17 Jun 2002 05:58:36 -0700
| Newsgroups | gmane.comp.java.webwork.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/webwork/webwork/src/resources/web/template/xhtml
In directory usw-pr-cvs1:/tmp/cvs-serv10009
Added Files:
checkbox.jsp combobox.jsp controlfooter.jsp controlheader.jsp
label.jsp password.jsp radiomap.jsp select.jsp
selectcascading.jsp selectgroupmap.jsp selectmap.jsp
styles.css tabbedpane.jsp table.jsp text.jsp textarea.jsp
Log Message:
refactor standard to xhtml
--- NEW FILE: checkbox.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license
-- See terms of license at opensource.org
--
--
-- checkbox.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control
-- * name - The name of the attribute to put and pull the result from
-- Equates to the NAME parameter of the HTML INPUT tag
-- * fieldValue - The value displayed by the control. Equates to the value
-- of the HTML INPUT tag
--
-- Optional Parameters:
-- * disabled - DISABLED parameter of the HTML INPUT tag
-- * tabindex - tabindex parameter of the HTML INPUT tag
-- * onchange - onkeyup parameter of the HTML INPUT tag
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<webwork:property value="errors[parameters['name']]" id="errmsg">
<webwork:if test=".">
<tr>
<td align="left" valign="top" colspan="2">
<span class="errorMessage"><webwork:property value="."/></span>
</td>
</tr>
</webwork:if>
</webwork:property>
<tr>
<td valign="top" colspan="2">
<%-- Use an extra table so that the checkbox doesn't align with the other columns. --%>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr><td valign="top">
<input type="checkbox" <webwork:if test="parameters['nameValue'] == true">checked="checked"</webwork:if>
name="<webwork:property value="parameters['name']"/>"
value="<webwork:property value="parameters['fieldValue']"/>"
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
/>
</td><td width="100%" valign="top">
<webwork:if test="@errmsg">
<span class="checkboxErrorLabel">
</webwork:if>
<webwork:else>
<span class="checkboxLabel">
</webwork:else>
<webwork:property value="parameters['label']"/>
</span>
</td></tr>
</table>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: combobox.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- combobox.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML SELECT tag.
-- * list - Iterator that will provide the options for the control.
-- Equates to the HTML OPTION tags in the SELECT and supplies
-- both the NAME and VALUE parameters of the OPTION tag.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * size - SIZE parameter of the HTML INPUT tag.
-- * maxlength - MAXLENGTH parameter of the HTML INPUT tag.
-- * disabled - DISABLED parameter of the HTML INPUT tag.
-- * onkeyup - onkeyup parameter of the HTML INPUT tag.
-- * tabindex - tabindex parameter of the HTML INPUT tag.
-- * onchange - onkeyup parameter of the HTML INPUT tag.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<input type="text"
name="<webwork:property value="parameters['name']"/>"
<webwork:property value="parameters['size']">
<webwork:if test=".">size="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['maxlength']">
<webwork:if test=".">maxlength="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['nameValue']">
<webwork:if test=".">value="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onkeyup']">
<webwork:if test=".">onkeyup="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
/><br/>
<webwork:property value="parameters['list']">
<webwork:if test=".">
<select onChange="this.form.elements['<webwork:property value="parameters['name']"/>'].value=this.options[this.selectedIndex].value"
<webwork:property value="parameters['disabled']">
<webwork:if test="{parameters['disabled']}">disabled="disabled"</webwork:if>
</webwork:property>
>
<webwork:iterator value=".">
<option value="<webwork:property value="."/>" <webwork:if test="parameters['nameValue'] == .">selected="selected"</webwork:if>><webwork:property value="."/>
</option>
</webwork:iterator>
</select>
</webwork:if>
</webwork:property>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: controlfooter.jsp ---
</td>
</tr>
--- NEW FILE: controlheader.jsp ---
<%@ taglib uri="webwork" prefix="webwork" %>
<%-- Only show message if errors are available.
-- This will be done if ActionFormSupport is used.
--%>
<webwork:property value="errors[parameters['name']]">
<webwork:if test=".">
<tr>
<webwork:if test="parameters['labelposition'] == 'top'">
<td align="left" valign="top" colspan="2">
</webwork:if>
<webwork:else>
<td align="center" valign="top" colspan="2">
</webwork:else>
<span class="errorMessage"><webwork:property value="."/></span>
</td>
</tr>
</webwork:if>
</webwork:property>
<%-- if the label position is top,
-- then give the label it's own row in the table
--%>
<tr>
<webwork:if test="parameters['labelposition'] == 'top'">
<td align="left" valign="top" colspan="2">
</webwork:if>
<webwork:else>
<td align="right" valign="top">
</webwork:else>
<webwork:if test="errors[parameters['name']]">
<span class="errorLabel">
</webwork:if>
<webwork:else>
<span class="label">
</webwork:else>
<webwork:property value="parameters['label']"/>:
</span>
</td>
<%-- add the extra row --%>
<webwork:if test="parameters['labelposition'] == 'top'">
</tr><tr>
</webwork:if>
<td>
--- NEW FILE: label.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- label.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy this text label
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<label>
<webwork:property value="parameters['name']">
<webwork:if test="."><webwork:property value="."/></webwork:if>
</webwork:property>
</label>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: password.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- checkbox.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML INPUT tag.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * size - SIZE parameter of the HTML INPUT tag.
-- * maxlength - MAXLENGTH parameter of the HTML INPUT tag.
-- * disabled - DISABLED parameter of the HTML INPUT tag.
-- * readonly - READONLY parameter of the HTML INPUT tag.
-- * onkeyup - onkeyup parameter of the HTML INPUT tag.
-- * tabindex - tabindex parameter of the HTML INPUT tag.
-- * onchange - onkeyup parameter of the HTML INPUT tag.
-- * show - determines whether the password is shown or not. Default is false.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<input type="password"
name="<webwork:property value="parameters['name']"/>"
<webwork:property value="parameters['nameValue']">
<webwork:if test=". && parameters['show']==true">value="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['size']">
<webwork:if test=".">size="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['maxlength']">
<webwork:if test=".">maxlength="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['readonly']">
<webwork:if test="parameters['readonly'] == true">readonly="readonly"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onkeyup']">
<webwork:if test=".">onkeyup="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
/>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: radiomap.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- radiomap.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML tag INPUT.
-- * list - Iterator that will provide the options for the control.
-- Equates to the HTML LABEL tags.
-- * listKey - Where to get the values for the INPUT tag. Equates to
-- the VALUE parameter of the INPUT tag.
-- * listValue - The value displayed next to the radio control. Equates to the body
-- of the enclosing HTML LABEL tag.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * disabled - DISABLED parameter of the HTML INPUT tag.
-- * tabindex - tabindex parameter of the HTML INPUT tag.
-- * onchange - onkeyup parameter of the HTML INPUT tag.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<webwork:iterator value="parameters['list']">
<label><webwork:property value="{parameters['listValue']}"/>
<input type="radio" <webwork:if test="{parameters['listKey']} == parameters['nameValue']">checked="checked"</webwork:if>
name="<webwork:property value="parameters['name']"/>"
value="<webwork:property value="{parameters['listKey']}"/>"
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
/>
</label>
</webwork:iterator>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: select.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- select.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML SELECT tag.
-- * list - Iterator that will provide the options for the control.
-- Equates to the HTML OPTION tags in the SELECT and supplies
-- both the NAME and VALUE parameters of the OPTION tag.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * size - SIZE parameter of the HTML SELECT tag.
-- * disabled - DISABLED parameter of the HTML SELECT tag.
-- * tabindex - tabindex parameter of the HTML SELECT tag.
-- * onchange - onkeyup parameter of the HTML SELECT tag.
-- * size - SIZE parameter of the HTML SELECT tag.
-- * multiple - MULTIPLE parameter of the HTML SELECT tag.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<select name="<webwork:property value="parameters['name']"/>"
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['size']">
<webwork:if test=".">size="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['multiple']">
<webwork:if test="parameters['multiple'] == true">multiple="multiple"</webwork:if>
</webwork:property>
>
<webwork:iterator value="parameters['list']">
<option value="<webwork:property value="."/>"
<webwork:if test="{memberOf(parameters['nameValue'],.)} == true">selected="selected"</webwork:if>
>
<webwork:property value="."/>
</option>
</webwork:iterator>
</select>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: selectcascading.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
-- selectcascading.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML tag SELECT.
-- * list - Iterator that will provide the options for the control.
-- Equates to the HTML OPTION tags in the SELECT.
-- * listKey - Where to get the values for the OPTION tag. Equates to
-- the VALUE parameter of the OPTION tag.
-- * listValue - The value displayed by the control. Equates to the body
-- of the HTML OPTION tag.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * receiver - The name of the receiving SELECT tag.
-- * onChange - The value of the Javascript that would be triggered if this SELECT is changed.
-- * receiverMap - Iterator that will provide the options for the control.
-- Equates to the HTML OPTION tags in the SELECT.
-- * disabled - DISABLED parameter of the HTML SELECT tag.
-- * tabindex - tabindex parameter of the HTML SELECT tag.
-- * onchange - IGNORED, it has its own onchange defined
-- * size - SIZE parameter of the HTML SELECT tag.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<script>
addCallerReceiverPair( "<webwork:property value="parameters['name']"/>", "<webwork:property value="parameters['receiver']"/>" );
tmpDataMap = new Map();
<webwork:if test="parameters['receiverMap']">
<webwork:iterator value="parameters['receiverMap']">
tmpMap = new Map();
<webwork:iterator value="value">
tmpMap.put( "<webwork:property value="key"/>", "<webwork:property value="value"/>" );
</webwork:iterator>
tmpDataMap.put( "<webwork:property value="{parameters['listKey']}"/>", tmpMap );
</webwork:iterator>
</webwork:if>
setDataMapForPair( "<webwork:property value="parameters['name']"/>", "<webwork:property value="parameters['receiver']"/>", tmpDataMap );
</script>
<select name="<webwork:property value="parameters['name']"/>" onChange="callerHasChanged( this.name, '<webwork:property value="parameters['receiver']"/>' );"
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">DISABLED</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['size']">
<webwork:if test=".">size="<webwork:property value="."/>"</webwork:if>
</webwork:property>
>
<webwork:if test="parameters['initialValue']">
<option value="<webwork:property value="parameters['initialValue']"/>" selected="selected">
<webwork:property value="parameters['initialValue']"/>
</option>
</webwork:if>
<webwork:iterator value="parameters['list']">
<option value="<webwork:property value="{parameters['listKey']}"/>"
<webwork:if test="{parameters['listKey']} == parameters['nameValue']">selected="selected"</webwork:if>>
<webwork:property value="{parameters['listValue']}"/>
</option>
</webwork:iterator>
</select>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: selectgroupmap.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- selectgroupmap.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML tag SELECT.
-- * list - Iterator that will provide the options for the control.
-- Equates to the HTML OPTION tags in the SELECT.
-- * groupKey - Where to get the values for the OPTGROUP tag. Equates to
-- the LABEL parameter of the OPTION tag.
-- * groupList - Iterator that will provide the options for the group.
-- Must refer to an attribute of the "list" parameter elements
-- * listKey - Where to get the values for the OPTION tag. Equates to
-- the VALUE parameter of the OPTION tag.
-- * listValue - The value displayed by the control. Equates to the body
-- of the HTML OPTION tag.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * disabled - DISABLED parameter of the HTML SELECT tag.
-- * tabindex - tabindex parameter of the HTML SELECT tag.
-- * onchange - onkeyup parameter of the HTML SELECT tag.
-- * size - SIZE parameter of the HTML SELECT tag.
-- * multiple - MULTIPLE parameter of the HTML SELECT tag.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<select name="<webwork:property value="parameters['name']"/>"
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['size']">
<webwork:if test=".">size="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['multiple']">
<webwork:if test="parameters['multiple'] == true">multiple="multiple"</webwork:if>
</webwork:property>
>
<webwork:iterator value="parameters['list']">
<optgroup label="<webwork:property value="{parameters['groupKey']}"/>">
<webwork:iterator value="{parameters['groupList']}">
<option value="<webwork:property value="{parameters['listKey']}"/>"
<webwork:if test="{memberOf(parameters['nameValue'], {parameters['listKey']})} == true">selected="selected"</webwork:if>
>
<webwork:property value="{parameters['listValue']}"/>
</option>
</webwork:iterator>
</optgroup>
</webwork:iterator>
</select>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: selectmap.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- selectmap.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML tag SELECT.
-- * list - Iterator that will provide the options for the control.
-- Equates to the HTML OPTION tags in the SELECT.
-- * listKey - Where to get the values for the OPTION tag. Equates to
-- the VALUE parameter of the OPTION tag.
-- * listValue - The value displayed by the control. Equates to the body
-- of the HTML OPTION tag.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * disabled - DISABLED parameter of the HTML SELECT tag.
-- * tabindex - tabindex parameter of the HTML SELECT tag.
-- * onchange - onkeyup parameter of the HTML SELECT tag.
-- * size - SIZE parameter of the HTML SELECT tag.
-- * multiple - MULTIPLE parameter of the HTML SELECT tag.
--
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<select name="<webwork:property value="parameters['name']"/>"
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['size']">
<webwork:if test=".">size="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['multiple']">
<webwork:if test="parameters['multiple'] == true">multiple="multiple"</webwork:if>
</webwork:property>
>
<webwork:iterator value="parameters['list']">
<option value="<webwork:property value="{parameters['listKey']}"/>"
<webwork:if test="{memberOf(parameters['nameValue'], {parameters['listKey']})} == true">selected="selected"</webwork:if>
>
<webwork:property value="{parameters['listValue']}"/>
</option>
</webwork:iterator>
</select>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: styles.css ---
.label {font-style:italic; }
.errorLabel {font-style:italic; color:red; }
.errorMessage {font-weight:bold; text-align: center; color:red; }
.checkboxLabel {}
.checkboxErrorLabel {color:red; }
--- NEW FILE: tabbedpane.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- tabbedpane.jsp
--
-- Required Parameters:
-- * contentName - The name of the data map to be used.
--
-- Optional Parameters:
-- * tabAlign - The Alignment of the tabs. Default is the CENTER of the control.
-- * id - Id of the control.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<webwork:bean name="'webwork.util.Counter'" id="tabIndex">
<webwork:param name="'first'" value="0"/>
<webwork:param name="'last'" value="content/size"/>
</webwork:bean>
<table border="1" cellspacing="0" cellpadding="5" id="<webwork:property value="id"/>">
<tr valign="bottom" align="<webwork:property value="tabAlign"/>">
<webwork:if test="tabAlign == 'CENTER' || tabAlign == 'RIGHT'"><th colspan ="1" width="*"></th></webwork:if>
<webwork:iterator value="content">
<th width="10%"
<webwork:if id="isCur" test="selectedIndex == @tabIndex/current">bgcolor="#A0B3FC"</webwork:if>
<webwork:else>bgcolor="#C0C0C0"</webwork:else>>
<a href="<webwork:url><webwork:param name="indexLink" value="@tabIndex/next"/></webwork:url>">
<webwork:if test="@isCur == true"><em></webwork:if>
<webwork:property value="key"/>
<webwork:if test="@isCur == true"></em></webwork:if>
</a>
</th>
</webwork:iterator>
<webwork:if test="tabAlign == 'CENTER' || tabAlign == 'LEFT'"><th colspan ="1" width="*"></th></webwork:if>
</tr>
<tr>
<td bgcolor="#E1EAE8" colspan="<webwork:property value="colSpanLength"/>" width="100%">
<webwork:include value="selectedUrl"/>
</td>
</tr>
</table>
--- NEW FILE: table.jsp ---
<%@ taglib uri="webwork" prefix="webwork" %>
<%/*This is just a sample table layout that I sometimes use.
* it shows fine on Internet Explorer but does not always look
* so good on Netscape ( a blank cell will show up as balck)
* you can modify this to shopw the table any way you want
*
* NOTE : this should currently be included within the context of the
* webTable bean.
*
*/%>
<webwork:if test=". != null">
<webwork:if test="model != null">
<p align="center">
<table bgcolor="white" border="0" cellpadding="1" cellspacing="0" >
<tr>
<td>
<table border="0" cellpadding="2" cellspacing="1">
<tr bgcolor="yellow">
<%/* Show the visible column names. Use the display name that can
* be set in the jsp.
*/%>
<webwork:property value="columns">
<webwork:iterator id="curColumn">
<webwork:if test="visible == true">
<th>
<webwork:if test="sortable == true">
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<webwork:property value="displayName" escape="false"/>
</td>
<td>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td align="bottom">
<webwork:if test="(sortColumn == offset) && (sortOrder == 'ASC')">
<img src="images/sorted_asc.gif" border="0" align="bottom"/>
</webwork:if>
<webwork:else>
<a href="<webwork:url><webwork:param name="sortColumnLinkName" value="offset"/><webwork:param name="sortOrderLinkName" value="'ASC'"/></webwork:url>"><img src="images/unsorted_asc.gif" border="0" align="bottom"/></a>
</webwork:else>
</td>
</tr>
<tr>
<td align="top">
<webwork:if test="(sortColumn == offset) && (sortOrder == 'DESC')">
<img src="images/sorted_desc.gif" border="0" align="top"/>
</webwork:if>
<webwork:else>
<a href="<webwork:url><webwork:param name="sortColumnLinkName" value="offset"/><webwork:param name="sortOrderLinkName" value="'DESC'"/></webwork:url>"><img src="images/unsorted_desc.gif" border="0" align="top"/></a>
</webwork:else>
</td>
</tr>
</table>
</td>
</tr>
</table>
</webwork:if>
<webwork:else>
<webwork:property value="displayName" escape="false"/>
</webwork:else>
</th>
</webwork:if>
</webwork:iterator>
</webwork:property>
</tr>
<%/*counter used to alternate background row colors*/%>
<webwork:bean name="'webwork.util.Counter'" id="rowCount">
<webwork:param name="'wrap'" value="true"/>
<webwork:param name="'last'" value="2"/>
</webwork:bean>
<%/*Row iterator will iterate through the formated rows*/%>
<webwork:property value="rowIterator">
<webwork:iterator>
<%/*set the background colors. Used in 0.95 version
* I haven't looked to see if there is a cleaner way
* but there must be
*/%>
<tr
<webwork:if test="@rowCount/next == 1">
bgcolor="#EEEEFF"
</webwork:if>
<webwork:if test = "@rowCount/next == 0"/>
<webwork:if test = "@rowCount/next == 2">
bgcolor="#FFFFFF"
</webwork:if>
>
<%/*show the actual cell contents. It is generated by the renderer for the columns*/%>
<webwork:iterator>
<td><webwork:property value="." escape="false"/></td>
</webwork:iterator>
</tr>
</webwork:iterator>
</webwork:property>
</table>
</td>
</tr>
</table>
</p>
</webwork:if>
<webwork:else>
<center>
<table border="1">
<tr><th><font color="red">ERROR</font></th></tr>
<tr><td>no model was available</td></tr>
</table>
</center>
</webwork:else>
</webwork:if>
<webwork:else>
this page can not be loaded directly
</webwork:else>
--- NEW FILE: text.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- text.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML INPUT tag.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * size - SIZE parameter of the HTML INPUT tag.
-- * maxlength - MAXLENGTH parameter of the HTML INPUT tag.
-- * disabled - DISABLED parameter of the HTML INPUT tag.
-- * readonly - READONLY parameter of the HTML INPUT tag.
-- * onkeyup - onkeyup parameter of the HTML INPUT tag.
-- * tabindex - tabindex parameter of the HTML INPUT tag.
-- * onchange - onkeyup parameter of the HTML INPUT tag.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<input type="text"
name="<webwork:property value="parameters['name']"/>"
<webwork:property value="parameters['size']">
<webwork:if test=".">size="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['maxlength']">
<webwork:if test=".">maxlength="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['nameValue']">
<webwork:if test=".">value="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['readonly']">
<webwork:if test="parameters['readonly'] == true">readonly="readonly"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onkeyup']">
<webwork:if test=".">onkeyup="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
/>
<%@ include file="controlfooter.jsp" %>
--- NEW FILE: textarea.jsp ---
<%--
-- WebWork, Web Application Framework
--
-- Distributable under LGPL license.
-- See terms of license at opensource.org
--
--
-- textarea.jsp
--
-- Required Parameters:
-- * label - The description that will be used to identfy the control.
-- * name - The name of the attribute to put and pull the result from.
-- Equates to the NAME parameter of the HTML INPUT tag.
-- * cols - Width of the textarea. Equates to the COLS parameter of
-- HTML tag TEXTAREA.
-- * rows - Height of the textarea. Equates to the ROWS parameter of
-- HTML tag TEXTAREA.
--
-- Optional Parameters:
-- * labelposition - determines were the label will be place in relation
-- to the control. Default is to the left of the control.
-- * disabled - DISABLED parameter of the HTML TEXTAREA tag.
-- * readonly - READONLY parameter of the HTML TEXTAREA tag.
-- * onkeyup - onkeyup parameter of the HTML TEXTAREA tag.
-- * tabindex - tabindex parameter of the HTML TEXTAREA tag.
-- * onchange - onkeyup parameter of the HTML TEXTAREA tag.
--
--%>
<%@ taglib uri="webwork" prefix="webwork" %>
<%@ include file="controlheader.jsp" %>
<textarea name="<webwork:property value="parameters['name']"/>"
cols="<webwork:property value="parameters['cols']"/>"
rows="<webwork:property value="parameters['rows']"/>"
<webwork:property value="parameters['disabled']">
<webwork:if test="parameters['disabled'] == true">disabled="disabled"</webwork:if>
</webwork:property>
<webwork:property value="parameters['readonly']">
<webwork:if test="parameters['readonly'] == true">readonly="readonly"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onkeyup']">
<webwork:if test=".">onkeyup="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['tabindex']">
<webwork:if test=".">tabindex="<webwork:property value="."/>"</webwork:if>
</webwork:property>
<webwork:property value="parameters['onchange']">
<webwork:if test=".">onchange="<webwork:property value="."/>"</webwork:if>
</webwork:property>
><webwork:property value="parameters['nameValue']"/></textarea>
<%@ include file="controlfooter.jsp" %>
_______________________________________________________________
Sponsored by:
ThinkGeek at http://www.ThinkGeek.com/