You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by John Eaton <jo...@lagan.com> on 2004/03/01 17:18:44 UTC

FW: Apache Tomcat 4.0 vs 4.1

Has no-one any ideas about my issue below?

-----Original Message-----
From: John Eaton 
Sent: 24 February 2004 09:17
To: tomcat-user@jakarta.apache.org
Subject: RE: Apache Tomcat 4.0 vs 4.1


The jsp page in the work directory is as follows

package org.apache.jsp;

import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
import org.apache.jasper.runtime.*;
import com.lagan.lagancentre.core.thinclient.common.util.*;
import com.lagan.lagancentre.core.util.forms.*;
import java.lang.*;
import java.util.*;
import java.text.*;

public class CreateIndividual_jsp extends HttpJspBase {


  private static java.util.Vector _jspx_includes;

  public java.util.List getIncludes() {
    return _jspx_includes;
  }

  public void _jspService(HttpServletRequest request, HttpServletResponse response)
        throws java.io.IOException, ServletException {

    JspFactory _jspxFactory = null;
    javax.servlet.jsp.PageContext pageContext = null;
    HttpSession session = null;
    ServletContext application = null;
    ServletConfig config = null;
    JspWriter out = null;
    Object page = this;
    JspWriter _jspx_out = null;


    try {
      _jspxFactory = JspFactory.getDefaultFactory();
      response.setContentType("text/html;charset=UTF-8");
      pageContext = _jspxFactory.getPageContext(this, request, response,
      			null, true, 8192, true);
      application = pageContext.getServletContext();
      config = pageContext.getServletConfig();
      session = pageContext.getSession();
      out = pageContext.getOut();
      _jspx_out = out;

      out.write("\r\n\r\n");
      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n\r\n");
      out.write("<html>\r\n");
      out.write("<head>\r\n");
      out.write("<title>Create Individual");
      out.write("</title>\r\n");
      out.write("<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\">\r\n");
      out.write("</head>\r\n");
      out.write("<script language=\"javascript\" src=\"calendar.js\">");
      out.write("</script>\r\n");
      out.write("<body>\r\n\r\n");
      JspRuntimeLibrary.include(request, response, "Options.jsp" + "?" + "pageTitle=" + "Create+Individual", out, true);
      out.write("\r\n\r\n");
      out.write("\r\n\r\n");

	int[] parms = new int[32];
	for (int i=0; i<32; i++) parms[i] = WSMethod.STRING;
	parms[10] = WSMethod.CALENDAR;

	String service = (String) application.getAttribute(AttributeName.WEB_SERVICE);
	
	WSMethod meth = new WSMethod(service, "createIndividual", parms);

	String title = null;
	String forename1 = null;
	String forename2 = null;
	String forename3 = null;
	String surname = null;
	String addressnumber = null;
	String address1 = null;
	String address2 = null;
	String address3 = null;
	String postcode = null;
	String dob = null;
	String phonenumber1 = null;
	String phoneusage1 = null;
	String phonetype1 = null;
	String phonenumber2 = null;
	String phoneusage2 = null;
	String phonetype2 = null;
	String emailaddress = null;
	String emailusage = null;
	String verificationlevel = null;
	String gender = null;
	String maritalstatus = null;
	String ethnicity = null;
	String nationality = null;
	String healthnumber = null;
	String ninumber = null;
	Calendar birth = null;
	boolean mandatory = false;
	boolean invalidDate = false;
	String dobString = null;

	if (request.getParameter("create") != null)
	{
		title = request.getParameter("title");
		forename1 = request.getParameter("forename1");
		forename2 = request.getParameter("forename2");
		forename3 = request.getParameter("forename3");
		surname = request.getParameter("surname");
		addressnumber = request.getParameter("addressnumber");
		address1 = request.getParameter("address1");
		address2 = request.getParameter("address2");
		address3 = request.getParameter("address3");
		postcode = request.getParameter("postcode");
		dob = request.getParameter("dob");
		phonenumber1 = request.getParameter("phonenumber1");
		phoneusage1 = request.getParameter("phoneusage1");
		phonetype1 = request.getParameter("phonetype1");
		phonenumber2 = request.getParameter("phonenumber2");
		phoneusage2 = request.getParameter("phoneusage2");
		phonetype2 = request.getParameter("phonetype2");
		emailaddress = request.getParameter("emailaddress");
		emailusage = request.getParameter("emailusage");
		verificationlevel = request.getParameter("verificationlevel");
		gender = request.getParameter("gender");
		maritalstatus = request.getParameter("maritalstatus");
		ethnicity = request.getParameter("ethnicity");
		nationality = request.getParameter("nationality");
		healthnumber = request.getParameter("healthnumber");
		ninumber = request.getParameter("ninumber");
		birth = Calendar.getInstance();
		mandatory = false;
		invalidDate = false;
		dobString = null;
	}
	
	if (title == null)
	{
		title = "";
	}
	if (forename1 == null)
	{
		forename1 = "";
	}
	if (surname == null)
	{
		surname = "";
	}
	if (forename2 == null)
	{
		forename2 = "";
	}
	if (forename3 == null)
	{
		forename3 = "";
	}
	if (addressnumber == null)
	{
		addressnumber = "";
	}
	if (address1 == null)
	{
		address1 = "";
	}
	if (address2 == null)
	{
		address2 = "";
	}
	if (address3 == null)
	{
		address3 = "";
	}
	if (postcode == null)
	{
		postcode = "";
	}
	if (dob == null)
	{
		dob = "";
	}
	if (phonenumber1 == null)
	{
		phonenumber1 = "";
	}
	if (phonenumber2 == null)
	{
		phonenumber2 = "";
	}
	if (emailaddress == null)
	{
		emailaddress = "";
	}
	if (verificationlevel == null)
	{
		verificationlevel = "";
	}
	if (nationality == null)
	{
		nationality = "";
	}
	if (healthnumber == null)
	{
		healthnumber = "";
	}
	if (ninumber == null)
	{
		ninumber = "";
	}

	if ((request.getParameter("create") != null))
	{
		if (surname.compareTo("") == 0)
		{	mandatory = true;
		}

		if (dob.compareTo("") == 0)
		{
			birth = null;
		}
		if (birth != null)
		{
			try
			{	
				if((Integer.parseInt(dob.substring(0,2)) <= 31) && (Integer.parseInt(dob.substring(3,5)) <= 12) && 
					(Integer.parseInt(dob.substring(0,2)) > 0) && (Integer.parseInt(dob.substring(3,5)) > 0))
				{
					birth = Calendar.getInstance();
					birth.setTime(DateFormat.
							getDateInstance(DateFormat.SHORT, Locale.UK).parse(dob));
					//Change to "2003-11-19T00:00:00.000" format
					int monthInt = birth.get(Calendar.MONTH);
					int dayInt = birth.get(Calendar.DAY_OF_MONTH);
					String month, day;

					if(birth.get(Calendar.MONTH)<9) 
						month = "0"+ (monthInt + 1);
					else
						month = ""+ (monthInt + 1);
						
					if(birth.get(Calendar.DAY_OF_MONTH)<10) 
						day = "0"+ dayInt;
					else
						day = ""+dayInt;
					
					dobString = birth.get(Calendar.YEAR)+"-"+month+"-"+day+"T00:00:00.000"; 
				}
				else
				{	dobString = null;
					invalidDate = true;
				}
			}
			catch (Exception pe)
			{
				dobString = null;
				invalidDate = true;
			}
		}
		
	
		if(!invalidDate && !mandatory)
		{	String emailadd = emailaddress;
			if(emailadd.equals(""))
				emailadd = null;
			String phoneno1 = phonenumber1;
			if(phoneno1.equals(""))
				phoneno1 = null;
			String phoneno2 = phonenumber2;
			if(phoneno2.equals(""))
				phoneno2 = null;
				
			String[] vals ={title, forename1, forename2, 
				forename3, surname, addressnumber, address1, address2, address3,
				postcode, dobString, phoneno1, phoneusage1, phonetype1, phoneno2,
				phoneusage2, phonetype2, emailadd, emailusage, verificationlevel, gender,
				maritalstatus, ethnicity, nationality, healthnumber, ninumber, null,
				null, null, null, null, null};
		
			String[][] res = null;
			try
			{
				res = meth.execute(vals);
				meth.displayArray(res); 

				if (res[0][0].equals("-2") || res[0][0].equals("-1"))
				{

      out.write("\r\n\t\t\t\t\t");
      out.write("<p class=\"error\">");
      out.write("<b>&nbsp;Exact client already exits");
      out.write("</b>");
      out.write("</p>\r\n");

				}
				else
				{

      out.write("\r\n\t\t\t\t\t");
      out.write("<p class=\"standard\">");
      out.write("<b>&nbsp;Created:");
      out.write("</b> ");
      out.print( forename1 );
      out.write(" ");
      out.print( surname );
      out.write("</p>\r\n\t\t\t\r\n");

					title = "";
					forename1 = "";
					forename2 = "";
					forename3 = "";
					surname = "";
					addressnumber = "";
					address1 = "";
					address2 = "";
					address3 = "";
					postcode = "";
					dob = "";
					phonenumber1 = "";
					phoneusage1 = "";
					phonetype1 = "";
					phonenumber2 = "";
					phoneusage2 = "";
					phonetype2 = "";
					emailaddress = "";
					emailusage = "";
					verificationlevel = "";
					gender = "";
					maritalstatus = "";
					ethnicity = "";
					nationality = "";
					healthnumber = "";
					ninumber = "";
				}
			}
			catch(Exception e)
			{
				e.printStackTrace();
				System.out.println("@@@@@@@@@@@@@@");

      out.write("\r\n\t\t\t");
      out.write("<p class=\"error\">");
      out.write("<b>&nbsp;Exception in Create method:");
      out.write("</b> ");
      out.print( e );
      out.write("</P>\r\n");

			}
		}
		else
		{	
			if(mandatory)
			{

      out.write("\r\n\t\t\t");
      out.write("<p class=\"error\">");
      out.write("<b>&nbsp;Surname is mandatory");
      out.write("</b>");
      out.write("</p>\r\n");

			}
			if(invalidDate)
			{

      out.write("\r\n\t\t\t");
      out.write("<p class=\"error\">");
      out.write("<b>&nbsp;Illegal date:");
      out.write("</b> ");
      out.print( dob );
      out.write("</p>\r\n");

			}
		}
	}
	else
	{

      out.write("\r\n\t\t");
      out.write("<p class=\"standard\">");
      out.write("<b>&nbsp;No Individual currently created");
      out.write("</b>");
      out.write("</P>\r\n");

	}


      out.write("\r\n\r\n");
      out.write("<form action=\"CreateIndividual.jsp\">");
      out.write("<center>\r\n");
	ComboFormItem[] comboFormItems = (ComboFormItem[])application.getAttribute(AttributeName.COMBO_ITEMS);
	
	// If frontline combo items aren't available, use defaults
	if (comboFormItems == null)
	{
		comboFormItems = new ComboFormItem[6];
		
		String[] values1 = {"","HOME","WORK","UNKNOWN"};
		comboFormItems[0]= new ComboFormItem(1,"Phone Usage", values1);
		String[] values2 = {"","TELEPHONE","MOBILE","FAX"};
		comboFormItems[1]= new ComboFormItem(2,"Phone Type", values2);
		String[] values3 = {"","HOME","WORK","UNKNOWN"};
		comboFormItems[2]= new ComboFormItem(3,"Email Usage", values3);
		ComboFormItem.ComboItem[] values4 = {new ComboFormItem.ComboItem("U","U","Undisclosed"),
			new ComboFormItem.ComboItem("M","M","Male"), new ComboFormItem.ComboItem("F","F","Female")};
		comboFormItems[3]= new ComboFormItem(4,"Gender", values4);
		ComboFormItem.ComboItem[] values5 = {new ComboFormItem.ComboItem("N","N","Undisclosed"),
			new ComboFormItem.ComboItem("S","S","Single"), new ComboFormItem.ComboItem("M","M","Married"),
			new ComboFormItem.ComboItem("W","W","Widowed"), new ComboFormItem.ComboItem("D","D","Divorced"),
			new ComboFormItem.ComboItem("S","S","Seperated")};
		comboFormItems[4]= new ComboFormItem(5,"Marital Status", values5);
		String[] values6 = {"Undisclosed","White - British","White - Irish","White - Other",
		"Mixed - White & Black Caribbean","Mixed - White & Black African","Mixed - White & Asian",
		"Mixed - Other","Asian or Asian British - Indian","Asian or Asian British - Pakistani",
		"Asian or Asian British - Bangladeshi","Asian or Asian British - Other","Black or Black British - Carribean",
		"Black or Black British - African","Black or Black British - Other","Other - Chineese","Other - Not Stated"};
		comboFormItems[5]= new ComboFormItem(6,"Ethnicity", values6);
		
		application.setAttribute(AttributeName.COMBO_ITEMS, comboFormItems);
	}

      out.write("\r\n");
      out.write("<table cellpadding=2>\r\n");
      out.write("<tr>\r\n");
      out.write("<td class=\"complete\">\r\n\t");
      out.write("<table border=\"0\" cellspacing=\"0\" cellpadding=\"4\" class=\"standard\">\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Title:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"title\" size=90 maxlength=35 value=\"");
      out.print( title );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<td>Forename:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"forename1\" size=90 maxlength=35 value=\"");
      out.print( forename1 );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<td>Surname:*");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"surname\" size=90 maxlength=70 value=\"");
      out.print( surname );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Forename2:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"forename2\" size=90 maxlength=35 value=\"");
      out.print( forename2 );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Forename3:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"forename3\" size=90 maxlength=35 value=\"");
      out.print( forename3 );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t\r\n\t\t");
      out.write("<tr>");
      out.write("<td colspan=100%>&nbsp;");
      out.write("</td>");
      out.write("</tr>\r\n\t\t\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Address Number:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"addressnumber\" size=90 maxlength=50 value=\"");
      out.print( addressnumber );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Address Line 1:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"address1\" size=90 maxlength=100 value=\"");
      out.print( address1 );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Address Line 2:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"address2\" size=90 maxlength=100 value=\"");
      out.print( address2 );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Address Line 3:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"address3\" size=90 maxlength=100 value=\"");
      out.print( address3 );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Postcode:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"postcode\" size=90 maxlength=8 value=\"");
      out.print( postcode );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t\r\n\t\t");
      out.write("<tr>");
      out.write("<td colspan=100%>&nbsp;");
      out.write("</td>");
      out.write("</tr>\r\n\r\n\t\t");
      out.write("<tr>");
      out.write("<td>DOB:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" size=15 name=\"dob\" value=\"");
      out.print( dob );
      out.write("\">\r\n\t\t");
      out.write("<a href=\"javascript:cal()\" \r\n            onclick=\"setDateField(dob);\r\n            top.newWin=window.open('calendar.html', 'cal', 'width=270, height=270')\">\r\n\t\t\t");
      out.write("<img src=\"images/calendar.gif\" width=16 height=16 align=bottom border=0/>");
      out.write("</a>\r\n\t\t\tdd/mm/yyyy");
      out.write("</tr>\r\n\t\t");
      out.write("</td>\r\n\t\t");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Verification Level:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"verificationlevel\" size=90 maxlength=25 value=\"");
      out.print( verificationlevel );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Gender:");
      out.write("</td>");
      out.write("<td>");
      out.write("<select name=\"gender\" class=\"standard\" style=\"width:100%;\">\r\n\t\t\t\t\t\t\t\t\t\t");

										ComboFormItem.ComboItem[] comboItems = comboFormItems[3].getComboItems();
									for (int i = 0; i < comboItems.length; i++)
								        {
											if (comboItems[i].getValue().equals(gender)) {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\" selected>");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											} else {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\">");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											}
										} 
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t");
      out.write("</select>");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Marital Status:");
      out.write("</td>");
      out.write("<td>");
      out.write("<select name=\"maritalstatus\" class=\"standard\" style=\"width:100%;\">\r\n\t\t\t\t\t\t\t\t\t\t");

										comboItems = comboFormItems[4].getComboItems();
									for (int i = 0; i < comboItems.length; i++)
								        {
											if (comboItems[i].getValue().equals(maritalstatus)) {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\" selected>");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											} else {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\">");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											}
										} 
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t");
      out.write("</select>");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Ethnicity:");
      out.write("</td>");
      out.write("<td>");
      out.write("<select name=\"ethnicity\" class=\"standard\" maxlength=25 style=\"width:100%;\">\r\n\t\t\t\t\t\t\t\t\t\t");

										comboItems = comboFormItems[5].getComboItems();
									for (int i = 0; i < comboItems.length; i++)
								        {
											if (comboItems[i].getValue().equals(ethnicity)) {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\" selected>");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											} else {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\">");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											}
										} 
										
      out.write("\r\n\t\t\t\t\t\t\t\t");
      out.write("</select>");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Nationality:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"nationality\" size=90 maxlength=35 value=\"");
      out.print( nationality );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Health Number:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"healthnumber\" size=90 maxlength=50 value=\"");
      out.print( healthnumber );
      out.write("\">");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>NI Number:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" size=90 name=\"ninumber\" maxlength=50 value=\"");
      out.print( ninumber );
      out.write("\">\r\n\t\t");
      out.write("</td>");
      out.write("</tr>\r\n\t\t\r\n\t\t");
      out.write("<tr>");
      out.write("<td colspan=100%>&nbsp;");
      out.write("</td>");
      out.write("</tr>\r\n\t\t\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Phone Number 1:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"phonenumber1\" size=17 maxlength=15 value=\"");
      out.print( phonenumber1 );
      out.write("\">\r\n\t\t&nbsp;Phone Usage 1: ");
      out.write("<select name=\"phoneusage1\" class=\"standard\">\r\n\t\t\t\t\t\t\t\t\t\t");

										comboItems = comboFormItems[0].getComboItems();
										for (int i = 0; i < comboItems.length; i++)
								        {
											if (comboItems[i].getValue().equals(phoneusage1)) {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\" selected>");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											} else {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\">");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											}
										} 
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t");
      out.write("</select>\r\n\t\t&nbsp;Phone Type 1: ");
      out.write("<select name=\"phonetype1\" class=\"standard\">\r\n\t\t\t\t\t\t\t\t\t\t");

										comboItems = comboFormItems[1].getComboItems();
										for (int i = 0; i < comboItems.length; i++)
								        {
											if (comboItems[i].getValue().equals(phonetype1)) {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\" selected>");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											} else {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\">");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											}
										} 
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t");
      out.write("</select>");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Phone Number 2:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" name=\"phonenumber2\" size=17 maxlength=15 value=\"");
      out.print( phonenumber2 );
      out.write("\">\r\n\t\t&nbsp;Phone Usage 2: ");
      out.write("<select name=\"phoneusage2\" class=\"standard\">\r\n\t\t\t\t\t\t\t\t\t\t");

										comboItems = comboFormItems[0].getComboItems();
										for (int i = 0; i < comboItems.length; i++)
								        {
											if (comboItems[i].getValue().equals(phoneusage2)) {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\" selected>");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											} else {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\">");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											}
										} 
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t");
      out.write("</select>\r\n\t\t&nbsp;Phone Type 2: ");
      out.write("<select name=\"phonetype2\" class=\"standard\">\r\n\t\t\t\t\t\t\t\t\t\t");

										comboItems = comboFormItems[1].getComboItems();
										for (int i = 0; i < comboItems.length; i++)
								        {
											if (comboItems[i].getValue().equals(phonetype2)) {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\" selected>");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											} else {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\">");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											}
										} 
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t");
      out.write("</select>");
      out.write("</td>");
      out.write("</tr>\r\n\t\t");
      out.write("<tr>");
      out.write("<td>Email Address:");
      out.write("</td>");
      out.write("<td>");
      out.write("<input type=\"text\" class=\"standard\" size=35 name=\"emailaddress\" value=\"");
      out.print( emailaddress );
      out.write("\"> \r\n\t\t&nbsp;Email Usage: ");
      out.write("<select name=\"emailusage\" class=\"standard\" style=\"width:40.7%;\">\r\n\t\t\t\t\t\t\t\t\t\t");

										comboItems = comboFormItems[2].getComboItems();
									for (int i = 0; i < comboItems.length; i++)
								        {
											if (comboItems[i].getValue().equals(emailusage)) {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\" selected>");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											} else {
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t\t\t");
      out.write("<option value=\"");
      out.print( comboItems[i].getValue() );
      out.write("\">");
      out.print( comboItems[i].getName() );
      out.write("</option>\r\n\t\t\t\t\t\t\t\t\t\t");

											}
										} 
										
      out.write("\r\n\t\t\t\t\t\t\t\t\t");
      out.write("</select>");
      out.write("</td>\r\n\t\t");
      out.write("</tr>\r\n\t");
      out.write("</table>\r\n");
      out.write("</td>\r\n");
      out.write("</tr>\r\n");
      out.write("</table>\r\n\t");
      out.write("<p>\r\n\r\n   \t");
      out.write("<input class=\"button\" type=\"submit\" name=\"create\" value=\"Create\">\r\n   \t");
      out.write("<input class=\"button\" type=\"submit\" name=\"reset\" value=\"Reset\"> \r\n\r\n");
      out.write("</center>");
      out.write("</form>\r\n\r\n");
      out.write("</body>\r\n");
      out.write("</html>\r\n");
    } catch (Throwable t) {
      out = _jspx_out;
      if (out != null && out.getBufferSize() != 0)
        out.clearBuffer();
      if (pageContext != null) pageContext.handlePageException(t);
    } finally {
      if (_jspxFactory != null) _jspxFactory.releasePageContext(pageContext);
    }
  }
}

