Request for browser feature: in-page search in url

5 points by antidoh ↗ HN
While reading an article that had a long introduction before the subject finally appeared, I searched the source for an internal anchor link, so that I could link to the meat instead of the top. Unfortunately there was no anchor to link to.

It would be cool if you could append a search specification to the end of a url, and the browser would then search the loaded page and jump to the first occurrence of that term. Or jump to the Nth occurrence, according to the search spec.

Ideally an RFC or W3C standard, for cross-browser implementation consistency, but the browser cabal could decide to implement it informally in common.

Example, where I use #/# as a possible search beginning:

  http://blog.n01se.net/blog-n01se-net-p-375.html#/#1. Faster Javascript Engines

5 comments

[ 5.1 ms ] story [ 28.0 ms ] thread
Already standardized: XPointer.
That seems to depend on the presence of ids. Can my example page (with correct uri and fragment syntax) work in this scheme? There is no id associated with the part that I tried to link to.
XPointer allows arbitrary XPath selectors; in fact, the very first example in the specification is exactly a substring match. I am thereby somewhat confused as to where you got the identifier requirement.

xpointer(string-range(//P,"a little hat ^"))

I want to be able to make a link, usable in the browser address field as a link or clickable from a mail message, so I was looking at URI fragments after looking at XPointer. I don't think you can make much more that a #id based link at the moment. A browser could implement your example, but I don't think they do at the moment.
I did not claim that XPointer was implemented: I claimed that it was standardized. You asked for this functionality, and said that ideally it would be a W3C standard; I am telling you that the standard already exists: it is called XPointer, and it has exactly the functionality you want.