Correct answer is <jsp:useBean name="People" class="People"/> I am looking in the jsp1.2 syntax card under <jsp:useBean> and i don't see name. There is beanName but not name. Also, according to the syntax card id="" is requred in <jsp:useBean>? I have also read somewhere that beanName (name) and class="" can't be together in the same <jsp:useBean> tag. Can someone care to elaborate on this...
Originally posted by Miftah Khan: An interesting finding: Check out William Brogden's post at http://www.javaranch.com/ubb/Forum7/HTML/006099.html . It implies that the value of the class attribute in a <jsp:useBean> call must include a package name, e.g. class="com.javaranch.People".
Actually this depends on your server. Some servers compile JSPs compile into the default package, and so don't need the import statement. Tomcat doesn't compile JSPs into the default package, so you need to put your classes in a package and specify it. Even if your server compiles to the default package you should specify a package for your own classes, to retain portability.
You can't have everything. Where would you put it?
Two software engineers solve most of the world's problems in one K&R sized book