using javascript to mark a link as visited

Here is how I did it. Only works in browsers that support HTML5 history api. // store the current URL current_url = window.location.href // use replaceState to push a new entry into the browser’s history history.replaceState({},””,desired_url) // use replaceState again to reset the URL history.replaceState({},””,current_url) Using replaceState means that the back button won’t be affected.

How to use a regular expression in querySelectorAll?

You can’t really use a regular expression in a selector but CSS selectors are powerful enough for your need with a “starts with” syntax inspired by regexes. You can use a substring matching attribute selectors : link[type^=service] Reads “Nodes of type link with an attribute type starting with “service” From the formal specification: [att^=val] Represents … Read more

Click an HTML link inside a WebBrowser Control

Something like this should work: HtmlElement link = webBrowser.Document.GetElementByID(“u_lp_id_58547”) link.InvokeMember(“Click”) EDIT: Since the IDs are generated randomly, another option may be to identify the links by their InnerText; along these lines. HtmlElementCollection links = webBrowser.Document.GetElementsByTagName(“A”); foreach (HtmlElement link in links) { if (link.InnerText.Equals(“My Assigned”)) link.InvokeMember(“Click”); } UPDATE: You can get the links within an IFrame … Read more

Is there any way to have WebView auto-link URLs and phone numbers in Android?

If you are loading your own (web) content from a String, then you can do something like this: final String content = “My email is: [email protected] …”; Spannable sp = new SpannableString(content); Linkify.addLinks(sp, Linkify.ALL); final String html = “<body>” + Html.toHtml(sp) + “</body>”; myWebView.loadData(html, “text/html”, “utf-8”);