Adding Page Peel

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
robsteruk
New Member
New Member
Posts: 6
Joined: Fri Jan 09, 2015 5:08 pm

Adding Page Peel

Post by robsteruk »

Hi

I am a newbie to CMS Made Simple and I am wanting to add a page peel feature to me CMS Made Simple site. I am using a widget and need to place a one time piece of code on my website similar to this:

Code: Select all

<__script__ src="http://cdnsysfiles.xxxxxx.net/javascripts/dwms.js"></__script> <__script__ type="text/javascript"> __dwms('123456/wp_12345') </__script>
Howevere I do not know where to place this. Can any body suggest where? Normally on an HTML file it would be placed just before the body tag on the relevant page.

Hope you can assist.

Thanks

Rob
User avatar
velden
Dev Team Member
Dev Team Member
Posts: 3497
Joined: Mon Nov 28, 2011 9:29 am

Re: Adding Page Peel

Post by velden »

Usually this code would be placed in the appropriate page template(s)(Layout -> Templates)

It would however be used on any page that uses that template(s). If that's not what you want you can use a separate template for those pages or use some logic in the template to only use the code on specific page aliases (the latter wouldn't be my favorite approach but it's a quick solution for a fixed number of - not changing - page aliases).
robsteruk
New Member
New Member
Posts: 6
Joined: Fri Jan 09, 2015 5:08 pm

Re: Adding Page Peel

Post by robsteruk »

Thanks for your reply.

I would like it to show on the home page. Sadly I still don't know in which file to add the code.

The site is www.polypostalpackaging.co.uk.

Sorry to appear so thick.

Rob
User avatar
velden
Dev Team Member
Dev Team Member
Posts: 3497
Joined: Mon Nov 28, 2011 9:29 am

Re: Adding Page Peel

Post by velden »

In the page overview in admin the used template is shown in the same row as the page (iirc it's even clickable).

Remember the page alias for the home page and then edit the template.

Before the closing <__body> tag type (assuming page alias for homepage is 'home':

Code: Select all

{if $page_alias == 'home'}
<__script__ src="http://cdnsysfiles.xxxxxx.net/javascripts/dwms.js"></__script> <__script__ type="text/javascript"> __dwms('123456/wp_12345') </__script>
{/if}
Note that this forum add's some underscores in the html tags.
robsteruk
New Member
New Member
Posts: 6
Joined: Fri Jan 09, 2015 5:08 pm

[Solved] Adding Page Peel

Post by robsteruk »

Thank you for your help - much appreciated.

All good now

Rob
Post Reply

Return to “Modules/Add-Ons”