|
|||||
|
Beans let you include more complex functions in your pages without having to clutter up your HTML with lots of code. The Beans referred to with regard to JSPs are different from either the JavaBeans used with IDEs or Enterprise JavaBeans (EJBs), but they serve the same basic purpose -- making complex functions easy to access and reuse. Bean classes have set and get methods which let JSPs access properties.
Beans can be instantiated and the properties can then be called from within
the JSP. For example, if you had a bean class with a property called color,
you could use the following JSP code to instantiate the bean and set the
value of the property color. <jsp:useBean name="colorBean1"
class="ColorBean" /> Once set, the property color can also be read from the bean using the getProperty method: The color is: <jsp:getProperty name="colorBean1" property="color" />
Note: MMA technical support staff cannot provide troubleshooting of problems with third-party CGI scripts including but not limited to: Perl scripts, C/C++ binaries, PHP or web/database integration unless these services are specifically contracted. For these services, please see our Quote Request Form. |
|||||
|
||||||
Copyright
© 1995-2000
Motivational Marketing Associates, LLC
All Rights Reserved.