JSP

JSP Projects

JSP Project

An Example of Login Page
Previous Home Next

 

Following Example consider for simple login page with username and password.

 

 <html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>R4R TECH SOFT</title>
    </head>
    <body>
        <h1>An Example of Login Page</h1>

        <form action="index.jsp" method="post">
            <table>
                <tr>
                    <td>User Name</td>
                    <td><input type="text" name="username"></td>
                </tr>
                <tr>
                    <td>Password</td>
                    <td><input type="password" name="password"></td>
                </tr>

                <tr>
                    <td>
                        <input type="submit" value="Submit">&nbsp;
                        <input type="reset">
                    </td>
                    <td></td>
            </table>
        </form>


        <%
                    String userName = request.getParameter("username");
                    String password = request.getParameter("password");

        %>
    </body>
</html>

Previous Home Next