0

I did following:

1) In Windows 7: Under registry: HKEY_CLASSES_ROOT\PROTOCOLS\Handler I have my custom protocol calls: stackoverflow (copied similar way in registry like other protocols mailto or ftp etc)

Followed

2) Open in IE the sample: http://jsfiddle.net/L528u/

<a href="stackoverflow:talking" id="link1">CLICK IT</a>
<button onclick="alert(document.getElementById('link1').protocolLong);">CHECK - IF - Protocol available or not</button>

3) when click the button from IE to detect the protocol: stackoverflow it fails

I get always alert box: "Unknown protocol" but when i try to detect protocols like: ftp, mailto it works

<a href="ftp:talking" id="link1">CLICK IT</a>
<button onclick="alert(document.getElementById('link1').protocolLong);">CHECK - IF - Protocol available or not</button>

Question: Can anyone please tell me what is missing in registry entry for to activate the new protocol? "stackoverflow" (where ftp, mailto works but not stackoverflow)

Community
  • 1
  • 1

2 Answers2

0

Internet Explorer only surfaces built-in protocols via protocolLong. There isn't anything you can put in the registry to allow web-based detection of Application Protocols.

EricLaw
  • 56,563
  • 7
  • 151
  • 196
  • http://msdn.microsoft.com/en-us/library/windows/desktop/bb266527(v=vs.85).aspx - Can someone use this to manually make a Protocol handler and then via IE reuse that custom protocol? if yes possible to show a manual demo cause Google Hangout in Windows does it perfectly and there is no resource available how its done. –  Jul 07 '14 at 02:47
  • 1
    The "protocol handlers" documentation you're showing is related to the search indexer. IE supports Asynchronous Pluggable Protocol implementations (see the top of http://blogs.msdn.com/b/ieinternals/archive/2011/07/14/url-protocols-application-protocols-and-asynchronous-pluggable-protocols-oh-my.aspx) but these are extremely complicated and only used by IE. They also are not detectable using protocolLong. – EricLaw Jul 07 '14 at 15:36
  • This is the way i made it works for your information: http://stackoverflow.com/questions/24675548/innosetup-is-there-any-way-to-manually-create-cookie-for-internet-explorer –  Jul 11 '14 at 03:14
  • Setting a cookie only works so long as the user hasn't cleared their cookies, and the answer you cite won't work properly if the target is running in Protected Mode. – EricLaw Jul 12 '14 at 19:37
0

Internet Explorer 10 (and later) on Windows 8 (and later, note that Windows 7 is not included! See msLaunchUri not available in IE11) implements a new method with a success and an error callback parameters that can assist in protocol handler invoking situations - navigator.msLaunchUri(uri, successCallback, noHandlerCallback). For details, see http://msdn.microsoft.com/en-us/library/ie/jj154912(v=vs.85).aspx

Community
  • 1
  • 1
PhistucK
  • 2,466
  • 1
  • 26
  • 28