PDA

View Full Version : [CSS] different hover color for different link


Tiestoo
02-06-2008, 11:16 AM
This is probably very basic and easy stuff, but I can't get it right.

I want to change the color of the tags showing up in my image_template.html. Since the tag <TAG_IMG_LIST> will generate Tags:<br/>
<a href="index.php?x=browse&amp;tag=nikon">Nikon</a>
<a href="index.php?x=browse&amp;tag=nature">Nature</a>
my idea was to find the code that generates this, and change it to something like Tags:<br/>
<a class="tag" href="index.php?x=browse&amp;tag=nikon">Nikon</a>
<a class="tag" href="index.php?x=browse&amp;tag=nature">Nature</a>

My problem, I can't find the piece of code that generates how to display the tags. Besides, I feel like hacking PP :'(

Is there an other solution to change the color of a specified links in CSS/PP?

cfnerd
02-06-2008, 02:04 PM
Basically what i would do is wrap the tag list in a div then use css to apply the color or what ever else you want to do to the links.

This would be my suggestion.

<style type="text/css">
.taglinks a { color:black; }
.taglinks a:hover { color:#c0c0c0; }
</style>
<div class="taglinks">
<TAG_IMG_LIST>
</div>

fredxeric
02-06-2008, 02:18 PM
maybe just wrap a span & style between

html part:


Tags:<br/>
<div id="tags">
<TAG_IMG_LIST>
</div>



css part:

#tags a {
color: blue;
}

Dennis
02-06-2008, 03:44 PM
Tags are created in the paged_archive addon. And besides that, tags do have a different ID, otherwise we can't change the fontsize: class="tagsxx" where xx is between 00 and 10.

<TAG_IMG_LIST> is probably without a style so you can do what fred-eric suggest. (or ask someone we both know :p)

Tiestoo
02-08-2008, 11:37 PM
Hehe, thx, got it working. Learned some new CSS techniques.
This guy we both know is busy with a website for my brother now, so that was not an option ;)