I have a menu (with ul and li) who call #anchors, thy are located just at the right of the menu, so I don’t want to have a jump in the page for nothing (informations are already on the screen). I tried onclick event, it don’t work (I have loaded Jquery on my page, so I don’t know why it doesn’t work. I have read dozen of pages for my question in this site but nothing helped me.
If anybody have an answer to avoid the jump of the anchors, it would be nice.
This will capture the click event and prevent the default action which is jumping and navigating.
The selector is for elements that have links that start with “#” such as the anchors.