Center Archive and Categories Widgets and Widget Title Font Size
-
Hello,
I’m trying to center the categories and archives drop down boxes in the sidebar, and couldn’t do so using the following for some reason:
#blog_subscription-2, #search-2, #archives-2, #categories-2 {
text-align: center;Also, how can I change the font size for the widget title text?
Thanks in advanve!
The blog I need help with is: (visible only to logged in users)
-
Hi there.
You cannot align it with text-align because your are managing a select object, not text. You could try with this piece of code, setting horizontal margins to auto :
.widget select {
margin: 0px auto;
}I hope this helps you.
-
Is this the right widget select code?
.archiveswidget {
margin: 0px auto;
}The above didn’t seem to work…
-
-
-
-
-
Honestly, @benconners: I do not know where the problem is.
Just to try one more thing, the last one: could you show us a copy of your whole custom CSS code?
-
-
-
Hi Ben,
I used the tips in our guide to How to Find Your Theme’s CSS to find the right CSS selector for those widgets.
Using that approach, I found that the dropdown in your categories widgets can be selected with .widget_categories select and the dropdown in your archives widgets can be selected with .widget_archive select. Here’s how to use those selectors in the CSS you’re looking for:
.widget_categories select, .widget_archive select { margin: 0 auto; }Please give that a try and let me know how it goes. :) You can use the same tips from that guide to find the selectors you need to change the font size for widget titles — let me know if you get stuck working on that!
-
That solved it! Thank you so much. I was also able to figure out font size. Just needed the correct CSS selector.
Thanks guys!
- The topic ‘Center Archive and Categories Widgets and Widget Title Font Size’ is closed to new replies.