Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can I stop a link looking like a link?

Tags:

html

css

I disabled my address link with the following:

<a href="#" onclick="return false;" rel="nofollow">Overview</a>

This came from some suggestions in my last post.

However --- When I move the cursor over the link a hand appears to show it's a link even though it does nothing. Is there a way to stop the cursor changing to a hand?

Thanks,

like image 537
RichardA Avatar asked Jan 29 '26 04:01

RichardA


2 Answers

Through CSS, a { cursor: default; color: black; text-decoration:none; }

This will remove the blue text, underline and the hand pointer that is normally default for browsers. Also, why are you using a tags, haha?

like image 88
Phil Avatar answered Jan 31 '26 19:01

Phil


If your link isn't pointing anywhere, you could just remove the href from the tag, which will result in browsers rendering the link as just normal text. (no underline, no pointer cursor)

like image 31
peirix Avatar answered Jan 31 '26 18:01

peirix