Posts: 7
Threads: 1
Joined: Oct 2014
Hi. I'm new to this CMS and it looks great. I've installed it twice on two servers and I've installed a few extra themes.
In all cases, I'm having difficulty changing the templates for a specific page. When I use the admin page to select a different template and then view the page, it always continues to look like the homepage (default) template no matter what I try. I tried flushing the cache as well. I added HTML comments into the default template.php file to differentiate it from wide.php and others so I can confirm that the default template is always being displayed/used. Switching between themes seems to show the same problem as well. Any ideas on how I can solve this problem?
Thanks in advance!
Posts: 6,267
Threads: 182
Joined: Sep 2011
What version of gs ?
Are you using i18n ?
Posts: 7
Threads: 1
Joined: Oct 2014
(2014-10-14, 00:17:11)shawn_a Wrote: What version of gs ?
Are you using i18n ?
Thanks for the response. I've got what I think is the latest - 3.3.4. I do not have i18n installed yet. It looks like its almost ubiquitous for most sites on GS, yes?
Posts: 6,267
Threads: 182
Joined: Sep 2011
Check health check and error log, perhaps something is not saving properly.
I will test here.
Posts: 7
Threads: 1
Joined: Oct 2014
The health check says all is ok. The logs don't have any issues to report either. Here is the pretty default site setup: http://clientextranet.us/lang/bowlarama/2014/. Just two pages and second page is supposed to show a different template with sidebar. but it is clearly using default as it now says so in the html comments.
Posts: 6,267
Threads: 182
Joined: Sep 2011
Just tested locally on stable, works fine for me.
When you go back to edit that page, does it show the template saved?
Just not on front end ?
Try deleting page cache data/other/pages.xml
Posts: 6,267
Threads: 182
Joined: Sep 2011
Works for me content.php set as template shows a totally different page with a sidebar
Posts: 7
Threads: 1
Joined: Oct 2014
that's crazy. I've used two browsers and installed the sites on two servers. So this - http://clientextranet.us/lang/bowlarama/2014/ - and this - http://clientextranet.us/lang/bowlarama/2014/index/second-page/ look different to you?
Posts: 7
Threads: 1
Joined: Oct 2014
I've tried three computers, two different operating systems, and 6 different browsers and those two pages all look the same on my end. Thanks for your time looking at this. Let me know if you see them as being different from each other. I'll be aghast but very thankful to know.
Posts: 7
Threads: 1
Joined: Oct 2014
I think the issue is with the Handcrafted theme. Once I install it, all subpages seem to break. A fresh install without it seems to work ok.
Posts: 6,267
Threads: 182
Joined: Sep 2011
Yeah they are the same some thing is overriding your install, it's not the theme afaik , it works for me.
A theme that is not active is breaking your site? Not sure how that's possible as it should not even be included unless it's active. Now there is a file check that falls back to template.php so if our file exists check failed it could do this.
Posts: 7
Threads: 1
Joined: Oct 2014
there is definitely something odd kicking in that prevents using any template besides template.php. could you point me to the file check logic in the code so maybe I can have it log when it has to use the default instead of the other one?
Posts: 6,267
Threads: 182
Joined: Sep 2011
in 3.3.4 is should be at the bottom of index.php
something like
PHP Code:
# include the template and template file set within theme.php and each page
if ( (!file_exists(GSTHEMESPATH .$TEMPLATE."/".$template_file)) || ($template_file == '') ) { $template_file = "template.php"; }
include(GSTHEMESPATH .$TEMPLATE."/".$template_file);
try a
die($template_file); before that and see if its picking up the template from the page cache properly first.
it gets set in the same file
$template_file = $data_index->template;
just like other fields, are you seeing other fields update properly?Like title, menu text etc.
Posts: 6,267
Threads: 182
Joined: Sep 2011
and make sure if you upgraded you copied the index.php file as well as the admin directory, people forget to do that and have old broke ass index.php files.