I'm a complete beginner when it comes to JSP, so I'm really not sure what I'm missing here. I'm trying to add some fields to a form in an existing webapp, but when I try to use html:text for my input fields, the complete form and the rest of the page after the form are not displaying. If I use <input> tags, my fields show up fine. The JSP code is below (fleetAccountsSearch.jspf file is what I'm trying to add). If there's more info required in order to help me figure out what I'm missing, please let me know and I'll try to add it. Thanks.
fleetAccounts.jsp:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/displaytag-12.tld" prefix="display" %>
<%@ page buffer = "16kb" %>
<jsp:useBean id="fleetAccountForm" scope="session" class="com.carolinapride.fleet.FleetAccountForm"/>
<script language="Javascript">
<!-- //Hide script from older browsers
function defaultFind(e) {
if (e.keyCode == 13 || e.which == 13) {
document.fleetAccountForm.target="_top";
submitForm("search");
}
}
function selectAccount(keyValue) {
document.fleetAccountForm.selectedAccount.value = keyValue;
submitForm("select");
}
// Finished hiding script from older browsers -->
</script>
<html:errors/>
<html:form action="fleet.do" method="POST">
<html:hidden property="formAction"/>
<center>
<TABLE align="center" width="100%" border="0" cellspacing="0" cellpadding="4">
<%@include file="fleetAccountsSearch.jspf"%>
<TR class="title">
<TD align="left" colspan="1">Fleet Accounts</TD>
<TD align="right" colspan="3">
<a href="javascript:submitForm('clear');" class="title_3d">Unselect</a>
<logic:equal name="user" property="role" value="ATT" scope="session">
<a href="javascript:submitForm('detail');" class="title_3d">Detail</a>
</logic:equal>
<logic:notEqual name="user" property="role" value="ATT" scope="session">
<a href="javascript:submitForm('detail');" class="title_3d">Edit</a>
<a href="javascript:submitForm('addAmount');" class="title_3d">Add Amount</a>
<a href="javascript:submitForm('creditAmount');" class="title_3d">Credit Amount</a>
<a href="javascript:submitForm('new');" class="title_3d">New</a>
<a href="javascript:submitFormConfirm('delete', 'Are you sure you want to delete the fleet account? This deletion cannot be reversed.');" class="title_3d">Delete </a>
</logic:notEqual>
</TD>
</TR>
<TR class="label">
<TD colspan="3">
<DIV id="fleet" style="Width: 100%; ">
<display:table name="sessionScope.fleetAccountForm.foundAccounts" requestURI="/fleet.do?formAction=nothing?displayTagAction=yes" sort="list" pagesize="15" align="center" width="100%" export="true" decorator="com.carolinapride.fleet.FleetAccountsTableDecorator">
<display:column property="company" title="Company" sortable="true" align="left" width="25%" headerClass="leftjustifiedsortable" />
<display:column property="name" title="Name" sortable="true" align="left" width="30%" headerClass="leftjustifiedsortable" />
<display:column property="type" title="Type" sortable="true" align="center" width="15%" headerClass="sortable" />
<display:column property="balance" title="Balance" align="right" width="15%"/>
<display:column property="selectedAccount" title="Select" align="center" media="html" width="15%"/>
<display:setProperty name="sort.behavior" value="list" />
<display:setProperty name="sort.amount" value="list" />
<display:setProperty name="paging.banner.placement" value="bottom" />
<display:setProperty name="paging.banner.full" value="<CENTER><span class=\"pagelinks\"> [<a href=\"{1}\">First</a>/ <a href=\"{2}\">Prev</a>] {0} [ <a href=\"{3}\">Next</a>/ <a href=\"{4}\">Last </a>]</span></CENTER>" />
<display:setProperty name="paging.banner.first" value="<CENTER><span class=\"pagelinks\"> [First/Prev] {0} [ <a href=\"{3}\">Next</a>/ <a href=\"{4}\">Last</a>] </span> </CENTER>" />
<display:setProperty name="paging.banner.last" value="<CENTER><span class=\"pagelinks\">[ <a href=\"{1}\">First</a>/ <a href=\"{2}\">Prev</a>] {0} [Next/Last] </span> </CENTER>" />
<display:setProperty name="paging.banner.onepage" value="<CENTER><span class=\"pagelinks\">{0}</span></CENTER>" />
<display:setProperty name="paging.banner.no_items_found" value="<CENTER><span class=\"pagebanner\"> No {0} found. </span></CENTER>" />
<display:setProperty name="paging.banner.one_item_found" value="<CENTER><span class=\"pagebanner\"> One {0} found. </span></CENTER>" />
<display:setProperty name="paging.banner.all_items_found" value="<CENTER><span class=\"pagebanner\"> {0} {1} found, displaying all {2}. </span> </CENTER>" />
<display:setProperty name="paging.banner.some_items_found" value="<CENTER><span class=\"pagebanner\"> {0} {1} found, displaying {2} to {3}. </span> </CENTER>" />
<display:setProperty name="paging.banner.item_name" value="account" />
<display:setProperty name="paging.banner.items_name" value="accounts" />
<display:setProperty name="paging.banner.group_size" value="10" />
<display:setProperty name="paging.banner.onepage" value="" />
<display:setProperty name="export.decorated" value="true" />
<display:setProperty name="export.excel.include_header" value="true" />
<display:setProperty name="export.csv.include_header" value="true" />
<display:setProperty name="export.xml.include_header" value="true" />
<display:setProperty name="export.excel.filename" value="fleetAccounts.xls" />
<display:setProperty name="export.csv.filename" value="fleetAccounts.csv" />
<display:setProperty name="export.xml.filename" value="fleetAccounts.xml" />
<display:setProperty name="basic.empty.showtable" value="false" />
<display:setProperty name="basic.msg.empty_list" value="No accounts found."/>
</display:table>
</DIV>
</TD>
</TR>
</TABLE>
</center>
</html:form>
fleetAccountsSearch.jspf:
<TR class="title">
<TD align="left">Fleet Accounts Search</TD>
<TD align="right" colspan="3"><a href="javascript:submitForm('clear');" class="title_3d">Clear</a><a href="javascript:submitForm('search');" class="title_3d">Search</a>
</TD>
</TR>
<TR class="label">
<TD align="right" class="label">First Name</TD>
<TD align="left" class="highlight">
<%--html:text size="30" maxlength="50" property="firstName"/--%>
<input type="text" size="30" maxlength="50" property="firstName"/>
</TD>
<TD align="right" class="label">Last Name</TD>
<TD alignn="left" class="highlight">
<%--html:text size="30" maxlength="50" property="lastName"/--%>
<input type="text" size="30" maxlength="50" property="lastName"/>
</TD>
</TR>
<TR>
<TD align="right" class="label">Company</TD>
<TD align="left" colspan="3" class="highlight">
<%--html:text size="30" maxlength="50" property="company"/--%>
<input type="text" size="30" maxlength="50" property="company"/>
</TD>
</TR>
<TR>
<TD align="right" class="label">City</TD>
<TD align="left" class="highlight">
<%--html:text size="30" maxlength="50" property="city"/--%>
<input type="text" size="30" maxlength="50" property="city"/>
</TD>
<TD align="right" class="label">State</TD>
<TD align="left" class="highlight">
<%--html:select property="state">
<html:option value="AL">Alabama</html:option>
<html:option value="AK">Alaska</html:option>
<html:option value="AZ">Arizona</html:option>
<html:option value="AR">Arkansas</html:option>
<html:option value="CA">California</html:option>
<html:option value="CO">Colorado</html:option>
<html:option value="CT">Connecticut</html:option>
<html:option value="DE">Delaware</html:option>
<html:option value="DC">District of Columbia</html:option>
<html:option value="FL">Florida</html:option>
<html:option value="GA">Georgia</html:option>
<html:option value="HI">Hawaii</html:option>
<html:option value="ID">Idaho</html:option>
<html:option value="IL">Illinois</html:option>
<html:option value="IN">Indiana</html:option>
<html:option value="IA">Iowa</html:option>
<html:option value="KS">Kansas</html:option>
<html:option value="KY">Kentucky</html:option>
<html:option value="LA">Louisiana</html:option>
<html:option value="ME">Maine</html:option>
<html:option value="MD">Maryland</html:option>
<html:option value="MA">Massachusetts</html:option>
<html:option value="MI">Michigan</html:option>
<html:option value="MN">Minnesota</html:option>
<html:option value="MS">Mississippi</html:option>
<html:option value="MO">Missouri</html:option>
<html:option value="MT">Montana</html:option>
<html:option value="NE">Nebraska</html:option>
<html:option value="NV">Nevada</html:option>
<html:option value="NH">New Hampshire</html:option>
<html:option value="NJ">New Jersey</html:option>
<html:option value="NM">New Mexico</html:option>
<html:option value="NY">New York</html:option>
<html:option value="NC">North Carolina</html:option>
<html:option value="ND">North Dakota</html:option>
<html:option value="OH">Ohio</html:option>
<html:option value="OK">Oklahoma</html:option>
<html:option value="OR">Oregon</html:option>
<html:option value="PA">Pennsylvania</html:option>
<html:option value="RI">Rhode Island</html:option>
<html:option value="SC">South Carolina</html:option>
<html:option value="SD">South Dakota</html:option>
<html:option value="TN">Tennessee</html:option>
<html:option value="TX">Texas</html:option>
<html:option value="UT">Utah</html:option>
<html:option value="VT">Vermont</html:option>
<html:option value="VA">Virginia</html:option>
<html:option value="WA">Washington</html:option>
<html:option value="WV">West Virginia</html:option>
<html:option value="WI">Wisconsin</html:option>
<html:option value="WY">Wyoming</html:option>
</html:select--%>
</TD>
</TR>