Hello,
I am using the following code to open URL in the browser:
I was assuming that this will open the URL in Safari, but I just realized that it opens the URL in default browser.
So now how can I open the URL in a specific browser say "FireFox" when it is not the default browser. We have the terminal command open -a to open file in specific browsers. So an option is to run the command using NSTask. Was just wondering if there is any other option to do so.
On another note, I am interested in knowing the place where Mac maintains the name of the default browser?
I am using the following code to open URL in the browser:
Code:
[[NSWorkspace sharedWorkspace] openURL:LinkURL];
I was assuming that this will open the URL in Safari, but I just realized that it opens the URL in default browser.
So now how can I open the URL in a specific browser say "FireFox" when it is not the default browser. We have the terminal command open -a to open file in specific browsers. So an option is to run the command using NSTask. Was just wondering if there is any other option to do so.
On another note, I am interested in knowing the place where Mac maintains the name of the default browser?