Adding a new widgetized area to pages


show more Adding a new widgetized area to pages provides you with in-depth training on Web. Taught by Morten Rand-Hendriksen as part of the WordPress 3: Building Child Themes show less
please wait ...

Adding a new widgetized area to pages

Earlier in this course I talked briefly about widgetized areas and sidebars. Now we're going to take a look at how you can add new widgetized areas to your site. One reason you may want to do this is if you want to offer up different widgets on your pages from those that are on your index and single posts. To add a whole new widgetized area we first have to add to the existing function that creates widgetized areas and then we have to add that area to a new sidebar file, or somewhere else. In our functions.php file you find the function that registers the sidebars at line 195.

It's called twentytwelve_widgets_init, and in it you have three instances of this register_sidebar function. What we want to do is add another one of these functions with our new sidebar. So I'm simply going to copy this register sidebar array out and then I'm going to go to the functions.php file in my child theme and I'll use this original my child theme setup function and I'll just put t...

Adding a new widgetized area to pages
Video duration: 4m 9s 3h 11m Intermediate Updated Nov 27, 2012

Viewers:

Adding a new widgetized area to pages provides you with in-depth training on Web. Taught by Morten Rand-Hendriksen as part of the WordPress 3: Building Child Themes

Subject:
Web
Software:
WordPress
Author:
please wait ...