Today's Posts Follow Us On Twitter! TFL Members on Twitter  
Forum search: Advanced Search  
Navigation
Marketplace
  Members Login:
Lost password?
  Forum Statistics:
Forum Members: 24,254
Total Threads: 80,792
Total Posts: 566,472
There are 1387 users currently browsing (tf).
 
  Our Partners:
 
  TalkFreelance     Design and Development     Programming     PHP and MySQL :

[WordPress] Assigning categories an image

Thread title: [WordPress] Assigning categories an image
Closed Thread    
    Thread tools Search this thread Display Modes  
07-04-2007, 05:37 PM
#1
Steven Fergus is offline Steven Fergus
Status: Hey, I'm Steven
Join date: Feb 2007
Location:
Expertise:
Software:
 
Posts: 1,212
iTrader: 3 / 100%
 

Steven Fergus is on a distinguished road

  Old  [WordPress] Assigning categories an image

Hi there,

I'm just wondering if it's possible to assign each category a image. For example:



The example above lists every category and highlights the category(s) that it's posted in, changing the image and text colour. Is this possible? I have a feeling it is, I'm just not too sure how to do it.

Thanks,
Steven

07-05-2007, 08:52 AM
#2
Immersion is offline Immersion
Status: Senior Member
Join date: Dec 2005
Location:
Expertise:
Software:
 
Posts: 918
iTrader: 5 / 100%
 

Immersion is on a distinguished road

  Old

Well you could have the class name the same as the category name and add the image through css. Other that that there maybe some plugin somewhere. Yet i think the css idea sounds reasonable.

07-08-2007, 09:26 PM
#3
Garrett is offline Garrett
Status: Waving
Join date: Aug 2005
Location:
Expertise:
Software:
 
Posts: 2,694
iTrader: 11 / 100%
 

Garrett is on a distinguished road

Send a message via MSN to Garrett

  Old

Originally Posted by Immersion View Post
Well you could have the class name the same as the category name and add the image through css. Other that that there maybe some plugin somewhere. Yet i think the css idea sounds reasonable.
www.wbmac.com

I made it, I believe:
Code:
<?php if(in_category('6')){ ?>
	<li class="exclusive">WB Mac Exclusive</li>
<?php } ?>
<?php if(in_category('3')){ ?>
	<li class="gold">Cheap</li>
<?php } ?>
<?php if(in_category('5')){ ?>
	<li class="diamond">Well designed</li>
<?php } ?>
<?php if(in_category('4')){ ?>
	<li class="award">Award winning Application</li>
<?php } ?>

Closed Thread    


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

  Posting Rules  
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump:
 
  Contains New Posts Forum Contains New Posts   Contains No New Posts Forum Contains No New Posts   A Closed Forum Forum is Closed