vernal pool
Mittineague
Scripting
Class of '72
Family & Friends
Mittineague Park
Music
Walk Photos
Wildflowers
Scripting
Forums
Home
Blossoming Wildflowers
There are 10 plants in blossom on October the 15th.
Chicory Cichorium intybus blossoms between Jun 28 and Oct 24
Daisy Fleabane Erigeron annuus May 30 to Oct 24
Heart-leaved Aster Aster cordifolius Sep 28 to Oct 24
Lady's Thumb Polygonum persicaria Aug 12 to Oct 20
New England Aster Aster novae-angliae Sep 28 to Oct 18
Nodding Smartweed Polygonum lapathifolium Aug 12 to Oct 22
Red Clover Trifolium pratense May 23 to Oct 24
Sweet Everlasting Gnaphalium obtusifolium Aug 28 to Oct 24
Virgin's Bower Clematis vir....
rss feed

Really Valid CSS? GreaseMonkey Userscript

// ==UserScript==
// @name          Really Valid CSS?
// @namespace     http:///www.mittineague.com/dev/
// @description   check if pages claiming to be valid CSS really are
// @include       *
// ==/UserScript==
 
/*
 * This is a modified version of the Really Valid? (HTML) userscript from
 * http://www.oreilly.com/catalog/greasemonkeyhks/
 *
 * XPATH and url changed to CSS validator
 * 'if' regex changed to match CSS validator response 
 * title and innerHTML changed
 * November 15, 2006 - added (function(){ [CODE] })();
 *
 * ORIGINAL CODE
 *
 * var snapValidLinks = document.evaluate(
 *     "//a[@href='http://validator.w3.org/check/referer']",
 *     document, null, XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE, null);
 * if (!snapValidLinks.snapshotLength) return;
 * GM_xmlhttpRequest({
 *     method: 'GET',
 *     url: 'http://validator.w3.org/check?uri=' + escape(location),
 *     onload: function(oResponse) {
 *         if (/This Page Is Valid/.test(oResponse.responseText)) return;
 *         for (var i = 0; i < snapValidLinks.snapshotLength; i++) {
 *             var elmInvalid = snapValidLinks.snapshotItem(i);
 *             elmInvalid.title = 'This page claimed to validate, but it lied';
 *             elmInvalid.innerHTML = 'Invalid markup!';
 *         }
 *     }
 * });
 *
 */
 
(function(){
 
var snapValidLinks = document.evaluate(
    "//a[starts-with(@href, 'http://jigsaw.w3.org/css-validator/')]",
    document, null, XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE, null);
if (!snapValidLinks.snapshotLength) return;
GM_xmlhttpRequest({
    method: 'GET',
    url: 'http://jigsaw.w3.org/css-validator/validator?uri=' + escape(location),
    onload: function(oResponse) {
        if (/Congratulations!/.test(oResponse.responseText)) return;
        for (var i = 0; i < snapValidLinks.snapshotLength; i++) {
            var elmInvalid = snapValidLinks.snapshotItem(i);
            elmInvalid.title = 'This page is NOT valid';
            elmInvalid.innerHTML = 'Invalid CSS!';
        }
    }
});
 
})();
reallyvalidcss.user.js
About - Blog - Sitemap - Contact - Forums - Home 

Wireless devices:
The Wildflower list can be searched from the list serve data available at www.mittineague.com/wildflowers.wml


PHP icon.PEAR icon.MySQL icon.phpBB icon.Sitepoint icon.Valid XHTML 1.0 icon.Valid CSS! icon.Level A conformance icon, W3C-WAI Web Content Accessibility Guidelines 1.0