• Post Reply Bookmark Topic Watch Topic
  • New Topic

INCLUDE syntax for html

 
Jeff Satori
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am to display a company name in the title bar of our HTML & JSP pages. I have modified all .jsp pages to have an <@include file="title.html" @> which works great but I am not sure how to do the same for html.
I have tried the following syntax
<!-- #INCLUDE FILE="title.html" -->
but it doesn't seem to work.
Any suggestions?
 
Jeff Satori
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I forgot to mention, the title.htm has only the following line.
<title>(Insert Company Name Here) </title>
 
Tim Holloway
Bartender
Posts: 18414
58
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The <!-- #include --> syntax isn't supported by HTML - it's a directive to a properly sensitized web server, just as <% %> tags are directives to JSP processors. In the Apache web server, you have to have mod_include activated as well as doing several other things that I usually screw up before it will work.
If you're not fronting the appserver with a regular web server (such as apache), you should just change the html page to JSP and use the JSP include feature.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!