Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Sidebars & Widgets (http://forum.bytesforall.com/forumdisplay.php?f=14)
-   -   Title Links and Padding issues in widgets (http://forum.bytesforall.com/showthread.php?t=5157)

dnavarrojr Jan 5, 2010 10:42 AM

Title Links and Padding issues in widgets
 
http://www.digibard.org/index.php/about/

I have two problems. First is that I can't seem to address the padding inside of widget content boxes. I have tried adding:

"padding: 5px 5px;"

inside of "ATA->Style Widgets->Widget Content Box" and it doesn't do anything.

I have been trying like heck to get the ID of the content area for all widgets, but I can't figure it out.

My other problem is that I can't get links inside of widget titles (like the twitter widget on the above page) to be a different color without effecting the links in the content area as well. I can't find a unique ID for the widget title. I can for individual widgets like the twitter widget, but I can't find a more generic ID to effect the title in all widgets.

I have a Firefox plugin that lets me select items to get their IDs, but widgets are so weird that I can't find what I'm looking for.

dnavarrojr Jan 5, 2010 10:47 AM

Unless there is no such thing as generic IDs to control padding, etc... for all widgets and they have to all be done individually...

juggledad Jan 5, 2010 03:06 PM

If you read the description for 'Widget Content Box' you see
Quote:

Widget Content Box
The Widget Content Box is gone since Atahualpa 3.4. for better plugin compatibility. It was a propretiary Atahualpa feature that provided extra styling possibilites but didn't play well with all plugins because some of them rely heavily on widgets having the same structure as in the "Default" theme (which does not have this extra DIV inside each widget). Instead of "div.widget-container" the styles that you put here will be applied on "div.widget ul, div.textwidget". That will cover all text widgets and all widgets that consists of unordered lists, which should be the majority of all widgets. Otherwise look into the source code of a browser rendered page of your site to see which DIV or other HTML element wraps around the body content of the widget that was not covered by this, and add a CSS Insert such as: div.some-class { margin: 10px }.
Atahualpa doesn't generate the code for a widget, the plugins do, but they are not all consistant. So you have to look at the generated source of your page. This is what yours looks like with some editing to make it manageable
HTML Code:

<!-- Right Sidebar -->
<td id="right">

<div id="text-3" class="widget widget_text">
        <div class="widget-title">
                <h3>My Stock Footage &amp; Photos</h3>
        </div>                       
        <div class="textwidget">
                ...snip - a bunch of links - snip...       
        </div>               
</div>


<div id="text-4" class="widget widget_text">
        <div class="widget-title">
                <h3>Find me on the Web</h3>
        </div>                       
        <div class="textwidget">
                ...snip - a bunch of links - snip...       
        </div>
</div>


<div id="twitter-3" class="widget widget_twitter">
        <div>
                <div class="widget-title">
                        <h3><a class="twitterwidget twitterwidget-title" title="Twitter: dnavarrojr" href="http://twitter.com/dnavarrojr" target="_blank">Follow Dave on Twitter</a></h3>
                </div>
                <ul>
                        ...snip - a big list - snip...       
                </ul>
        </div>
</div>


<div id="rss-3" class="widget widget_rss">

        <div class="widget-title">
                <h3><a class='rsswidget' href='http://www.pond5.com//rss_new_clips.php?artist=dnavarrojr' title='Syndicate this content'>Latest Pond5 Clips</a></h3>
        </div>
        <ul>
                ...snip - a big list - snip...       
        </ul>
</div>

</td>
<!-- / Right Sidebar -->

The padding for the text widgets is easy, but look at the last widget, the one with id="rss-3". It has a div for the title but then it's just an unordered list. The structure is different from the other widgets. so you would have to use something like '.widget_rss ul li {padding.....} because of it's structure.

Wouldn't if be nice if there was a standard...alas...

Notice also that hte twitter widget has a different layout than eithor the text of the rss widget so the CSS selector would have to be different here also (.widget_twitter div ul li {padding.....})

Hope this helps explain why there is no universal fix.

dnavarrojr Jan 5, 2010 05:05 PM

Yeah, I was afraid of that... But I can easily get the ID's for the individual widgets, so I'll just have to fix them all individually.


All times are GMT -6. The time now is 04:06 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.