We do not currently use ActionForms, so Im not sure if that would be a better
place to do this, however, here is what we have done.
We have not yet added security to fields depending on the user, however, that
should not be too big of a deal to add.
We have a set of fields that may never be changed, such as table keys, etc.
These fields, we use the "readonly" attribute to stop those that are using IE
from thinking that they may modify the data.
Our Action class only retrieves those fields that the user should have access
to modify. The other fields, we should be able to retrieve from somewhere
else if needed.
(maybe from a bean stored in the session, for example).
If you want to allow different users to modify different fields:
In our approach, you would check the users access before retrieving each field
in the action class. Then decide where to get the information from... The
form, or a bean.
This is only one approach, Im sure that there are others. You may want to
look into the ActionForm. This may be a better place to handle it.
I am interested in other options as we will be starting to look into field
level security in the next couple of months.
HTH,
Pete
Firmin David wrote:
> Do you have an example of how you'd control this in the Struts action, as
> I'm having the same problem with Netscape and can't solve it.
>
> Thanks in advance for any help.
>
> -----Original Message-----
> From: Peter Alfors [mailto:[EMAIL PROTECTED]]
> Sent: 05 April 2001 16:22
> To: [EMAIL PROTECTED]
> Subject: Re: DISABLE TEXT FIELD ON JSP
>
> IE accepts the readonly attribute on the input field.
> However, Netscape ignores it.
> Therefore, to be safe, you should handle this in your action.
>
> [EMAIL PROTECTED] wrote:
>
> > HI,
> > Does anybody know the trick how I can disable all or some text fields on
> JSP
> > to make sure use can not change anything on the form..
> >
> > Thanks N Regads
> >
> > TAHIR IQBAL
> >
>
> ************************************************************************
> The information in this email is confidential and is intended solely
> for the addressee(s).
> Access to this email by anyone else is unauthorised. If you are not
> an intended recipient, you must not read, use or disseminate the
> information contained in the email.
> Any views expressed in this message are those of the individual sender,
> except where the sender specifically states them to be the views of
> The Capital Markets Company.
>
> http://www.capco.com
> ***********************************************************************
begin:vcard
n:;
x-mozilla-html:FALSE
org:<BR><IMG SRC="http://www.irista.com/logo/irista.gif"><BR><BR><FONT Color=#000080><FONT SIZE=2><B>Bringing Vision to Your Supply Chain
adr:;;;;;;
version:2.1
end:vcard