Hello!
I am using a simple Hello World program and including the global.jsp in the body.html file. I am using sightly or HTL for this. Below are the files
contentpage.html
<html>
<head>
<title>Hello World!!!</title>
</head>
<div data-sly-include="body.html"/>
</html>
body.html
<%@include file="/libs/foundation/global.jsp"%>
<body>
<h1>Welcome to HTL</h1>
<h2> I am using Sightly </h2>
<h3>Properties</h3>
<p>Title: ${currentPage.properties.jcr.title}</p>
<h3>Page Details</h3>
<p>Title: ${currentPage.Title}</p>
<p>Name: ${currentPage.Name}</p>
<p>Path: ${currentPage.Path}</p>
<p>Depth: ${currentPage.Depth}</p>
<h3>Node Details</h3>
<p>Name: ${currentNode.Name}</p>
<p>Path: ${currentNode.Path}</p>
<p>Depth; ${currentNode.Depth}</p>
</body>
Problem statement: The global.jsp file is not included, rather the directive "<%@include file="/libs/foundation/global.jsp"%>" is printed as is on the page. See the attached for details. Why is the global.jsp file not included ?
Regards
Harshs
Solved! Go to Solution.
There is no need to include global.jsp in HTL files.
This is required for JSP files
There is no need to include global.jsp in HTL files.
This is required for JSP files
Thanks Feike
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies