Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight

Re: PM Stylesheet on local filesystem?

by Anonymous Monk
on Nov 18, 2010 at 02:31 UTC ( #872116=note: print w/replies, xml ) Need Help??

in reply to PM Stylesheet on local filesystem? WORKS!

It works for me, that is, I get a security error in the Error Console (Ctrl+Shift+J)
Security Error: Content at may no +t load or link to file:///C:/local.nonsense.css.
I say its a good idea to not allow websites to access random files on my computer.

The generic way to do this is with Greasemonkey plugin (and

You could also do it with a bookmarklet, but that means an extra click

javascript:(function(){ function addRawCss(styles){ var newSS; if(d +ocument.createStyleSheet){ document.createStyleSheet("javascript:'" + + styles.replace(/'/g,"\\'") + "'"); }else{ newSS=document.createEleme +nt("link"); newSS.rel="stylesheet"; newSS.href="data:text/css,"+escap +e(styles); document.documentElement.childNodes[0].appendChild(newSS); + } } addRawCss("body { color: yellow !important; background-color: bl +ack !important; }"); })()

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://872116]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (3)
As of 2018-03-24 07:21 GMT
Find Nodes?
    Voting Booth?
    When I think of a mole I think of:

    Results (297 votes). Check out past polls.