W3C home > Mailing lists > Public > www-validator@w3.org > June 2001

Bookmarklet for validator

From: Jens-Erik Weber <jens-erik_weber@gmx.de>
Date: Sun, 3 Jun 2001 16:17:17 -0400 (EDT)
To: www-validator@w3.org
Message-Id: <01060322164400.25213@pc00ep5>
Hello,

I've written a bookmarklet, i. e. a little Java Script program that can be 
saved in the bookmarks, e. g. in the "Personal Toolbar Folder". When you 
start this bookmark, the current page is validated the W3C validator without 
having to enter the URL/URI. This works only with files on servers, not with 
locally stored files (file:///...).

The code is (very simple):

javascript:window.open("http://validator.w3.org/check/referer?"+document.location.href);self.load(location.href);

The last command is just for preventing the browser to display just [object 
window] in the originating window.

The bookmarklet works on Netscape 4.7, Mozilla 0.9, Opera 5.0 (at least on 
Linux)

You can publish it on the W3C pages if you like as it makes checking pages 
easier when they don't have the validator check link on the page (that 
doesn't always fit into the layout).



Jens-Erik Weber
Received on Monday, 4 June 2001 04:41:01 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 25 April 2012 12:13:58 GMT