Concrete5 CMS Page Type and Page Templates (defaulting to default.php)
Permalink
I have just got into a new clients office today to fix up a site using Concrete5 CMS however im having an issue with something. (Never used this CMS before so think ive done ok so far)
Issue im facing is this:
I created 2 new page types: blog and blog article
I created 2 new page templates blog.php and blog_article.php
I assigned to the page types what templates to use as default
However when i view the the blog page or a blog article page it was not using the templates i found but always using default.php template.
Anyone have any ideas why this might be and why it is not using the page templates i assigned to the page types?
Thank in advance to any help here.
Issue im facing is this:
I created 2 new page types: blog and blog article
I created 2 new page templates blog.php and blog_article.php
I assigned to the page types what templates to use as default
However when i view the the blog page or a blog article page it was not using the templates i found but always using default.php template.
Anyone have any ideas why this might be and why it is not using the page templates i assigned to the page types?
Thank in advance to any help here.
Hey thanks for coming back to me, it is the latest version of Concrete5 and they are in application\themes\theme_storem and yep i done the import from what i can remember
Thanks in avance
Thanks in avance
Hi guys, pulling my hair out this morning with this, here is everything as follows:
Files located in: application\themes\theme_storem\
blog_article.php
I have attached screenshots of the admin areas etc..
Hope someone can spot what im doing wrong, totally new to concrete5 and 2nd day on the job so need to make some good progress today haha
Files located in: application\themes\theme_storem\
blog_article.php
<?php defined('C5_EXECUTE') or die(_("Access Denied.")); ?> <?php $this->inc('elements/header.php'); ?> <div class="ccm-page page-type-blog-article page-template-full"> <div class="container"> <div class="row"> <div class="col-sm-8 col-content"> <?php $a = new Area('Main'); $a->setAreaGridMaximumColumns(12); $a->display($c); print $innerContent; // testing ?> </div> <div class="col-sm-offset-1 col-sm-3 col-sidebar"> <?php
Viewing 15 lines of 51 lines. View entire code block.
I have attached screenshots of the admin areas etc..
Hope someone can spot what im doing wrong, totally new to concrete5 and 2nd day on the job so need to make some good progress today haha
Hi,
forgive me if I am missing something but why have you got
'print $innerContent;'
on the template. This is only normally used on the view.php file?
forgive me if I am missing something but why have you got
'print $innerContent;'
on the template. This is only normally used on the view.php file?
That was me just testing stuff, im new to concrete so was just playing with it so can ignore that.
No worries. I did experience a similar error to you when I first came over from 5.6 to 5.7.
I found 'clear cache' in the dashboard fixed it.
I found 'clear cache' in the dashboard fixed it.
It turns out that the issue was the Edit Defaults for the page template were not set.
Again thanks for all your help mate
What version of concrete5 are you using?
Where did you put the page template files?
After adding the page template files, did you "import" them?
Dashboard > Pages & Themes > Themes > click Page Templates button of active theme > Page Templates in Theme > click Ok button