kabuto_666 Posted October 11, 2005 Share Posted October 11, 2005 In the Category listing box, is there a way to change the subcategory text to a different color then the main category names? (and potentially a different color for each category level on the tree?) I made the following changes to categories.php: line 17: $categories_string .= '<font color="#FF9933">??<b>--</b>'; line 46: $categories_string .= '</a></font>'; That give me a "--" in orange but not the subcategory names even though a view source give me the correct line... like this: <font color="#FF9933">??<b>--</b><a href="http://www.xxxxxx.com/index.php?cPath=41_60">MJ Metals</a></font>?(5) Any ideas? Link to comment Share on other sites More sharing options...
♥Monika in Germany Posted October 11, 2005 Share Posted October 11, 2005 In the Category listing box, is there a way to change the subcategory text to a different color then the main category names? (and potentially a different color for each category level on the tree?)I made the following changes to categories.php: line 17: $categories_string .= '<font color="#FF9933">??<b>--</b>'; line 46: $categories_string .= '</a></font>'; That give me a "--" in orange but not the subcategory names even though a view source give me the correct line... like this: <font color="#FF9933">??<b>--</b><a href="http://www.xxxxxx.com/index.php?cPath=41_60">MJ Metals</a></font>?(5) Any ideas? the a href overrides your font setting I think. It takes the stysheet class for a link ... If you want to make each cat a different color, I usggest adding a field to the database and pulling it along with the cat name in the query, and using that. I've made a similar thing for a product listing display where the background is the category color ... :-) Monika addicted to writing code ... can't get enough of databases either, LOL! my toolbox: Textpad - Compare and Merge - phpMyAdmin - WS_FTP - Photoshop - How to search the forum Interactive Media Award July 2007 ~ category E-Commerce my advice on the forum is for free, PMs where you send me work are considered consultation which I charge for ... Link to comment Share on other sites More sharing options...
braylark Posted July 10, 2007 Share Posted July 10, 2007 In the Category listing box, is there a way to change the subcategory text to a different color then the main category names? (and potentially a different color for each category level on the tree?)I made the following changes to categories.php: line 17: $categories_string .= '<font color="#FF9933">��<b>--</b>'; line 46: $categories_string .= '</a></font>'; That give me a "--" in orange but not the subcategory names even though a view source give me the correct line... like this: <font color="#FF9933">��<b>--</b><a href="http://www.xxxxxx.com/index.php?cPath=41_60">MJ Metals</a></font>�(5) Any ideas? I was having the same problem for quite some time, however i did manage to find a solution. In my file this code is found on lines 59 and 60 Change this // display category name $categories_string .= '.$tree[$counter]['name']; $categories_string .= '</a>'; To This // display category name $categories_string .= '<font color="#000000">'.$tree[$counter]['name']; $categories_string .= '</a></font>'; Hope this helps Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.