Here’s what I’m trying to do. I have a hyperlink like this on my page:
<a href='http://www.wikipedia.com/wiki/Whatever_Page_Here'>Whatever Page Here</a>
When a user clicks the link I want to grab that click. If it’s a link I don’t want them to click (like something that doesn’t match the format http://www.wikipedia.com/wiki/xxxxx) I want to pop a message box. Otherwise I want to funnel them through my Mvc Controller instead. like this:
//Category is the 'Whatever_Page_Here' portion of the Url that was clicked. public ActionResult ContinuePuzzle(string category) { }
Any suggestions?
Start by intercepting all the click events:
The ‘return false;’ tells the anchor not to fire the navigate.