Any available action to add content before and after sidebar?

You can create your own actions using do_action, like this: <?php do_action(‘before_sidebar’); // you can name it whatever you want ?> <?php if ( is_active_sidebar(‘main-sidebar’) ) : ?> <ul> <?php dynamic_sidebar(‘main-sidebar’); ?> </ul> <?php endif; ?> <?php do_action(‘after_sidebar’); ?> and use add_action() normally: add_action(‘before_sidebar’, ‘before_sidebar_function’); add_action(‘after_sidebar’, ‘after_sidebar_function’); UPDATE: depending on the codex you can use … Read more

Any advice on customising this twitter feed?

It’s part of the Webzine theme – if you take a look at the source, near the bottom, there’s a rather hefty chunk of JS that queries Twitter & renders the tweets. Now whether that code is sat there waiting for you in footer.php, or called in from somewhere else, I don’t know – if … Read more

Extend a plugin to include a widget option

A widget is a PHP object that echoes string data to STDOUT when its widget() method is called. — WordPress Widgets API To create the widget you have to extend the WP_Widget class with your widget class. You use the class name in the register_widget function. class Foo_Widget extends WP_Widget { //Class methods here } … Read more

Issue with checked() echoing on to page

By default, checked echoes. If you set the (currently empty) third parameter to false, it should work as expected. Change the line to: $$sku = isset( $instance[$sku] ) ? checked( (bool) $instance[$sku], true, false ) : false; More info: http://codex.wordpress.org/Function_Reference/checked

Replace the “widgets” label in the backend

Finally, I used this solution to change the “Widgets” label in the sub-menu (Appearence > …): add_action( ‘admin_menu’, ‘adjust_the_wp_menu’, 999 ); function adjust_the_wp_menu() { $page = remove_submenu_page( ‘themes.php’, ‘widgets.php’ ); } add_action(‘admin_menu’, ‘register_custom_menu_page’); function register_custom_menu_page() { add_submenu_page(‘themes.php’, ‘custom menu title’, ‘custom menu’, ‘add_users’, ‘widgets.php’); }`

event organiser not loading in main content area

The page you go to is the single event page. The problem is that the plug-in provided default templates (see the templates directory – for category, venue, single event and event archive pages) do not work with every theme. The solution is simple, copy these template files into your theme folder and edit them there … Read more