We help IT Professionals succeed at work.

Check out our new AWS podcast with Certified Expert, Phil Phillips! Listen to "How to Execute a Seamless AWS Migration" on EE or on your favorite podcast platform. Listen Now

x

Wordpress - I want some pages to be 2 column and some pages to be 3 column -- is it possible?

Rowby Goren
Rowby Goren asked
on
Medium Priority
462 Views
Last Modified: 2012-05-07
I have a client who wants a wordpress site.  She wants the "non blog" pages to be two columns and the blog pages to be three columns.

Is this possible?  And if so how can that be accomplished?  With a special template?  With a special widget?

Thanks,

..Rowby
Comment
Watch Question

Commented:
Hi Rowby,

Yes, this is easily accomplished. Different elements of wordpress are defined by the different files in your theme folder.

Within your theme - "single.php" would be the template that you use for your posts (blog). "page.php" would be the template that you use for non-blog pages. You can create custom page templates as well.  Your CSS within single.php and within page.php can be completely different.

You can also create custom page templates. Each page (non-blog) page can have different styling. See: http://codex.wordpress.org/Pages#Page_Templates

Multiple post templates require some uhm, lets say hacks. It's not as easy as creating multiple page templates.

Take a look at this page: http://codex.wordpress.org/Using_Themes - Scroll down and look at the section called "creating themes". You will see which template files produce which types of pages, and what needs to be included in each file.

Other useful links:
http://codex.wordpress.org/Templates
http://www.jonathanwold.com/tutorials/wordpress_theme/

Author

Commented:
Thanks razor19,

I will be working on your solutions tomorrow. Stay tuned!

Rowby

Commented:
Cool - let me know if you need any help.

Author

Commented:
Hi razor19,

Here's my test wordpress site:

http://rowby.com/wordpress2/

NOt sure if this template has built into it any 2 column versions.  

Any thoughts before I dig in?

Thanks

...Rowby

Author

Commented:
It's weird. In the back end I add a page (not a blog) but it does not show upo in the left navigation.

In fact in the back end I cannot see any of the pages (not blogs) even listed.)  So I can't even edit them.

Am I missing a widget or something?  

Rowby

Author

Commented:
Ah,

I found and activated the widget to show my pages.

Rowby

Author

Commented:
But, I sse that those pages are also three columns.  So I am back to seeing how to make page pages 2 column.  I will review your initial comments and links.

...Rowby

Author

Commented:
Ah, I edited th page.php  and it seems to have done the trick!.

Stay tuned. I may have a few questions as I do this.

Rowby

Commented:
LOL - Sorry - I was away for the computer.

Yes - that's right - editing the page.php will give your non-blog pages a different look.

You can create different templates for pages too - if you need - and select them under "page template" when you create the pages.

I'll be around now for a while - let me know if you need more help!

Author

Commented:
Hi razor19.

So far all is working fine.

1)  The "Page" pages  are two column with the pages navigation on the left
2)  The Blog pages are 3 columns with the page navigation on the left and the blog stuff on the right.

I think all I need from you now is how do I make the home page like a "Page" page, -- two columns with the pages navigation on the left.

Thanks

Rowby

Author

Commented:
Some more issues.

THere are items in this template that I don't want to be live and I don't know how to deactivatre them.

For example:
Left column: Navigation.  I don't see a widget for that in the back end.  The navigatin includes Home and About and I don't see where those are coming from in the wp-admin.

The blogroll on the right.  How do I turn that off?  I don't see a widget for that.

Perhaps there are wordpress settings that turn these things on and off???  Hmmmm  I'll dig through the configuration ....

Author

Commented:
Hi razor19,

HEre's another question (and pl;ease let me know if I should post it as a separate question.

Regaridng H1 tags.  I am trying to switch the title H2 tags to H1 tags.

This article says how to do it  but I am a bit lost because my single.php page already has h1 as the title tag.  Is there a plugin or widget that can do it or do you know how to switch title h2 tags to H1 tags.


http://www.medianetrix.com/wordpress/5/maximum-seo-with-wordpress-h1-header-tags/
HEre's my single.php
 
<?php get_header(); ?>
 
	<div id="content_box">
	
		<div id="left_box">
	
			<div id="content">
		
				<div id="content_inner">
<?php 
				if (have_posts()) : 
					while (have_posts()) : the_post(); ?>
		
					<h1><?php the_title(); ?></h1>
					<p class="post_author"><em>by</em> <?php the_author(); ?></p>
					<div class="format_text">
<?php the_content('<p>Read the rest of this entry &raquo;</p>'); ?>
<?php link_pages('<p><strong>Pages:</strong> ', '</p>', 'number'); ?>
					</div>
		
				</div>
		
				<?php comments_template(); ?>
<?php 
					endwhile;
				else: ?>
	
					<h1>Uh oh.</h1>
					<div class="format_text">
						<p>Sorry, no posts matched your criteria. Wanna search instead?</p>
<?php include (TEMPLATEPATH . '/searchform.php'); ?>
					</div>
				
				</div>
<?php 
				endif; ?>
		
			</div>
		
			<?php include (TEMPLATEPATH . '/left_bar.php')?>
	
		</div>
	
		<?php get_sidebar(); ?>
		
	</div>
 
<?php get_footer(); ?>

Open in new window

Author

Commented:
Hee hee

I hope you don't mind me using this experts  Experts Exchange question  as a notepad!!

As I work I see that the individual page titales are now inded h1.  It appears only the blog titles are h2.  I guess there is a similar page for blog pages that I need to look for the h2 tag....

Rowby

Author

Commented:
H1 issue is resolved.

Now I am back to getting the home page to have two columns instead of 3.

Could that be because the home page is actually a blog page?   IF that is the case then I need to make the home page a regular page.

Then I would need a link to the site's "BLOG section"  right?  

Hmmmmm.   How to do that....

....Rowby

Author

Commented:
I found this link showing how to make the home page a "regular page".

http://www.facilitatingchange.org/2009/05/wordpress-blog-not-on-home-page/

I assume it will work and solve "that" issue.

I have to leave for a few hours.  I'll report when I get back.

In the mantime if you have any thoughts just post them  here.

Rowby
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION

Commented:
Yes - that link you posted is precisely what I am saying. :)

Author

Commented:
razor19,

YOu've answered my question and I am awarding you the points.

I have some more formatting and setting questions and am posting that question now here.

Please look if you have some time.

Rowby

Author

Commented:
thanks and please look at my next wordpress question which I am putting up now.
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.