Hi
I am just trying to get hang of
struts and the tag libraries provided with it . New to this concept .
gettin some errors while using the html:select tag in my
jsp page .
Request all u guys to help me out with it .
Below is my code and the eror i get on the jsp page.
---jsp page -----
<%@ page language="java" import="java.util.*"%>
<%
System.out.println("inside index.jsp");
%>
<%@ taglib uri="/tags/taglib/struts-html" prefix="html"%>
<%@ taglib uri="/tags/taglib/struts-bean" prefix="bean"%>
<%@ taglib uri="/tags/taglib/struts-logic" prefix="logic"%>
<html:html>
<head>
<title>Struts tutorial</title>
</head>
<body>
<table>
<tr>
<td>This page uses tag library </td>
</tr>
<tr>
<td>
<html:select property="id">
<html
ption value="1">option 1</html
ption>
<html
ption value="2">option 2</html
ption>
<html
ption value="3">option 3</html
ption>
</html:select>
</td>
</tr>
</table>
</body>
</html:html>
--message on screen is ----
org.apache.jasper.JasperException: Exception in JSP: /index.jsp:19
16: </tr>
17: <tr>
18: <td>
19: <html:select property="id">
20: <html
ption value="1">option 1</html
ption>
21: <html
ption value="2">option 2</html
ption>
22: <html
ption value="3">option 3</html
ption>
Stacktrace:
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:504)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:375)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
root cause
javax.servlet.ServletException: Cannot find bean under name org.apache.struts.taglib.html.BEAN
org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:858)
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:791)
org.apache.jsp.index_jsp._jspService(index_jsp.java:82)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
root cause
javax.servlet.jsp.JspException: Cannot find bean under name org.apache.struts.taglib.html.BEAN
org.apache.struts.taglib.html.SelectTag.calculateMatchValues(SelectTag.java:240)
org.apache.struts.taglib.html.SelectTag.doStartTag(SelectTag.java:200)
org.apache.jsp.index_jsp._jspx_meth_html_select_0(index_jsp.java:140)
org.apache.jsp.index_jsp._jspx_meth_html_html_0(index_jsp.java:111)
org.apache.jsp.index_jsp._jspService(index_jsp.java:75)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
I am new to this technology so cant understand the error .
Need some urgent help as i need to implement this .
Thanks for all the help in advance .
Avneet