Return-Path: Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: (qmail 16839 invoked from network); 8 May 2007 14:02:47 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 8 May 2007 14:02:47 -0000 Received: (qmail 28168 invoked by uid 500); 8 May 2007 14:02:41 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 28147 invoked by uid 500); 8 May 2007 14:02:41 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 28136 invoked by uid 99); 8 May 2007 14:02:41 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 May 2007 07:02:41 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=MSGID_FROM_MTA_HEADER,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of mgainty@hotmail.com designates 65.54.246.241 as permitted sender) Received: from [65.54.246.241] (HELO bay0-omc3-s41.bay0.hotmail.com) (65.54.246.241) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 May 2007 07:02:33 -0700 Received: from hotmail.com ([65.55.138.22]) by bay0-omc3-s41.bay0.hotmail.com with Microsoft SMTPSVC(6.0.3790.2668); Tue, 8 May 2007 07:02:13 -0700 Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Tue, 8 May 2007 07:02:13 -0700 Message-ID: Received: from 24.63.77.77 by BAY133-DAV12.phx.gbl with DAV; Tue, 08 May 2007 14:02:08 +0000 X-Originating-IP: [24.63.77.77] X-Originating-Email: [mgainty@hotmail.com] X-Sender: mgainty@hotmail.com Reply-To: "Martin Gainty" From: "Martin Gainty" To: "Tomcat Users List" References: <4a12aaf80705080633v4f0079bas253a0c144e99eec6@mail.gmail.com> <4a12aaf80705080655g3fae3de6hc3d2e52e46f2c6f4@mail.gmail.com> Subject: Re: request.getParameter is returning the wrong value Date: Tue, 8 May 2007 10:02:01 -0400 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=response Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2180 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-OriginalArrivalTime: 08 May 2007 14:02:13.0263 (UTC) FILETIME=[7A5241F0:01C79179] X-Virus-Checked: Checked by ClamAV on apache.org you are calling js function named 'showCa' but your javascript function name is 'showCap' When/Where do you actually pass these values to servlet? M-- This email message and any files transmitted with it contain confidential information intended only for the person(s) to whom this email message is addressed. If you have received this email message in error, please notify the sender immediately by telephone or email and destroy the original message without making a copy. Thank you. ----- Original Message ----- From: "Richard Sayre" To: "Tomcat Users List" Sent: Tuesday, May 08, 2007 9:55 AM Subject: Re: request.getParameter is returning the wrong value > On 5/8/07, Caldarale, Charles R wrote: >> > From: Richard Sayre [mailto:richardsayre@gmail.com] >> > Subject: request.getParameter is returning the wrong value >> > >> > The problem I am have is when a user clicks the link >> > showCa.jsp?id=2345 >> > >> > The request.getParameter("id") is returning the wrong id! >> >> This is usually caused by application code storing some value in the >> wrong scope, or erroneous use of static variables. Storing a >> request-specific item in the session or servlet objects is one such >> example. >> >> - Chuck > > I store a 'UserSession' object in Tomcats session but it does not > contain a variable called "id". This is the only variable/object that > I am storing in that scope. Everything else is using the 'page' > scope. > > I am passing the "id" parameter through the URL (HTTP GET Method). > > The Generated HTML looks like this: > > 1818 2007/04/13 > > The showCa function: > > function showCap( vId ) { > > > top.location.href="showCa.jsp?editFlag=" + > document.theForm.editFlag.value + "&activeTab=" + > document.theForm.activeTab.value + "&id=" + vId; > > > } > > The JavaScript function redirects the browser. > > On the showCa page the URL in the browser has the right ID. The > request.getQueryString(); returns the proper query string but the > request.getParameter("id") does not return the id that is in the URL > or QueryString > > --------------------------------------------------------------------- > To start a new topic, e-mail: users@tomcat.apache.org > To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org > For additional commands, e-mail: users-help@tomcat.apache.org > > --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org