How to use #/fragment identifier with file:// URI/URL protocol

290 views Asked by At

I'm trying to open local html files at specific anchors by using the #fragment identifiers, this unfortunately seems to be stripped by the file handler. For example running

cmd.exe /c rundll32  url.dll,FileProtocolHandler "file://C:\test.html#anchor1"

system calls from my Windows application seems to strip everything from the # mark (pasting directly in the browser works though). Escaping the hash with "%23" does not work either as then nothing is opened (the file seems to not have been found).

Is there a way to open a local file at an anchor from a system call? Alternativley, is there some other way to open a local html file at an anchor?

0

There are 0 answers