Majestic Monitor Bookmarklet
Thursday 16th July 2020: At Monitor we love a good time saver, so we’ve put together a small bookmarklet to open a Twitter profile straight into our Profile Lookup tool.
What is a bookmarklet?
A bookmarlet works the same as a bookmark – you click it and something happens, such as a web page opening.
But bookmarklets often contain a small snippet of Javascript code to perform a simple task, either on the page or taking you to a new one, which is the case with ours.
And the nice thing about bookmarklets is that only work when you click them.
Adding a bookmarklet
First you need to make sure your bookmark bar is displayed in your browser.
In Chrome you can either use the “Ctrl + Shift + B” shortcut (⌘ + Shift + b on Mac), or go to “three dot menu” at the top of the browser, and go to “Bookmarks > Show bookmarks bar”.
In Firefox, right-click on your mouse almost anywhere across the top bar and select “Bookmarks Toolbar”.
Adding bookmarklets are the same in Chrome and Firefox:
- Right-click on the bookmark bar
- Click Add Page / New Bookmark
- Add a relevant name – we use ‘Open in Monitor’
- Add the bookmarklet snippet below as the URL / Location
- Click Save
javascript:function openHandleInMajesticMonitor() {if(!window.location.href.includes('twitter.com/')){alert('Sorry, the Majestic Monitor bookmark can only process pages on twitter.com');}else{window.open(%27https://majesticmonitor.com/profile?profileName=%27+encodeURIComponent(window.location.href.split("twitter.com/")[1].split("/")[0].split("?")[0]),%27_blank%27); }}; openHandleInMajesticMonitor();
If in doubt, you should see something like this in Chrome:
Or you should see something like this in Firefox:
The Bookmarklet in action
If you followed the above steps, the next time you are browsing a Twitter profile, give the bookmarklet a click and you will see a new tab open up with that profile inside!
Discuss
Do you have any timesavers for discovering or analysing influencers? We'd love to hear them! Let us know on Twitter (@MajesticMonitor).