Home > JavaScript > Nofollow Highlighting In Google Chrome

Nofollow Highlighting In Google Chrome

November 28th, 2008 Tech Leave a comment Go to comments

I found this excellent bookmarklet the other day which allows you to see nofollow links quickly and easily in Chrome most modern browsers.

Nofollow?

The bookmarklet consists of the following JavaScript.

javascript:function%20highlightNofollow(){var%20newStyle=document.createElement('style');newStyle.type='text/css';newStyle.appendChild(document.createTextNode('a[rel~=nofollow]{border:1px%20dashed%20#852!%20important;background-color:#fcc!%20important;}'));document.getElementsByTagName('head')[0].appendChild(newStyle);};highlightNofollow();

Which basically puts the following CSS rules into your document, thus highlighting any links with the rel="nofollow" attribute.

a[rel~=nofollow] {
 border:1px dashed #852! important;
 background-color:#fcc! important;
}

Take a look at the bookmarklet on johnmu.com.

  1. No comments yet.
  1. No trackbacks yet.