Hola, tengo un problema al llamar a una clase desde una página jsp. Aquí esta el código:
<jsp:useBean id="biblioteca" scope="page" class="GestioLlibres"/>
<%
Llibre[] elsllibres = biblioteca.getLlibres(false);
%>
<HTML>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<p align="center"><font face="Arial, Helvetica, sans-serif" size="2"><b>LLISTA DE LLIBRES DISPONIBLES A LA BIBLIOTECA</b>
</font></p>
<p> </p>
<% if (elsllibres!=null) for (int n=0; n<elsllibres.length; n++) { %>
<%=elsllibres[n].getAutor()%>;<b><%=elsllibres[n].getTitol()%></b>
<br>
<% } %>
</body>
</html>
Estoy utilizando resign por lo tanto la clase la tengo en WEB-INF/Classes. Pues bien siempre me da el mismo error:
[show] /prueba.jsp:2: cannot find symbol
symbol : class GestioLlibres
location: class _jsp._prueba__jsp
GestioLlibres biblioteca;
^
/prueba.jsp:2: cannot find symbol
symbol : class GestioLlibres
location: class _jsp._prueba__jsp
biblioteca = (GestioLlibres) pageContext.getAttribute("biblioteca");
^
/prueba.jsp:2: cannot find symbol
symbol : class GestioLlibres
location: class _jsp._prueba__jsp
biblioteca = new GestioLlibres();
^
/prueba.jsp:4: cannot find symbol
symbol : class Llibre
location: class _jsp._prueba__jsp
Llibre[] elsllibres = biblioteca.getLlibres(false);
^
4 errors
He buscado bastante por google y nada... lo extraño es que es el código de un curso y (acaso que no haya escrito algo mal) no tiene porque haber fallos en la sintaxis.
S4ludos!
Solucionado, usa tomcat :xD