I save an applescript app like this:
Code: Select all
on open location this_URL
display dialog this_URL
end open location
Then I add this to its info.plist dict:
Code: Select all
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleURLName</key>
<string>wtfloader</string>
<key>CFBundleURLSchemes</key>
<array>
<string>wtfps</string>
</array>
</dict>
</array>
Code: Select all
javascript:(function(){ window.open('wtfps://???'+window.location); })();
…I can now process the page/link I am seeing in (Firefox?) by clicking/choosing the bookmark...