• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis

tag library use in included page  RSS feed

 
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there a way to have the included page use a tag libary from the primary page?

Otherwise I see no other solution to double define the tag. Define the same tag in both the included page and the primary page.

The included page is only a fragment containing a table with some <select><option>...</select>
The <form> is in the primary page. I need to use a tag on the form element in the included file and the tag has been defined in the primary page.

I am using request-time inclusion <jsp:include.../>
 
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I am using request-time inclusion <jsp:include.../>



When you use the include action each page is interpreted as a standalone page at run time so you would need to make any declarations needed in each page.

If you use the include directive ( <%@ include file...%> ) then the code is merged at compile time and the whole kitten kaboodle is treated as a single page at run time.
 
Sverre Moe
Ranch Hand
Posts: 110
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there a way to make Eclipse aware of this too?

When I try to use the <spring:bind> tag I get a warning about unknown tag.

Perhaps because the included page has no knowledge of the page that is including it before it is translated.

But when I include a page which have a variable using <%@ include...> I am able to access that variable on the page that is doing the include. And Eclipse seems to know the variable even if it exists on another page
[ July 13, 2007: Message edited by: Sverre Moe ]
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!