Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to hide href title?

Tags:

<a href="link.html" title="Titletext"> 

...is the code.

I need to use the title attribute because of slimbox, but I want to hide the title-text that shows up when hovering the mouse over the link.

Any ideas?

like image 264
Johan Avatar asked Aug 24 '09 14:08

Johan


People also ask

How do I hide a title in HTML?

The easiest way to hide the title of your page or post is to simply remove it after publishing. You could then add the title at the top of the page/posts content area and use the Heading (H1) tags.

Is it possible to hide the title from a link with css?

no, you can't hide the tooltips. that's not part of the css spec. possible duplicate of How to disable tooltip in the browser with jQuery? That's too bad.

How do I turn off title tooltip?

To remove the title tooltips globally, add the following code in the Theme Options > JS: jQuery(document). ready(function($){ $('a'). removeAttr("title"); });

What is title in href?

Defines the title of a link, which appears to the user as a tooltip. href. url. Specifies the linked document, resource, or location.


2 Answers

How about a nice simple:

<a href="link.html" title="Titletext"><span title=" ">text</span></a> 

(Better, put something actually useful in the nested title.)

like image 70
bobince Avatar answered Sep 27 '22 20:09

bobince


Supposing you are using an image tag in the a tag, you can just use an alternative title for the image (even a space) and that will overwrite the title of the link when you hover over it.

like image 43
jeroen Avatar answered Sep 27 '22 19:09

jeroen