sidekick not showing up because not included head.jsp? | Community
Skip to main content
Level 3
October 16, 2015
Solved

sidekick not showing up because not included head.jsp?

  • October 16, 2015
  • 1 reply
  • 1232 views

Hi,

  I am a newbie to CQ5 and I am trying to follow this tutorial to create a simple page with a sidekick. http://dev.day.com/docs/en/cq/current/howto/website.html

  This is my contentpage.jsp

 <%@include file="/libs/foundation/global.jsp"%><%
%><%@page session="false" contentType="text/html; charset=utf-8" %><%
%><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<cq:include script="head.jsp"/>
<cq:include script="body.jsp"/>
</html>

And I found something weird. If i remove cq:include head.jsp, the sidekick will not show on the page. I wondered why? If this is a mandetory on the page, what else are mandetory?

 

Thank you

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by PaulMcMahon

Well head.jsp is not itself mandatory, however it does do some mandatory things which whether you rely on the inherited head.jsp, or you create your own head.jsp need to happen. You can see what it does by looking at /libs/foundation/components/page/head.jsp in CRXDE Lite.

  • The reason sidekick isn't showing up is that head.jsp includes /libs/wcm/core/components/init/init.jsp. init.jsp includes authoring related CSS and JavaScript and launches the sidekick. 
  • head.jsp also prints out the html head element of your page - without a head element your page isn't a valid HTML page. 
  • It also includes headlibs.jsp which is responsible for including your page's CSS and JS. 

In most real world scenarios you override both head.jsp and headlibs.jsp in order to match your project's requirements. 

1 reply

PaulMcMahonAccepted solution
Level 8
October 16, 2015

Well head.jsp is not itself mandatory, however it does do some mandatory things which whether you rely on the inherited head.jsp, or you create your own head.jsp need to happen. You can see what it does by looking at /libs/foundation/components/page/head.jsp in CRXDE Lite.

  • The reason sidekick isn't showing up is that head.jsp includes /libs/wcm/core/components/init/init.jsp. init.jsp includes authoring related CSS and JavaScript and launches the sidekick. 
  • head.jsp also prints out the html head element of your page - without a head element your page isn't a valid HTML page. 
  • It also includes headlibs.jsp which is responsible for including your page's CSS and JS. 

In most real world scenarios you override both head.jsp and headlibs.jsp in order to match your project's requirements.