Ask your WordPress questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

How to reorder items/widgets in sidebar using mimbo 2.2 theme? WordPress

  • SOLVED

In a Mimbo 2.2 theme, how do I reorder the items in the sidebar? In this situation, I want to make the Twitter and Tags Widgets that I recently added to an old client's site drop down the column. See www.madhairstyling.ch. The more familiar approach of dragging and dropping the widgets in the admin panel does not work because most of the "widgets" are not "active" in "sidebar1". I do not really understand php.

The code currently in the sidebar.php file is:



<div id="sidebar">
<ul id="sidelist">
<?php /* Widgetized sidebar, if you have the plugin installed. */
if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar() ) : ?>
<?php endif; ?>


<?php

// this is where 10 headlines from the current category get printed
if ( is_single() ) :
global $post;
$categories = get_the_category();
foreach ($categories as $category) :
?>
<li><h2>More from this category</h2>
<ul class="bullets">
<?php
$posts = get_posts('numberposts=10&category='. $category->term_id);
foreach($posts as $post) :
?>
<li><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></li>

<?php endforeach; ?>

<li><strong><a href="<?php echo get_category_link($category->term_id);?>" title="View all posts filed under <?php echo $category->name; ?>">Archive for '<?php echo $category->name; ?>' &raquo;</a></strong></li>
</ul>
</li>
<?php endforeach; endif ; ?>



<?php if ( is_home() ) { ?>
<li><h3><?php
// this is where the name of the News (or whatever) category gets printed
wp_list_categories('include=8&title_li=&style=none'); ?></h3>
<?php
// this is where the last three headlines are pulled from the News (or whatever) category
query_posts('showposts=3&cat=8');
?>
<ul class="bullets">
<?php while (have_posts()) : the_post(); ?>
<li><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></li>
<?php endwhile; ?>
</ul>
</li>
<?php } ?>


<li><h3>Archiv</h3>
<form id="archiveform" action="">
<select name="archive_chrono" onchange="window.location =
(document.forms.archiveform.archive_chrono[document.forms.archiveform.archive_chrono.selectedIndex].value);">
<?php get_archives('monthly','','option'); ?>
</select>
</form>
</li>


<li><h3>Kategorien</h3>
<ul class="subnav">
<?php wp_list_categories('title_li='); ?>
</ul>
</li>

<li><h3>Newsletter</h3>

<script language="JavaScript">
var success = 'Vielen Dank f&uuml;r die Abonnierung unseres Newsletters.';
var failed = 'Bitte geben Sie eine g&uuml;ltige Emailadresse ein.';
function alertSubscribed() { doc = document.forms['em_newsletter']; if (doc.email.value.replace(/\s/,"").length == 0) { alert(failed); return false; } else { alert(success); return true; } }
</script>

<form method="post" action="http://www.eyemanage.ch/subscribe.php" onSubmit="return alertSubscribed();" style="margin: 0px; padding: 0px;" name="em_newsletter"> <input type="hidden" name="guid" value="F134A43BCA58D990C4E50240DF2B67423D713E568ABF95F240DF2B67EE704473568ABFBB105839B5B235B09466D57BCAEE701908817288">

<table cellspacing="0" cellpadding="0">
<tr>
<td>Vorname</td><td>&nbsp;&nbsp;&nbsp;</td><td><input type="text" name="firstname" size="10"></td>
</tr>
<tr>
<td>Nachname</td><td>&nbsp;&nbsp;&nbsp;</td><td><input type="text" name="lastname" size="10"></td>
</tr>
<tr>
<td>E-Mail</td><td>&nbsp;&nbsp;&nbsp;</td><td><input type="text" name="email" size="10"></td><td>&nbsp;&nbsp;&nbsp;</td><td><input type="submit" name="submit" value="Submit" class="button"></td>
</tr>
</table>

</form>


</li>


<li><h3>Werbung</h3>
<ul class="subnav">

<center>
<!--/* OpenX Javascript Tag v2.8.1 */-->

<script type='text/javascript'><!--//<![CDATA[
var m3_u = (location.protocol=='https:'?'https://ad2.medialution.com/www/delivery/ajs.php':'http://ad2.medialution.com/www/delivery/ajs.php');
var m3_r = Math.floor(Math.random()*99999999999);
if (!document.MAX_used) document.MAX_used = ',';
document.write ("<scr"+"ipt type='text/javascript' src='"+m3_u);
document.write ("?zoneid=23");
document.write ('&amp;cb=' + m3_r);
if (document.MAX_used != ',') document.write ("&amp;exclude=" + document.MAX_used);
document.write (document.charset ? '&amp;charset='+document.charset : (document.characterSet ? '&amp;charset='+document.characterSet : ''));
document.write ("&amp;loc=" + escape(window.location));
if (document.referrer) document.write ("&amp;referer=" + escape(document.referrer));
if (document.context) document.write ("&context=" + escape(document.context));
if (document.mmm_fo) document.write ("&amp;mmm_fo=1");
document.write ("'><\/scr"+"ipt>");
//]]>--></script><noscript><a href='http://ad2.medialution.com/www/delivery/ck.php?n=a4be8013&amp;cb=INSERT_RANDOM_NUMBER_HERE' target='_blank'><img src='http://ad2.medialution.com/www/delivery/avw.php?zoneid=23&amp;cb=INSERT_RANDOM_NUMBER_HERE&amp;n=a4be8013' border='0' alt='' /></a></noscript>
</center>


</ul>
</li>

<? /*

<li><h3>Webmaster</h3>

<ul class="bullets">
<?php wp_list_authors
('exclude_admin=0&show_fullname=1&hide_empty=1&feed_image=' .
get_bloginfo('template_url') . '/images/rss.gif&feed=XML'); ?>
</ul>
</li>
*/ ?>

</ul><!--END SIDELIST-->
</div><!--END SIDEBAR-->



There is something in functions.php that looks like it is relevant:


<?php
if ( function_exists('register_sidebar') )
register_sidebar(array(
'before_widget' => '<li id="%1$s" class="widget %2$s">',
'after_widget' => '</li>',
'before_title' => '<h2 class="widgettitle">',
'after_title' => '</h2>',
));

?>

Answers (2)

2010-03-16

Erez S answers:

shopdev.co.uk/blog/sortable-widgets-wordpress-plugin/
wordpress.org/support/topic/263036
try it


James Maiden comments:

Thanks for the speedy reply. That plugin is quite cool - i tried it on the problem site and another wp blog that i have - but sadly, it does not address my problem. I think the issue is that things in the sidebar are not widgetized (apart from the recent two at the top that i added myself). So the plugin doesn't appear to work on those things - only the widgetized ones. I suspect it is something to do with the mimbo theme.


Erez S comments:

delete all from <li><h3>Archiv</h3> to <? /* without the <? /* but save backup first and then add the widgets from the admin control panel

2010-03-16

Edouard Duplessis answers:

if you just want to have your twitter and the cloud tag below, just take the:

<?php /* Widgetized sidebar, if you have the plugin installed. */
if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar() ) : ?>
<?php endif; ?>

and put it above the :

</ul><!--END SIDELIST-->
</div><!--END SIDEBAR-->