• 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

forEach tag

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can we put Scripting code in the body of foeEach tag?
 
Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi
no!.. scripting cant be done in tags..
beacause the basic reason for using tags is to eliminate scripting....inorder to develop scriptless jsps..we use tags...hence we cant use scriptlets or scripting code inside a tag..
try an example...with that...u can learn by the container given error more than anything else..
hope this helps
ranchers correct me if i am wrong

regards
vandu
 
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

ranchers correct me if i am wrong


I take the opportunity to do so

forEach tag's body content is JSP, which means that you can put some JSP in it, which will be interpreted by the container.




The basic reason to use tags is not to eliminate scripting(of course it helps eliminate scripting), but to make programmer's life easier, especially for those who are responsible to make JSP but who have little knowledge on Java.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic