29 Jan 2012

Tutorial - Show Page Title Widget Area on Homepage Only - Genesis Eleven40 Theme



So some of you may know that I recently upgraded to Genesis's new mobile responsive theme Eleven40. It is an excellent theme and many choose to use it out of the box. But being the design freak that I am I decided upon adding a slider to the page title widget. I figured this would be a pretty simple task and it was easy to install. I did come across one issue though. By default Eleven40's 'page title' widget area appears on all pages but I wanted it on the homepage only. So I experimented and came across the solution. So how did I do it.

Open up your functions.php file.

Find the following code:

/** Add the page title section */
add_action( 'genesis_before_content_sidebar_wrap', 'eleven40_page_title' );
function eleven40_page_title() {
genesis_widget_area( 'page-title', array(
'before' => '<div>',
) );
}

Delete it.

Open up the home.php file

Paste the above code near the top.

It really is as simple as that and now my slider only appears on the homepage. You can of course fill that widget area with whatever you like but I opted for a slider. Eleven40 and Genesis are available here.

 

0 comments:

Post a Comment