Changing Blog Page Type

Permalink 3 users found helpful
I am using the Greek Yogurt theme which has a default blog page type with a left sidebar. I can edit the pagetype to add/move blocks but is there a way to change the page type to a right sidebar using the dashboard options or do I need to modify theme files (if so what change would I make?)

View Replies: View Best Answer
jordanlev replied on at Permalink Best Answer Reply
You need to modify the theme files. You will first want to copy the greek yogurt theme folder and work with the copy (so it doesn't get overridden next time the system updates. On you server, copy this folder:
SITEROOT/concrete/themes/greek_yogurt here:

Then in your new copy of the theme, edit the "blog_entry.php" file, and change this:
<div id="left-sidebar-container" class="grid_8"> this:
<div id="right-sidebar-container" class="grid_8">

And change this:
<div id="left-sidebar-inner"> this:
<div id="right-sidebar-inner">

You might also need to move that whole "right-sidebar-content" div down so it's below the "main-content-container" div... but maybe not.

Good luck!

peverist replied on at Permalink Reply
Hi - thanks for the reply, it worked nicely (I did have to move the updated sidebar to after Main.

I have one more question you may be able to assist with - there is only the option to add to main and add to sidebar when I edit the page type - I have added a navigation block and comment block to the Main area but now the Posted By line appears after the added content when I really want it to display immediately after the heading.

Is there an easy way to change this? Thanks

The code is:
defined('C5_EXECUTE') or die("Access Denied.");
$nav = Loader::helper('navigation');
   <div id="header-image">
      <div class="grid_24 alpha omega" id="featured-image-full">
         if ($c->isEditMode()) {
            print '<br><br>';
            $a = new Area('Thumbnail Image');
jordanlev replied on at Permalink Reply
That is doable but you must be very careful about copying HTML code from one portion of the page to another.

So you have this in the page now:
$a = new Area('Main');

...that is where the main content area is. You will want to move it below the code beneath it. But depending on where you move it to, it might wind up inside a <div> that makes it too small or show up in the wrong place. You will need to experiment with cutting and pasting that portion of code into different parts of the template.... basically though you want to move it after the stuff below it. Hope that makes sense.
peverist replied on at Permalink Reply
Thanks Jordan - that worked well.
avary replied on at Permalink Reply
Hi Jordan!

I had a similar situation... I wanted to change the blog_entry.php file to be a right sidebar layout and your answer helped me to successfully do that. And, as said above, yes, the "right-sidebar-content" div did need to be placed down below the "main-content-container" div.

Your explanations and answers (to questions posted by others that have mirrored my same questions) have helped me in the past as well. I am at the beginner level of learning about concrete5 and I find your answers easy to understand and I really appreciate it!

jordanlev replied on at Permalink Reply
You're welcome! Thanks for the great feedback -- it is very nice to hear.

citytech2 replied on at Permalink Reply
You can do this from admin sitemap. Just Follow the below steps:

Dashboard->Sitemap->Page(Blog Page)->Left Click your mouse on it(a drop-down will appear)->Click Design->Choose a Page Type(Right Sidebar)->save.

That's set.

jordanlev replied on at Permalink Reply
Hi Citytech,
Your solution will work to an extent, but the problem is that the top-level blog index page will not work correctly unless the blog pages are of the "Blog Entry" page type (for example, it will not show comment counts, and might not list the pages at all).
Also, it creates a confusing situation for end-users where they see a "Blog Entry" page type but need to know to choose a different page type (Right Sidebar) each and every time they create a new blog post. And if they want to use the Composer in the dashboard, this will also create problems.
For all of these reasons, I think the better solution is to tweak the blog_entry.php page type template (as shown above).

NateRNY replied on at Permalink Reply
Hello, everyone...this looks like the thread I've been searching for. I'm trying to do a similar thing but I want to eliminate the sidebar entirely. My client wants the blog to be full-width like every other page on the site. I've removed both sidebar <divs> in the blog_entry.php file and uploaded it to root/themes/mytheme but I don't see a there anything I'm doing wrong?
NateRNY replied on at Permalink Reply
Well, figured that to make the rest of the page a full width...