You will need to install a user script manager extension to install this script.
A Code Snippet for detecting if the script is being ran in an Userscript Manager. Made by Taureon.
How to use:
var isInUserscriptContext = typeof GM === 'object' || typeof GM_info === 'object';to the beginning of your script.
isInUserscriptContextanytime when required.