vForums Support > Programming & Coding :: Code Requests & Support :: > Category Text CSS

Category Text CSS - Posted By ashkir (ashkir) on 21st Oct 08 at 4:49pm
I cannot figure out how to change the color of the category titles, size and font with CSS:

.categorytitle {
text-align: center;
color: #94720A;
nav-color: #94720A;
font-size: 20px;
font-family: Georgia;
}

Re: Category Text CSS - Posted By Nick (nickb) on 21st Oct 08 at 5:16pm
I know how to align it, but not color it. I could try to, Because I know it is more then what you have (I believe) If I can't do it, then Dwight can step in.

Re: Category Text CSS - Posted By ashkir (ashkir) on 21st Oct 08 at 5:17pm
The align part works well. ^^

.categorytitle {
text-align: center;
}

Re: Category Text CSS - Posted By Nick (nickb) on 21st Oct 08 at 5:29pm
edit:
I guess it does not work for the main boards title, but it does work like when you modify a header/footer or anything else in the admin panel. I will have to work more on this. Its close at least {Smile}
Well I got it fixed {Smile} I know whats wrong

You have to have this:
Code:
 
  1. <script type="text/javascript">
  2. <!--
  3. /*Remove Link From Category Name by Danny*/
  4.  
  5. var cat = document.getElementsByTagName('tr');
  6. for(e=0; e<cat.length; e++){
  7. if(cat[e].firstChild.className=='title2 categorytitle' && cat[e].firstChild.colSpan=='3'){
  8. cat[e].getElementsByTagName("a")[1].removeAttribute("href");
  9. cat[e].getElementsByTagName("font")[0].removeAttribute("size");
  10. }
  11. }
  12.  
  13. // -->
  14. </script>
  15.  
 

This removes the link from the category title, which makes the CSS work.

Code:
 
  1. <style type="text/css">
  2. .categorytitle {
  3. text-align: center;
  4. color: #94720A;
  5. nav-color: #94720A;
  6. font-size: 20px;
  7. font-family: Georgia;
  8. }
  9. </style>
  10.  
 


If you want to see for your self go here:
http://dmtesting.vforums.co.uk and you will see

Re: Category Text CSS - Posted By ashkir (ashkir) on 21st Oct 08 at 5:44pm
Nope. Didn't work from my end. =/

Re: Category Text CSS - Posted By Nick (nickb) on 21st Oct 08 at 5:46pm
How about now? I increased it by 90 {Tongue Out} its really big now.

Oh and I only tested this in FireFox, Maybe I first should of tested everywhere else too. So I am on it.


Re: Category Text CSS - Posted By ashkir (ashkir) on 21st Oct 08 at 5:48pm
Works on your board but mine not, but I use the skin feature. Is it in your all skins? And what location?

Re: Category Text CSS - Posted By Nick (nickb) on 21st Oct 08 at 5:51pm
Well I tested it in Internet Explore. Safari, Opera, and Google Chrome, all look fine to me. If you are talking about your forum I forgot to mention put the other code in your Global header. Then put the CSS where ever you like it.

Re: Category Text CSS - Posted By ashkir (ashkir) on 21st Oct 08 at 6:00pm
I put it in the global footer and it worked. Thanks!

Re: Category Text CSS - Posted By Nick (nickb) on 21st Oct 08 at 6:07pm
Your welcome. {Smile} Glad to help.

Re: Category Text CSS - Posted By ashkir (ashkir) on 21st Oct 08 at 6:08pm
'nother problem arose the font tag isn't working. :[. It works when I use '.general.' in category name but I don't have the space to do all of them with the font tag to get that font.

Re: Category Text CSS - Posted By Nick (nickb) on 21st Oct 08 at 6:10pm
Ok I will see what I can do.

edit:

Sorry I was not able to. Maybe Ross or Dwight can do it. Whomever gets on first.

edit 2:
I can change the Title1 and 2 font family, but I cannot seem to get the category text to work.