DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/)
-   JSP (http://www.daniweb.com/forums/forum24.html)
-   -   Jsp doesnt return parameter value (http://www.daniweb.com/forums/thread22786.html)

nelly_1005 Apr 29th, 2005 8:54 am
Jsp doesnt return parameter value
 
hi guys

found anotehr probem with my code, i have created a wml page which users input a search criteria, this is then apssed onto a jsp page which prints the value

in teh jsp page though it doesnt print the parametr value and prints out null

code is:
<b><big> Subject:</big></b>
<br/>

<input type ="text" name="srch" height="20" format="*X,*x"/>

<do type="accept" label="Search">

<go href="http://localhost:8080/srch2.jsp" method="post">

<postfield name="Subject" value="$srch"/>


JSP:
<card id="srch" title="Search">


<p>
<%


String Search;
Search=(String)request.getParameter("srch");

out.println("<br/>Search is"+Search);

%>

</p>
</card>

please could anyone tell me what is wrong
PLease thank you

adityabakle May 1st, 2005 6:21 am
Re: Jsp doesnt return parameter value
 
Hey Buddy
I dont know much about wml but i think your JSP file has a tag <code> with
same id
try searching the id and also use get method to confirm that ur parameter is passed to the JSP as the complete url will appear in the address bar
:!:


All times are GMT -4. The time now is 11:41 pm.

Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC