|
|||||||
|
|
|
![]() |
|
|
Strumenti |
|
|
#1 |
|
Senior Member
Iscritto dal: Oct 2000
Città: Udine
Messaggi: 3178
|
[JSP/Beans]help!errore al primo tentativo di usare un bean...
ciao
sto cercando di usare per la prima volta un Bean (come test) in una pagina testbean.jsp. ecco come si presenta testbean.jsp: Codice:
<html> <head> <title></title> </head> <%@ page language="java"%> <jsp:useBean id="test" scope="page" class="testBean" /> <body> </body> ecco la classe testBean: Codice:
class TestBean {
private String nome = "Marco";
public TestBean() {
}
public void setNome(String nome) {
this.nome = nome;
}
public String getNome() {
return nome;
}
}
ottengo un errore: org.apache.jasper.JasperException: /testbean.jsp(6,0) The value for the useBean class attribute testBean is invalid. dove sbaglio? grazie in anticipo |
|
|
|
|
|
#2 |
|
Senior Member
Iscritto dal: Oct 2000
Città: Udine
Messaggi: 3178
|
up
|
|
|
|
|
|
#3 |
|
Member
Iscritto dal: Apr 2005
Messaggi: 87
|
La classe si chiama TestBean no testBean. Cambia il valore di class=testBean in TestBean.
|
|
|
|
|
|
#4 | |
|
Senior Member
Iscritto dal: Oct 2000
Città: Udine
Messaggi: 3178
|
Quote:
ho anche riavviato tomcat a scanso di equivoci |
|
|
|
|
|
| Strumenti | |
|
|
Tutti gli orari sono GMT +1. Ora sono le: 22:29.



















