WordPress.org

Ready to get started?Download WordPress

Forums

Custom Sidebars
[resolved] Sidebar CSS Formatting (7 posts)

  1. Krissy
    Member
    Posted 1 year ago #

    Running the most recent versions of this script and WP is causing a weird error that I'm unsure how to fix.

    The formatting (preset in functions.php) for the sidebar are not carrying over to the Custom Sidebars, it also removed the formatting for the default sidebar preset in WordPress.

    I do remember utilizing this script on another site where there were no issues for the formatting to carry over - and even copying the information directly (only having this function listed in the functions.php file to ensure nothing else was interfering) it's still showing the lack of formatting.

    Is this a common occurrence?

    if ( function_exists('register_sidebar') )
    	register_sidebar(array(
    		'before_widget' => '<div class=widget_text>',
    		'after_widget' => '</div>',
    		'before_title' => '<span class=widget_title>',
    		'after_title' => '</span>',
    	));

    http://wordpress.org/extend/plugins/custom-sidebars/

  2. therandomguy12345
    Member
    Posted 1 year ago #

    I have a remotely similar question and I actually might be able to answer you question with an answer to mine.

    I'm using a buddypress theme and no sidebar (widget area) had been allocated for the Registration page by the theme author.

    Will this plugin allow me to actually create a sidebar area and add widgets there? Say that my theme doesn't even have a sidebar on that page to start off with... or, will I have to edit the code for that page to create a sidebar and then, use this plugin to add widgets there?

    Please respond as soon as possible.

  3. designpromote
    Member
    Posted 1 year ago #

    Suppose you are using 2012 template. I use the code below:

    register_sidebar( array(
    'name' => __( 'Third Front Page Widget Area', 'restaurant' ),
    'id' => 'sidebar-4',
    'description' => __( 'Appears when using the optional Front Page template with a page set as Static Front Page', 'restaurant' ),
    'before_widget' => '<aside id="%1$s" class="widget %2$s">',
    'after_widget' => '</aside>',
    'before_title' => '<h3 class="widget-title">',
    'after_title' => '</h3>',
    ) );

    If your questions are about CSS, please use firebug in Firefox. For example (#myid #mywidget #mytext) have more weight than (#mywidget #mytext) or (#myid #mytext), CSS structure are different between 2012 and 2011.

  4. therandomguy12345
    Member
    Posted 1 year ago #

    Wait... so for buddypress, how would I be able to get a sidebar onto the registration page? Would I have to edit my theme's register.php, or would this plugin allow me to add a sidebar to that page?

  5. Hi All,

    @Krissy, are you still having issues with this?

    @therandomguy12345 You'd have to edit your themes register.php and use code similar to that, that @designpromote posted.

    Thanks!

    Kind Regards
    Jack.

  6. Krissy
    Member
    Posted 10 months ago #

    No, I figured it out the following day...

  7. Mike
    WPMU DEV Support Staff
    Posted 9 months ago #

    That's great, thanks for letting us know and for marking this as resolved!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic