JSP Tutorials

JSP Request
Previous Home Next
adplus-dvertising

JSP request implicit object

In JSP request is used an implicit object by HttpServletRequest which means for each jsp request by the web container and to get request information of header ,remote address, server port and name,content type.

Example

index.jsp
    <form action="welcome.jsp">  
    <input type="text" name="uname">  
    <input type="submit" value="go"><br/>  
    </form>  

    <form action="welcome.jsp">  
    <input type="text" name="uname">  
    <input type="submit" value="go"><br/>  
    </form>  
welcome.jsp
    <%   
    String name=request.getParameter("uname");  
    out.print("welcome "+name);  
    %>  

    <%   
    String name=request.getParameter("uname");  
    out.print("welcome "+name);  
    %>  

Output :

Previous Home Next