I was trying to understand the usage of jsp tags in struts.
Here are the rules for attribute usage for instance consider the following <jsp:useBean id="mybean" class="com.xxx.yyy.mybeanclass" property="myproperty"
scope="request" > :
1. id is used to define a bean
2. name is used to refer to an existing bean (the value is either the value of an id attribute in a previous tag, or is found in application, session, request, or page scope)
3. property is used to select a property from a bean
4. scope tells which scope to search for the bean. If scope is not specified then the bean is searched for in page, request, session and application order)
Tuesday, October 27, 2009
Monday, October 26, 2009
Disabling the use of scriptlets in jsp
The use of scriptlets in jsp can be restricted by making use of <jsp-config> element in web.xml
Refer the following for a sample on how to achieve this.. http://www.java-samples.com/showtutorial.php?tutorialid=548
This can allow best practices to be enforced more easily.
Refer the following for a sample on how to achieve this.. http://www.java-samples.com/showtutorial.php?tutorialid=548
This can allow best practices to be enforced more easily.
Sunday, October 25, 2009
UnsupportedClassVersionError in Java
Most of you would have come across an error like: java.lang.UnsupportedClassVersionError: Bad version number in .class file
[at java.lang.ClassLoader.defineClass1(Native Method)]
on running a compiled java class file.
This error comes when you compile the java file against one version of jdk and run it on an earlier version of jvm. In essence you can not run .class files that are compiled with a newer version than the JVM.
[at java.lang.ClassLoader.defineClass1(Native Method)]
on running a compiled java class file.
This error comes when you compile the java file against one version of jdk and run it on an earlier version of jvm. In essence you can not run .class files that are compiled with a newer version than the JVM.
At Work...
Here starts my new blog which is gonna be the repository of my daily xperiences at work.. the techhy stuff which I come across... :) Hoping 2 b active here...
Subscribe to:
Posts (Atom)