Yes, that's what's weird... I didn't muck around with the original TLD file
or anything...

-----Original Message-----
From: edgar [mailto:edgar@;blue-moose.net]
Sent: Monday, November 11, 2002 3:47 PM
To: 'Struts Users Mailing List'
Subject: RE: Why would disabled="..." not take a runtime expression? The
docs say that it should...


In the struts-html.tld is <rtexprvalue> set to true for the disabled
attribute?


-----Original Message-----
From: Davide Bruzzone [mailto:Davide.Bruzzone@;ngt.com] 
Sent: Monday, November 11, 2002 5:36 PM
To: 'Struts Users Mailing List'
Subject: Why would disabled="..." not take a runtime expression? The
docs say that it should...


Greetings all...

I'm trying to control whether or not some form fields are editable using
a custom security tag. So, at the top of the page, I have something like
this:

<%-- Page security --%>
<bean:define id="readOnly" type="java.lang.String" value="false"/>
                        
<ngt-security:hasNoPermission deny="deny">
        <bean:define id="readOnly" type="java.lang.String"
value="true"/> </ngt-security:hasNoPermission>

If the deny attribute is anything but null or an empty string, readOnly
is set to "true". Then I try to do this:

<html:select property="priority" styleClass="fullwidth" disabled="<%=
readOnly %>">
        ...
</html:select>

What I get back is that the readOnly symbol cannot be resolved...
However, the following tests work:

- <html:select property="priority" styleClass="fullwidth"
disabled="true">
- <%= readOnly %> (On its own... This prints out "true")

This is just strange. According to the documentation, disabled should be
able to take a runtime expression, and I use runtime expressions of the
form <%= someVariable %> all over the palce elsewhere.

Any insight would be greatly appreciated.

Cheers...

Davide Bruzzone


--
To unsubscribe, e-mail:
<mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail:
<mailto:struts-user-help@;jakarta.apache.org>


--
To unsubscribe, e-mail:
<mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail:
<mailto:struts-user-help@;jakarta.apache.org>

--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@;jakarta.apache.org>

Reply via email to