File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Struts and the fly likes html taglib struts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "html taglib struts" Watch "html taglib struts" New topic

html taglib struts

pedro costa

Joined: Mar 24, 2011
Posts: 7
Good afternoon in my timezone.

I have a few little doubts regarding the use of this tag library and the actionForm. I want to put a inputText in my page , but this input text will be read only.So i did not put any thing in the actionForm object because this is a readOnly text(just to display data). I put the information in the request scope (request.setAttribute("readOnly","data")). In my jsp i have

<html:form action="action1">
<html:text name="actionForm" property="inputText1"/>
<html:text name="actionForm" property="inputText2"/>
<html:text property="readOnly" readonly="true"/>

This is not working(if i remove the last field everything works fine), so i put the following questions ? Is it possible using <html:text> to access attributes in any scope,regardless the actionForm bean ?The documentation provide us with two properties to define the bean from where we want to retrieve the values (name=name of the bean and property=name of the property inside the bean).But it does not say anything about scopes(requst,scope). So can i use this taglibrary or i have to go by another way ?

Thanks in advance
I agree. Here's the link:
subject: html taglib struts
It's not a secret anymore!