Expand my Community achievements bar.

Learn about Edge Delivery Services in upcoming GEM session
SOLVED

Where to put sidekick code?

Avatar

Level 1

Hi, I am following this how to page: http://dev.day.com/docs/en/cq/current/howto/website.html

Under the section "Using the Foundation Page Scripts", I can't find where to put the launchSidekick code?? I tried putting it in content.jsp page, but then I got a blank page back.

CQ.WCM.launchSidekick("/content/mywebsite/en/products", {propsDialog: "/libs/foundation/components/page/dialog", locked: false locked: false }); 
1 Accepted Solution

Avatar

Correct answer by
Level 8

Hi,

In the tutorial, you are asked to open the page source and observe the launchSidekick code. The intent is to observe that the page is inheriting content from the foundation/components/page component because of your page component's sling:resourceSuperType property. The inherited content includes the code that launches Sidekick.  So, you don't actually need to do anything with the launchSidekick code.

I hope that makes things clearer

scott

View solution in original post

2 Replies

Avatar

Correct answer by
Level 8

Hi,

In the tutorial, you are asked to open the page source and observe the launchSidekick code. The intent is to observe that the page is inheriting content from the foundation/components/page component because of your page component's sling:resourceSuperType property. The inherited content includes the code that launches Sidekick.  So, you don't actually need to do anything with the launchSidekick code.

I hope that makes things clearer

scott

Avatar

Level 1

Hi Scott, thanks for getting back to me. That is what I though was supposed to be going on, but when I ran the tutorial, no sidekick appeared on the page. I am not sure why it didn't appear, thought that I had forgot to add the code somewhere. Apart from that, the rest of the tutorial worked fine.