1

You know when you hover a < a> element and the link appears in the bottom left corner of the browser? Is it possible to do it with another tag?

Lucas Steffen
  • 1,092
  • 1
  • 9
  • 20

2 Answers2

3

No. Setting the status bar manually has been disabled in modern browsers for security reasons. A malicious site developer could make the status bar display a different URL than the one they would be taken to on a link.

The Javascript property used to work like this:

window.status = "Status bar text";

This no longer does anything at all by default on any current browser.

omnichad
  • 1,555
  • 10
  • 10
3

No, but you can put an <a> element over/around another element and 'disable' the link (onclick) using javascript to achieve a similar result:

<a href="//Message in the status bar!" onclick="return false">
    <div>
         This div shows something in the status bar 
         but is actually surrounded by a disabled link
    </div>
</a>
sjkm
  • 3,776
  • 2
  • 24
  • 43
  • Good answer, but the status bar will look something like this: "http://message%20in%20the%20status%20bar%21" (See https://jsfiddle.net/6gexggqa/1) To make it more meaningful, you could use `href="about:Message...`. (See https://jsfiddle.net/6gexggqa/) – Rick Hitchcock Mar 30 '16 at 18:23
  • @RickHitchcock Thank you :)! That's a good idea! – sjkm Mar 30 '16 at 20:45
  • Problem is that it has some incomprehensible css that nobody wants to mess with, and putting anything else will break the responsiveness. – Lucas Steffen Mar 30 '16 at 20:58