The line that the exception reports at is just the handler line i.e.

if (pageContext != null) pageContext.handlePageException(t);

John

-----Original Message-----
From: John Eaton 
Sent: 20 February 2004 09:25
To: 'Tomcat Users List'
Subject: RE: Apache Tomcat 4.0 vs 4.1


Yes I can see the jsp page in the work directory.

The reason I chose this title is that it works in Tomcat 4.0.3 but does not work in 4.1.24 or 4.1.29

Thanks
John

-----Original Message-----
From: Shapira, Yoav [mailto:Yoav.Shapira@mpi.com]
Sent: 19 February 2004 16:57
To: Tomcat Users List
Subject: RE: Apache Tomcat 4.0 vs 4.1



Howdy,

>----- Root Cause -----
>javax.servlet.ServletException
>	at
>org.apache.jasper.runtime.PageContextImpl.handlePageException(PageConte
xtIm
>pl.java:536)
>	at
>org.apache.jsp.CreateIndividual_jsp._jspService(CreateIndividual_jsp.ja
va:8
>60)

Can you see the .java page for your JSP in tomcat's work directory?  

Also, why did you choose this subject?  Does it work on 4.0.3 and not on
4.1, or vice versa?

Yoav Shapira



This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged.  This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender.  Thank you.


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


The information in this message is confidential and may be legally privileged. It is intended solely for the addressee.  Access to this message by anyone else is unauthorised.  If you are not the intended recipient, any disclosure, copying, or distribution of the message, or any action or omission taken by you in reliance on it, is prohibited and may be unlawful.  Please immediately contact the sender if you have received this message in error.


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org