• 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

Question on including file by directive

 
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My view.jsp:

<html>
<body>
AAAAAAAAAA
<%@ include file="footer.html" %>
</body>
</html>

Then, I changed content of footer.html, then I access the view.jsp again. How come view.jsp now shows new content of footer.html?

I'm confused. Since I didn't change view.jsp and directive include happens at translation time, the content of view.jsp should not be changed. Right?

Thanks,
Jenny
 
Ranch Hand
Posts: 152
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Jenny

My guess is you are using one of the popular web servers like tomcat , weblogic , websphere etc

These are termed as "intelligent servers"(as termed in HFSJ)
which can detect when the file has been changed even when you make use of include directive

Hence for most modern web servers include directive works same as jsp irective even though it is not guaranteed by the spec

Catch You Later
Shiva
 
Jingh Yi
Ranch Hand
Posts: 90
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks, Shiva! Tomcat is too smart for me...
 
Normally trees don't drive trucks. Does this tiny ad have a license?
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic