Is it possible to run javascript to run when a specific anchor is selected?
Say I have an anchor in a web page:
<a name="comegetit"></a>
Is there a way to run javascript if the page is received by a link that falls into this anchor? (for example, such a link as <a href="http://myawesomewebpage.com/page#comegetit"></a>). I do not think there is, but I would like it to be.
I am using Really Simple History ( http://code.google.com/p/reallysimplehistory/ )
- :
window.dhtmlHistory.create();
window.dhtmlHistory.initialize();
window.dhtmlHistory.addListener(function(hash){
// this is where you process your hash and do something special
// and totally funky
});
, - -.
B.S. window.location.hash