I wrote a abbrevation in html something like this,
<abbr title="How are you">HAY</abbr>
This piece of code show the abbrevation just for 4 or 5 seconds.
Is is posible to customize this time ??
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
No, this is handled entirely by the browser, and is inaccessible to the user or web-developer to change, read or edit the time of visibility.
You could, with JavaScript create an element that will contain the text of the
titleattribute the visibility of which would be explicitly under your control.Edited because it occurred to me that I should try and offer an example of alternatives (rather than just saying ‘they exist’), so, a CSS example (I’m using CSS generated content in this implentation, which unfortunately doesn’t allow for CSS transitions, so it just appears, and remains in place until you mouse-out from the
abbrelement):HTML:
CSS:
JS Fiddle demo.
This does require the user to have a browser that supports CSS generated content, since if there was a
titleattribute you’d have both the CSS pop-up and the default title showing up which is neither terribly useful or particularly pretty.An alternative is using nested elements and CSS transitions, which gracefully degrades in those browsers that don’t support transitions (the content simply ‘appears’, but at least it’s available):
HTML:
CSS:
JS Fiddle demo.
And a JavaScript approach (which is kind of ugly, frankly):
JS Fiddle demo.