Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Missing Template/Theme Folders


Go to End


7 Posts   1018 Views

Avatar
MikeG12

Community Member, 4 Posts

16 January 2015 at 11:33am

Edited: 16/01/2015 11:35am

Hello,

I am helping a friend add the Google Tag Manager code snippet into each page of his website. He paid someone to create his website, but he was given full admin privileges which I now have. When I go to the page editor and click the little "html" button, the only code I find is the written content for the webpage starting with <p>. I know you are supposed to paste the code snippet directly after the <body> tag, but would it work if I paste it into the first line of content code instead?

I only ask this because for the life of me I cannot find where the <heading> and <body> tags are. I figure they are in some sort of .ss theme or template, but the only files I see in the CMS are photos for the background and galleries. On the CMS menu I see the following:

Hi Admin (With log out button)
Pages
Files
Reports
Security
Settings
Help

I went through all of them but found nothing on the template or theme. Is this something that only the original person who created the site can access or am I looking in the wrong place.

I greatly appreciate any help you all can supply!

Avatar
stallain

Community Member, 68 Posts

16 January 2015 at 11:49am

Hi,
You can't modify the template file you're looking for (Page.ss) within the CMS. You'll have to retrieve it from the server by FTP, edit it in a text editor, then send it back to the server.

Avatar
MikeG12

Community Member, 4 Posts

16 January 2015 at 12:23pm

I think my noob is going to show here, but do I have to contact the web developer to get the page.ss or can I access the server to get that file through FTP myself with just the admin privileges.

I'm not even sure what server I should be trying to access. The one hosting the domain right?

Avatar
stallain

Community Member, 68 Posts

16 January 2015 at 8:42pm

The admin privileges are for the CMS only. To access the server (the one that hosts the Silverstripe files : php, templates, javascript...) you need to get the FTP credentials, which have nothing to do with the CMS password and login. Then use a FTP client, such as Filezilla. If you don't know at all what I'm talking about (everybody has to start somewhere !), contacting the web developer is probably the best solution.

Avatar
MikeG12

Community Member, 4 Posts

17 January 2015 at 2:04am

Thankfully I do understand exactly what you're talking about! I'll try to get a hold of him to get the login info for the server since it appears that will be the only way to get that tag in there.

Thanks so much for your help!

Avatar
MikeG12

Community Member, 4 Posts

20 January 2015 at 9:06am

I have a problem related to this one so instead of making a whole new topic, I'll just ask here.

The CMS is stripping any Javascript I manually enter into the "content" section of each page and replacing it with "<p>&nbsp;</p>"
I figure that the content field only supports simple html and not javascript. However, is there any way I can reconfigure it to allow Javascript to be inserted into the content section?

Avatar
stallain

Community Member, 68 Posts

20 January 2015 at 11:33am

Edited: 20/01/2015 11:34am

I'm not a 100% sure, but I think it's not possible, unless you set your own shortcode : http://www.silverstripe.org/community/forums/general-questions/show/25571
But again, the easiest way to do so is to put your js code directly in the template, or even better to include it via the page requirements : http://doc.silverstripe.org/framework/en/reference/requirements