iamsiter 0 Newbie Poster

Hi all
I made a welcome.jsp page and included loginbox.jsp using<jsp:include> tag
While loginbox.jsp is working perfectly (with database),but when i include it in welcome.jsp then it dosen't work!!!!Please help
welcome.jsp

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
        <title>JSP Page</title>
    </head>
    <style>
        .bc
        {
       background-color:#CCCC00;   
           background-repeat: no-repeat;
           background-position:center center;
           
         }
        
        
        
    </style>
      <body style="margin-top:0px; margin-left:0px; margin-right:0px; margin-bottom:0px;">
<table cellpadding="0" cellspacing="0" width="100%" border="0" >
    <tr  height="70px" bgcolor="#CCCC00"><td  colspan="9"><jsp:include page="header.jsp"></jsp:include></td></tr>
<tr height="30px" bgcolor="#CCCC00"><td colspan="9"><jsp:include page="linkpage.jsp"></jsp:include></td></tr> 
<tr height="550px"><td bgcolor="#CCCC00" width="25%"><form name="se" action=""><jsp:include page="loginbox.jsp"></jsp:include></form></td><td class="bc" width="58%"   ></td><td bgcolor="#CCCC00" width="17%"><jsp:include page="adpage.jsp" ></jsp:include></td></tr>
  



</table>


</body>
</html>

loginbox.jsp

</head>

<body style="margin-top:0px;">
    <form name="form" onsubmit="chktext()">
<table width="25%" bgcolor="#CCCC00">
<tr height="45px"><td><font face="Verdana, Arial, Helvetica, sans-serif"><b>MemberLogin</b></td></tr>


<tr  height="65px"><th>Username</th><th><input type="text" name="id" /></th><br /></tr>
<tr  height="54px"><th>Password</th><th><input type="password"    align="middle" name="pass" /></th></tr>
<tr><td height="33"></td><td style="color:red; text-align: center;">
        
    <jsp:setProperty name="login"  property="id"></jsp:setProperty>
    <jsp:setProperty name="login"  property="pass"></jsp:setProperty>
    <%
   int d=0;
 
   d=login.check();
    
    if(d==1)
    {
    response.sendRedirect("home.jsp");        
     }
 else if(d==3)
          {
       
       out.println("Please enter a valid password");
          }
   
    else if(d==2)
          {
    out.println("Please enter a valid username and password");
          }   
     
       
   %>
        
        
        
    </td></tr>
<tr  height="58px"><td height="33"></td>
<td align="center"><input type="submit"  style="background-color:#FFFF00 ; color:#000000"value="Login" /></td></tr>



<tr height="134px" >
  <th width="40%"><img  align="left" src="images/man.jpg" border="1" height="80px" width="80px"/></th>
  <td width="59%"><b><font style="text-decoration:blink"><a style="text-decoration:none; color:#000000;" href="brandform.jsp">Become a Friendster<br /> &nbsp;&nbsp;&nbsp; Ambassador</a></font></b>  </td><td width="1%"></th></tr>
<tr height="135px"><th width="40%"><img src="images/2.jpg" align="left" border="1" height="80px" width="80px" />
<td width="59%"><b><font><a href="funstuff.jsp" style="text-decoration:none; color:#000000" ><b>Friendster's Fun Stuff</b></a></font></td>

</tr>
</table>
    </form>
    
    
    
</body>
</html>
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.