Support » Multisite » Add a global sidebar with widgets?

Add a global sidebar with widgets?

  • Is there a way to create a widgeted global sidebar that will show up on all child sites?

    There is only one child theme on my site and I have it set up so that a global sidebar appears and I can add html to it, but if I try to add in widget functions, they don’t display.

    Is it possible to make a global sidebar with widgets or will it all have to be hard-coded?

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hard coded would actually be the best way around it, as cross-site traffic can get expensive (CPU wise)

    What about pulling in something like the most recent posts from across the site? Is that doable?

    There’s a plugin for that – Diamond Multisite Widgets. It uses caching to make magic happen with less drama on the CPU 🙂

    I tried that but it breaks my theme. Here is my sidebar code:

    <div id="sidebar-alt" class="sidebar widget-area">
    	<div id="text-4" class="widget widget_text">
    		<div class="widget-wrap">
    			<div class="textwidget">
    				<img src="/images/advertise.jpg" alt="Advertise Here" />
    				<img src="/images/advertise.jpg" alt="Advertise Here" />
    	<?php DiamondRP(); ?>

    If I remove the DiamondRP code, the theme renders fine. When I put it back in, I lose my buddypress menu bar and my footer. Any suggestions?

    Can’t you echo the shortcode in your template?

    <?php echo do_shortcode('[shortcode option1="value1" option2="value2"]'); ?>

    It literally just puts [shortcode option1=”value1″ option2=”value2″] on the screen. Just echoes the text.

    Ok – duh – I didn’t even read it. If I use the PROPER shortcode for the widget I get the right output. 😀

    Now my issue is that the custom widget I need to display there doesn’t have shortcode. Guess I will have build that into the plugin in order for it to work in my global sidebar.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Add a global sidebar with widgets?’ is closed to new replies.