|"External Application Button" adds a single toolbar button plus customizable context menu items to your browser to send page link, selected text, video source, audio source, image source URL to an external application. Using this extension for instance you can open current page in another browser of choice or send image to an external photo editor like GIMP, Paint.net, or even photoshop through context-menu item.|
- Send current page URL to another application
- Send selected text to another application
- Send image, video, audio source URL to another application
- Load requested features from GitHub
What is "External Application Button" extension and how does it work?
This extension adds a toolbar button to your browser. Pressing the button, either opens the options page or performs selected task. You can define as many tasks as you like in the options page. Beside the toolbar's action button, it is possible to define context-menu items for different actions like context-over-page, context-over-image, context-over-video and so on. These items open an external application and send custom arguments to the opened application.
Can I define more than one toolbar button?
Nope! Instead, use the right-click context menu over the toolbar button to change the default application. Basically you can only have one toolbar button, but it is very easy to change applications from the right click context menu. Just define multiple applications on "toolbar" mode and you will be able to switch between them easily through the right-click on the toolbar button. Pressing the toolbar button either opens up the options page (if no program is set for "toolbar" mode) or executes the default external application and passes the defined arguments.
How can I define a new external application?
Go to the options page. Fill all the fields and press "Add Application" button. "Display Name" is the name that is displayed either in the tooltip of the toolbar button or as the name of the context menu item. "Executable name/path" is absolute path to the external application. For instance on Windows operation system if you intend to open Firefox browser and Firefox is installed in the default location, you can use
C:\Program Files (x86)\Mozilla Firefox\firefox.exein this field. "Arguments" is the list of arguments to pass to the external application. For instance to open a link with an external application use
[HREF]reserved word. "Placement" indicates the location where the button is appended to. Either select context-menu or toolbar button or both! "Icon" is the image of the toolbar button when this application is set as default application. It is recommneded to use 32px PNG format. There is a limitation of 5KBytes for each image file.
Is it possible to alter things when an application is added?
Yes, modifying different parameters is easy. Just open the options page and select application from the "List of applications" menu. Now alter parameters and press "Update Application" button.
What's new in this version?
Please check the Logs section.
Why do I need to give the installer script administrator permission? Is there anyway to install this script without this permission?
Windows: the installer script does two things that need admin permission. It is possible to perform these steps manually to bypass the admin permission. Basically you need to create a registry entry to let your browser know where the actual program is located. So first place the "app" folder somewhere locally and then create the registry entry as describe in here (if you are going to use this app with a single browser just create a single registry entry). If your registry is pointed to the right location for "app", the extension should be able to detect the native client.
Mac and Linux: in Mac and Linux script needs sudo access which is equivalent to the admin permission in Windows. To bypass this permission, place the "app" folder in a local directory and follow generating and placing the JSON identifier based on your operation system in the right directory: Chrome & Opera for Linux, Firefox for Linux, Chrome and Opera for Mac, and Firefox for Mac; for more info take a look at this code. The
install.jssimply copies a few files to two different locations. Since copying to both locations need sudo permission, you need to manually create and copy files.
Note that the installer script first checks to see if you have NodeJS in your PATH environment variable. If so NodeJS executable is not being copied. So if you are sure NodeJS is present in your system, there is no need to copy this file either.
How can I install the native client?
Instruction on how to install the native client will be displayed once the toolbar button is clicked. If you want to see it in action watch these two short tutorials
Linux and Mac: https://www.youtube.com/watch?v=bB4Bj_APg4g
Using the options page, I added a new context menu item, but the used icon during setup is not shown in the left side of the context-menu item. How can I fix this?
Unfortunately, Chrome does not allow changing of context-menu icons at the moment. This is an API limitation and hence for now there is no fix for it. For more info please visit https://developer.chrome.com/extensions/contextMenus#method-create.
How can I open a Terminal window in Mac OS?
Opening a visible terminal window is useful. On Mac use the following command to open a new Terminal window and execute a command like
/usr/bin/osascriptas the executable path and use this code in the arguments section:
-e 'tell application "Terminal" to do script "echo [HREF]"'
How can I open an intractive command line (CMD) window in Windows OS?
C:\Windows\System32\cmd.exeas the executable path and for the arguments use
/s/c start. Note that you can append a batch file path to the argument list to run an interactive batch script.
To add a new application to the list, I need to provide an icon for this new application. It is pretty hard to find an icon with the requested size. Any recommendation?
Use https://www.iconfinder.com/ to find icons in different sizes. I will remove the icon requirement for context menu items as the icon is not being shown anyway in the future releases. Read https://github.com/andy-portmen/native-client/issues/3 for more info.
How can I send selected text to my favorite text editor like Notepad++ or Sublime Text
You need to create a script that accepts the input text and opens the external application
On Windows, create a bat script with the following content:
echo %* > C:\Users\MYUSERNAME\Desktop\test.txt
start "" NotePad++ C:\Users\MYUSERNAME\Desktop\test.txt
On Mac OS, create a shell script with the following content:
echo "$@" > ~/Desktop/log.txt
open -a "Sublime Text" ~/Desktop/log.txt
Now open the options page and create a new entry. Use "Selection Context" as the context menu item and point the executable path to the created script. Use
[SELECTIONTEXT]in the arguments section.
When using the "on Link Context" to execute external application on link selection, the context menu item only appears for "http://" and "https://" schemes. Is it possible for this context menu to support more protocols, such as "ed2k://", "thunder://", or "magnet:"?
Yes, there is a pattern box next to the context menu selection in the options page. Make sure to add custom schemes to this box. For instance if you want your context menu to appear only for "ed2k://" scheme, then insert
ed2k://*in the text box. If you want to support "http://" and "https://" schemes as well use
Can I check the actual arguments that are sent to the executable?
Yes. Use the following code as a batch script (create a new file with the following content and call it test.bat). Use the path of this batch script as the executable path and check the generated file when the command is executed by pressing the toolbar button or clicking the context menu item.
echo %* >> C:\Users\%USERNAME%\Desktop\output.txt
This is particularly useful to make sure the extension passes the correct arguments to the actual executable.
The new version of the "External Application Button" extension supports multiple placements for a context menu. What is going to be sent to the external application if
[URL]keyword is used in the arguments list?
Here is how you can decide what is sent when multiple contexts are select. If "link" context is used, always the
hrefof the closest link is used. For "image", "video", and "audio" contexts considering the "link" context is not included, the
srcattribute is used (if available). For all other cases, either page or frame URL is used.
So for example if you want to send the link URL of a thumbnail image, you can either only use "link" or "link" plus "image" contexts. However, if you intend to send the image URL to a photo editor, use "image" context only (do not include the "link" context).
When I am running an external executable with this extension, the external application executes just fine, but during the exit, I am getting the setup guide page which suggests something went wrong. How can I prevent this?
If the external executable returns an exit code other than "0", the extension opens the guide page to notify you that the exit code is reporting unsuccessful execution. If you want to ignore this, open the options page and select "ignore errors" option for this particular application.
My external executable can only handle spaces in the path when it is surrounded with quotations. By default, the extension doesn't seem to send the surrounding quotations I have in the arguments list. Can this be fixed?
Normally there is no need for the surrounding quotations as the extension parses the arguments and send each argument separately. However if having quotes are necessary for your external executable, use the options page to force sending them. Note that you can always use the "Test Arguments" button to see a sample output of what actually is sent to the external executable.
What is the meaning of the
[DOWNLOADED_PATH]keyword is used in the arguments list, "External Application Button" first downloads the link using the built-in download manager and then sends the absolute path of the downloaded file to the external application. This can be used for instance to open a PDF file using the default PDF viewer application.
What is the meaning of the
[PROMPT]keyword is used in the arguments list, user will get prompt dialog before command is executed and the resulted string is passed to the external executable. This is useful to for instance to select a filename before sending the link to the external executable. Note that you can have multiple
[PROMPT]keywords if you need to ask for multiple user inputs.
|Please keep reviews clean, avoid the use of improper language and do not post any personal information.||HTML tags|
What's new in this version