/    Sign up×
Community /Pin to ProfileBookmark

different types of links?

I’m trying to get two different styles of links on a page using a stylesheet, i.e. i want a:link{}, a:visited{}, a:hover{} etc to be different for my top border and the rest of the page.

is this possible?

i tried defining the whole lot under a class using .toplink etc but it didnt seem to work.

any ideas?

thanks very much.

to post a comment
CSS

10 Comments(s)

Copy linkTweet thisAlerts:
@DaveSWFeb 25.2004 — try

.toplink a {

}

a {

}


<div class="toplink">

<a href="#">hello</a>

</div>

<a href="#">hello</a>
Copy linkTweet thisAlerts:
@BigjohnFeb 25.2004 — I've seen it done this way (and so I copied it!):

[CODE]
a.text{font-variant:normal;border:0px none;}
a.text:link, a.text:visited{text-decoration:underline;
color:#660033;background:#ede7c0;}
[/code]


John
Copy linkTweet thisAlerts:
@elbandito999authorFeb 25.2004 — hi - thanks for your help - but dave's way doesn't seem to work - or at least .toplink just covers the first a{} and not any of the others.

and i don't quite understand bigjohn's idea - i guess the code given is the one for the stylesheet - so what do u put in the html?
Copy linkTweet thisAlerts:
@VladdyFeb 25.2004 — Post a link to the page you are working on. We are at forums.webdevelopers.com not forums.psychicpowers.com :rolleyes:
Copy linkTweet thisAlerts:
@BigjohnFeb 25.2004 — [i]Originally posted by elbandito999 [/i]

[B]hi - thanks for your help - but dave's way doesn't seem to work - or at least .toplink just covers the first a{} and not any of the others.



and i don't quite understand bigjohn's idea - i guess the code given is the one for the stylesheet - so what do u put in the html? [/B]
[/QUOTE]


< a class="text" href='yadda.html'>Yadda</a>

John
Copy linkTweet thisAlerts:
@TimeBanditFeb 25.2004 — a:link { color: #003; text-decoration: none; }

a:visited { color: #003; text-decoration: none; }

a:hover { color: #FFA400; text-decoration: none; }

a:active { color: #003; text-decoration: none; }

.home-highlight-fill a:link,

.home-highlight-fill a:visited,

.home-highlight-fill a:active {

color: #26468E;

text-decoration: underline;

}

.home-highlight-fill a:hover {

color: #677CCB;

text-decoration: underline;

}

<a href="#">regular link</a>

<div class="home-highlight-fill"><a href="#">groovy link</a></div>
Copy linkTweet thisAlerts:
@elbandito999authorFeb 25.2004 — ok lol

http://www.mcjs.co.uk/test1/news&events.htm

i want the links on the buttons at the top (school overview etc) to be white, and underlined when the mouse hovers over them (as school overview but white not green)

However the links on the page itself (the latest newsletter etc) need to be blue, size 12, and underlined all the time.

thanks again 4 your help.
Copy linkTweet thisAlerts:
@elbandito999authorFeb 25.2004 — yay its working now

thanks very much everyone
Copy linkTweet thisAlerts:
@ray326Feb 25.2004 — Your left nav bar only seems to work in IE.
Copy linkTweet thisAlerts:
@Paul_JrFeb 25.2004 — [i]Originally posted by Vladdy [/i]

[B]Post a link to the page you are working on. We are at forums.webdevelopers.com not forums.psychicpowers.com :rolleyes: [/B][/QUOTE]

Lol. ?

Your posts always give me a warm, fuzzy feeling inside.
×

Success!

Help @elbandito999 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.14,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...