Add Widget area below menu or header in Artister 3.0


Author Message
GMC74

Posted: 3/8/2011
Quote message 

1) Open file page.php and search for this code (1st line!):

<?php get_header(); ?>


--after 1st line add this code:

<?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar('belowmenuwidget') ) : ?>
<?php endif; ?>

2) Now open file fuction.php and search for:

if (function_exists('register_nav_menus')) {
register_nav_menus(array('primary-menu' => __( 'Primary Navigation', THEME_NS)));
}

--Just after add this code:

if (function_exists('register_sidebars')) {
register_sidebars(1,array('name' => 'belowmenuwidget','before_widget' => '<div id="%1$s">','after_widget' => '</div>','before_title' => '<h3>','after_title' => '</h3>'));
}

Now you'll have a new widget called belowwidgetmenu to display slideshow/banners under theme menu! Enjoy :-D

Thanks to Subs for his code (http://www.artisteer.com/?post_id=146746&p=forum_post&topicsPage=2&forum_id=13)

 
Sarah

Posted: 3/10/2011
Quote message 

That may be a good way for 2.6 (not sure since I'm using 3), but if you try to do this with V3, it will not allow you to change the styling of your widget area. I have a post on how to add an extra sidebar to your header, but the same principle applies below the menu, the code that would go into the header.php file would just go into the page.php file instead. There are more steps, but it's more functional. You can find a step-by-step here: http://reflectingthedesigner.com/wordpress/2011/03/09/adding-a-widgetized-sidebar-to-your-header/
 
GMC74

Posted: 3/11/2011
Quote message 

Obviously, the code I entered has been previously tested by me on the version 3 of Artisteer.

It is true that the widget will not be highly customizable, but is generally good for banner and slideshow.

Anyway, you be so kind to show me the article about customizing.

PS: Nice site ;-)
 
Sarah

Posted: 3/11/2011
Quote message 

All you need to do is follow my steps listed from the article linked to above in order for the sidebar to react like all of the other widget areas which give you the dropdown functionality of block styles. The version you listed gives the dropdown, but when you try to choose any of the styles, it doesn't change anything.

I do have a post on adding new widget styles as well that can be found here: http://reflectingthedesigner.com/wordpress/2010/12/31/adding-more-widget-styles-to-wp-part-2/
 
Clippy

Posted: 3/11/2011
Quote message 

Sarah is kind of a god.
 
Sarah

Posted: 3/12/2011
Quote message 

LOL, Clippy! I'm just still learning like everyone else. There are definitely other forum visitors more knowledgeable than me in the coding department.

However, the great thing is, anyone can learn this stuff. Just takes some patience and effort. (and the willingness to learn from mistakes along the way.)
 
Lars

Posted: 5/22/2011
Quote message 

in artisteer 2.6 I got it working when I put the first code below the header object div (thx Sarah!) Thx for tip!