This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Remove and Set Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Remove and Set" Watch "Remove and Set" New topic
Author

Remove and Set

satyam bobba
Greenhorn

Joined: Jan 30, 2006
Posts: 10
<c:set var="a" value="b" />

<c:set var="${a}" value="c" />

<c:remove var="${a}"/>

In HFSJ book mentioned the var attribute remove tag should not be expression.

But i am not getting any error?

I tried in manner also<c:remove var="<%=a%>"/>

Can i use expression for <c:set> and <c:remove> for var attribute?
Narendra Dhande
Ranch Hand

Joined: Dec 04, 2004
Posts: 950
Hi,

Which JSTL version you are using ? According to the JSTL 1.1 the "var" attribute of "set" tag does not accept the expressions. It is compilation time error.

Thanks


Narendra Dhande
SCJP 1.4,SCWCD 1.4, SCBCD 5.0, SCDJWS 5.0, SCEA 5.0
satyam bobba
Greenhorn

Joined: Jan 30, 2006
Posts: 10
I am using JSTL 1.0 . What is the Latest version
Narendra Dhande
Ranch Hand

Joined: Dec 04, 2004
Posts: 950
Hi,

I think the stable release is JSTL 1.1, which is also in Exam. The JSTL 1.2 is under Maintainence realease.

Thanks
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Remove and Set
 
Similar Threads
a JSTL question in Whizlabs Exam Simulator
How does c:remove scope=... work?
c:remove
c:set var question
c:remove custom tag