WordPress.org

Ready to get started?Download WordPress

Forums

Help!! Option for sidebar2 missing in editor (11 posts)

  1. TheOrganicSister
    Member
    Posted 5 years ago #

    I just uploaded a new theme (dandelion style). When I go to edit my widgets (appearance>widgets) it is only giving me the option of sidebar1. No sidebar2 in the pulldown at all.

    If you look at my site (http://theorganicsister.com) you can see the outer sidebar which has everything the widget editor says Sidebar1 has. The inner sidebar shows a repeat of some of the wigets in the outer sidebar (categories but not alphabetized, archives) as well as "menu". I can't delete these or edit them.

    Have no idea what to do!!!

    Tara
    http://theorganicsister.com

  2. buddha trance
    Member
    Posted 5 years ago #

    I could tell you what you can try to fix it, but I'd rather tell you to stay away from this theme, as it contains obfuscated code in functions.php and footer.php, and I stopped checking for more.
    I just downloaded this theme to see the sidebar code...

    To know what obfuscated code is, read this thread
    http://wordpress.org/support/topic/235659?replies=5

    Advice - stay away from this theme!

  3. TheOrganicSister
    Member
    Posted 5 years ago #

    Um. Wow. Okay.

    Can I fix it so I can use it while I look for another suitable theme? Or it is so unsafe that I should delete it right away?

  4. buddha trance
    Member
    Posted 5 years ago #

    It's never good to have hidden code. I would personally delete it.

  5. TheOrganicSister
    Member
    Posted 5 years ago #

    Okay I deleted it and found an almost identical one from WordPress.org (called page-style). This one is doing the same thing. I would imagine because it's from WordPress that there shouldn't be hidden code; am I right? But are the widgets fixable?

  6. buddha trance
    Member
    Posted 5 years ago #

    Yes, this one is fine, identical to the other one, and has no hidden code.

    I checked your site, and the sidebars seem fine, with no duplicated content. Are you still having the same problem?

    If so, try this:

    In sidebar.php, add the registration code for sidebar-left, and call it "sidebar one"

    <div id="sidebar-left">
    	<?php 	/* Widgetized sidebar, if you have the plugin installed. */
    					if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar("Sidebar One") ) : ?>

    Then, add the name "sidebar two", to the right sidebar

    <div id="sidebar-right">
    			<div id="subfeed" >
    				<a href="<?php bloginfo('rss2_url'); ?>"><img height="50" border="0" width="215" alt="Sub via feed" title="Sub via feed" src="<?php bloginfo('template_url'); ?>/img/feed.gif"/></a>
    			</div>
    				<?php 	/* Widgetized sidebar, if you have the plugin installed. */
    					if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar("Sidebar Two") ) : ?>

    In functions.php, call both sidebars in separate arrays

    <?php
    if ( function_exists('register_sidebar') )
        register_sidebar( array(
        'name' => 'Sidebar One',
            'before_widget' => '<div class="s-menu sidebar-box">',
            'after_widget' => '<div class="s-menub"></div></div>',
            'before_title' => '<h2>',
            'after_title' => '</h2>',
        ));
    
         register_sidebar( array(
        'name' => 'Sidebar Two',
            'before_widget' => '<div class="s-right sidebar-box">',
            'after_widget' => '<div class="s-rightb"></div></div>',
            'before_title' => '<h2>',
            'after_title' => '</h2>',
        ));
    
    }
    ?>

    See if this works for you.

  7. TheOrganicSister
    Member
    Posted 5 years ago #

    Questions: Where in sidebar.php am I adding the first and second and am I deleting anything else, like al the code for menu, categories etc?

    And in functions do I delete what is there, replacing it completely or simply add this to what is there?

    Thank you for your help. I'm loking forward to making this work. :)

  8. TheOrganicSister
    Member
    Posted 5 years ago #

    Okay I tried only adding the first bits without taking anything out. And I completely replaced the functions with what is there. Still not working. :(

  9. TheOrganicSister
    Member
    Posted 5 years ago #

    I've tried rewriting and overwriting 4 times now. But when I go to Appearance>Editor, it shows NO changes! WTH???

  10. buddha trance
    Member
    Posted 5 years ago #

    In functions.php, you rewrite over and replace

    In sidebar.php you add the code as follows:

    Fist bit you just write over <div id="sidebar-left"> so you add the php code to register the sidebar.

    Second bit you just have to add the sidebar name in the php code that is there, or write the bit over starting from <div id="sidebar-right">. This second bit only adds "Sidebar Two" to the php code registering the sidebar.

  11. arcsis
    Member
    Posted 5 years ago #

    I just realized the same issues when I started using this theme, thanks for asking & answering. :)

Topic Closed

This topic has been closed to new replies.

About this Topic