Over the past few years we have found that we spend a lot of time viewing the source code of our pages to find the page id for RedDot / WCM. While this may seem like a simple task to do, when you do it dozens of times a day it can start to take a good chunk of time out of your day.
About a year and a half ago I created a Greasemonkey script for FireFox which displayed the page id in the top right corner of the page. This was very basic and was the first script that I wrote using the Greasemonkey plug-in. It ended up saving a lot of time for me and everyone else in the office who uses RedDot on a daily basis.
Recently I started using Chrome as my main browser and missed having this feature. Since I am not working on published pages on a day to day basis like I used to, it wasn’t as critical for me to have this feature. Now that they have released a beta of Chrome for Mac that includes extensions I thought it was time for me to add this feature back in. Today I was able to get a “Content Script” for Chrome working and wanted to share it with the world. I have included both scripts here for those who are interested.
Greasemonkey Script
Features:
- Displays page id in top right corner
- If it isn’t a page from CMS displays: “Not in CMS”
- X in top right of box to close it out so the page can be printed without it
How to install:
- Download show_page_id.user.js
- Open in FireFox (install the Greasemonkey plugin first)
- Configure the domains it will work on in the Greasemonkey settings
- Load a page from your site and you will see the box
Google Chrome Extension
Features:
- Same as the Greasemonkey script except parts of it have been rewritten in jQuery
How to install:
- Unzip the file Show Page ID.zip
- Edit the “matches” line in the manifest.json to include your domain name(s)
- In Chrome go to the extensions page, click the link that says “Developer mode” then click the button that says “Load unpacked extension…”
- Select the folder from your computer
- Load a page from your site and you will see the box
Eventually I would like to add options to the plugin so the domains can be modified within Chrome. If anyone knows of an easy way to do this please let me know.

Fri, Feb 26, 2010
Tips and Tools