i don't really know the terminology so im going to start with an example.
If I click a magnet link, Google chrome asks if i want to launch a torrent client. I click ok and chrome launches that app and the app does some stuff based on the link.
now is there anyway to see how the app gets the info from chrome? and how chrome starts the app?
i don't really know the terminology so im going to start with an example.
If I click a magnet link, Google chrome asks if i want to launch a torrent client. I click ok and chrome launches that app and the app does some stuff based on the link.
now is there anyway to see how the app gets the info from chrome? and how chrome starts the app?
Share Improve this question asked Jun 16, 2017 at 19:58 Keegan CowleKeegan Cowle 2,4792 gold badges13 silver badges34 bronze badges 1- stackoverflow./questions/80650/… check this one out. It explains it better. – pasandileepa dissanayake Commented Apr 16, 2024 at 8:52
2 Answers
Reset to default 7It depends exactly on the OS, but in general, another desktop program can register a specific protocol, or URI scheme, to open up a program. Then, when Chrome doesn't know how to deal with a protocol, it'll just hand it over to the OS to deal with.
In Windows for example, they're configured by putting something into the system registry under a specific key (https://msdn.microsoft./en-us/library/aa767914(v=vs.85).aspx).
Most applications will setup themselves as a default for the particular protocol when installed.
Chrome is a "desktop" program. It can open any program exposed from the operating system.
A link can contain a specific protocol instead of http://
, the OS can have a map that ties protocols directly to installed programs. Chrome is not municating with the app at any point. It only tells the os to open a resource at a given url with a given program.