• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Headfirst Servlets and Jsp <c:set> pg.457

 
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ranchers, I'm just confused with this line in Headfirst Servlets and Jsp <c:set> pg.457.

It say's here that:

"You can never have both the "var" and "target" attributes in a <c:set>."

But when I try this block of codes it's working fine.

Here is the servlet doGet:


Here is the Jsp:


Hi ranchers hope you could help me!

Thanks!
 
Ranch Hand
Posts: 238
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i think you can use both together..
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The JSP specification does not say anything in this case. There are only four syntaxes expected :

If it's not one of these, I guess that it's up to the container to decide what to do.
 
Neil Muya
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi guys,

Hmmm.. Does this mean that Headfirst Servlets and Jsp Rules regarding <c:set> is with an older version of jstl?

I am wondering on what rules to follow for the exam SCWCD 5..


Quite confused..

But anyway thanks for the reply guys.

 
Creator of Enthuware JWS+ V6
Posts: 3411
320
Android Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Neil,

Hmmm.. Does this mean that Headfirst Servlets and Jsp Rules regarding <c:set> is with an older version of jstl?


No, they are correct: don't use both of them at the same time (although you can)

I am wondering on what rules to follow for the exam SCWCD 5..


The exam always follows the official specifications which means one of the four possibilities that Christophe gave you

Regards,
Frits
 
It's just like a fortune cookie, but instead of a cookie, it's pie. And we'll call it ... tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic