WordPress.org

Ready to get started?Download WordPress

Forums

edit individual widget width and class (21 posts)

  1. Joshua Knowles
    Member
    Posted 6 years ago #

    I cannot figure out how to center align my tag cloud and edit the width for the tag cloud widget. I don't want to center the title, just the actual tags. You can easily see my problem here: http://blog.halloweencanteen.com

  2. Joshua Knowles
    Member
    Posted 6 years ago #

    *~.~*~.~*BuMpEd*~.~*~.~*

  3. Joshua Knowles
    Member
    Posted 6 years ago #

  4. CyberCobre
    Member
    Posted 6 years ago #

    No. You have to hand-edit the widgets.php file found in your wp-admin folder. WARNING: This is NOT an easy thing to do. Make back-ups before trying anything.

  5. Joshua Knowles
    Member
    Posted 6 years ago #

    Is this the file?: wp-includes/widgets.php
    If so, I tinkered around with it and could not figure anything out. I know html but php is beyond me. Help please?!

  6. Joshua Knowles
    Member
    Posted 6 years ago #

    If I can help at all, here is the widgets.php file (from wp-includes/widgets.php):

    http://blog.halloweencanteen.com/widgetsphp.zip

    Can you include the needed fixes in a reply in case someone else is trying to accomplish this same task? I'm sure there are many people having this problem, but I can't find a solution anywhere on the net. Plug-in?

    Thanks in advance!

  7. Samuel Wood (Otto)
    Tech Ninja
    Posted 6 years ago #

    No, you don't need to manually edit the file. You change your CSS instead, like you should for all stylistic changes.

    Just add this to your theme's style CSS file:

    .widget_tag_cloud {
    text-align: center;
    }
    .widget_tag_cloud h2 {
    text-align: left;
    }
  8. Joshua Knowles
    Member
    Posted 6 years ago #

    Thank you Otto42 That worked. Now how do I set the width so the longer tags are not leaking over the background column?

  9. Joshua Knowles
    Member
    Posted 6 years ago #

    New really nice plugin: http://reciprocity.be/ctc/
    I'm using it on my site mentioned about.

    I still need to know how to set the width for the
    tag cloud
    . See my site where my tags are too long.

  10. kmessinger
    Volunteer Moderator
    Posted 6 years ago #

    I control the width and placement in the style.css file like this

    #sidebar
    {
    	padding: 20px 0 10px;
    	margin-left: 550px;
    	width: 190px;
    	}
  11. Leejj
    Member
    Posted 6 years ago #

    I need to do something like that in my text boxes. They all hang over the left of the box. I have a widget I added to a text box and I can't get it to center. I was hoping it would draw me more traffic but I might just have to remove it.

    I looked through the CSS but could not find it.

  12. Samuel Wood (Otto)
    Tech Ninja
    Posted 6 years ago #

    Leejj: You'll need to post a link to the site so we can see just what you're talking about. We can't tell you what to do without seeing it.

  13. Leejj
    Member
    Posted 6 years ago #

    Sorry...I thought my name became a link to it. http://footballjabber.com

  14. designakaart
    Member
    Posted 6 years ago #

    Hi,

    I am having this problem as well. The site is mormonpodcasting.com. Basically, I would like to make the XSPF Player wider, and make the tag cloud which is bleeding over the column width fit correctly. I tried messing with the CSS style sheet for the theme:

    widget_tag_cloud {
    text-align: center;
    width: 220;
    }
    .widget_tag_cloud h2 {
    text-align: left;
    }

    But it made no difference at all.
    I've been looking for this solution all over the web, and I know it may be seen as bad to ask, but I am really stuck on this.

    thanks,

    Jason

  15. Craw4x4PH
    Member
    Posted 6 years ago #

    Hi all,

    My problem is with regards to the widget headers. I want to create graphic headers for each widget, instead of using the default text/h3 headers, but I can't seem to figure out how to do it.

    Here's a sample site where I've seen it: http://www.shopcrazy.com.ph

    And here's mine (because I don't know if it's because of the theme or what): http://www.4x4ph.com/outoftown

  16. madzzoni
    Member
    Posted 6 years ago #

    Hi All

    I'm using the wp_tag_cloud in my WP 2.3.3 @ http://www.xconsult.dk (-and others)

    I want it to show up like a cloud and not a list in my sidebar.

    I tried to control this widget in my stylesheet (without succes!) this way:

    li#tag_cloud { list-style: none; display: inline; }

    .widget_tag_cloud {
    display: inline;
    color: #69aee7;
    text-decoration: none;
    }

    It still shows up like a list, can't get this to work, what's wrong here?

    How can i make this widget "breake out" from the overall sidebar-css, and show up like a inline cloud instead?

    Could someone please paste a some valid css-tags to control this widget?

    //madzzoni

  17. Wendy
    Member
    Posted 6 years ago #

    Oh my god, I've tried everything to get my tag cloud to stay within the padding I'd like in all my widget boxes. No problems for any others so far: just this one!

    So far, the only thing that's worked is to add padding to the link style, which then throws its usage elsewhere out. I've tried the stuff suggested above, but the widget doesn't want to look at any new CSS I introduce (my fault, no doubt).

    I've tried all sorts of things suggested on the forums, and before anyone suggests CTC, yes, I've tried that too but it uses the same base code to collect the tags so the padding problem is the same.

    My site is here:
    http://www.lefrancophoney.com

    Can anyone help?!?

  18. Wendy
    Member
    Posted 6 years ago #

    ...so...that's a no then?

  19. Wendy
    Member
    Posted 6 years ago #

    Well, in case anyone is wondering, I fixed it by doing two steps:

    1. I added a new style to my css called "widgetbody" that set the left and right padding only.

    2. In my 'functions.php' file, I added <div class="widgetbody"> to the end of the 'before widget' code, and a closing </div> to the start of the 'after widget' code.

    On the off-chance it helps someone else as frustrated as I've been getting with the lack of help for so many questions asked on this forum, it looks like this:

    <?php
    if ( function_exists('register_sidebar') )
    {
    	ob_start();
    	bloginfo('template_directory');
    	$a = ob_get_clean();
    
    	register_sidebar(array(
            'before_widget' => '<!-- //start sideitem //--><div class="sideitem"><div class="sideitemtop"><img src="'.$a.'/img/stl.gif" alt="" width="15" height="15" class="corner" style="display: none" /></div><strong><div class="widgetbody"></strong>',
            'after_widget' => '<strong></div></strong><div class="sideitembottom"><img src="'.$a.'/img/sbl.gif" alt="" width="15" height="15" class="corner" style="display: none" /></div></div><!-- //end sideitem //-->',
            'before_title' => '<h2>',
            'after_title' => '</h2>',
        ));
    }
    ?>
  20. Wendy
    Member
    Posted 6 years ago #

    Sorry, due to being unable to use the bold feature within code, that came out wrong. It should look like this:

    <?php
    if ( function_exists('register_sidebar') )
    {
    ob_start();
    bloginfo('template_directory');
    $a = ob_get_clean();

    register_sidebar(array(
    'before_widget' => '<!-- //start sideitem //--><div class="sideitem"><div class="sideitemtop"><img src="'.$a.'/img/stl.gif" alt="" width="15" height="15" class="corner" style="display: none" /></div><div class="widgetbody">',
    'after_widget' => '</div><div class="sideitembottom"><img src="'.$a.'/img/sbl.gif" alt="" width="15" height="15" class="corner" style="display: none" /></div></div><!-- //end sideitem //-->',
    'before_title' => '<h2>',
    'after_title' => '</h2>',
    ));
    }
    ?>

  21. iuchewie
    Member
    Posted 6 years ago #

    looking for some help here...

    i just installed the cloud tag widget to my sidebar: http://talkflop.com/blog/

    it appears that there needs to be a break after the title of the tag cloud before the first tag is shown. so instead of

    TalkFlop.com Tagsbad luck full house

    it should read

    TalkFlop.com Tags
    bad luck full house

    anyone know where i should be looking to modify this?

    thanks in advance.

Topic Closed

This topic has been closed to new replies.

About this Topic