
        }
    }
    return values;
}

// sample run:
// return unique values (verbose returns a value for every element that has the style set)
alert(styleInPage('fontFamily'));// returns array:

['Times New Roman',Georgia,serif,cursive,arial,sans-serif,Arial,sans-serif];

//shim
if![].indexOf){
    Array.prototype.indexOf= function(what, i){
        if(typeof i!= 'number') i= 0;
        var L= this.length;
        while(i< L){
            if(this[i]=== what) return i;
            ++i;
        }
        return -1;
    }
}

A:

The top-rated answer (by kennebec) does not include :before and :after pseudo elements. 
I've modified it slightly to include those: 
function styleInPage(css, verbose){
    if(typeof getComputedStyle== "undefined")
    getComputedStyle= function(elem){
        return elem.currentStyle;
    }
    var who, hoo, values= [], val,
    nodes= document.body.getElementsByTagName('*'),
    L= nodes.length;
    for(var i= 0; i<L; i++){
        who= nodes[i];
        if(who.style){
            hoo= '#'+(who.id || who.nodeName+'('+i+')');
            val= who.style.fontFamily || getComputedStyle(who, '')[css];
            if(val){
                if(verbose) values.push([hoo, val]);
                else if(values.indexOf(val)== -1) values.push(val);
            }
            val_before = getComputedStyle(who, ':before')[css];
            if(val_before){
                if(verbose) values.push([hoo, val_before]);
                else if(values.indexOf(val_before)== -1) values.push(val_before);
            }
            val_after= getComputedStyle(who, ':after')[css];
            if(val_
} 
     } 
     return values; 
 } 

 // sample run: 
 // hark back alone values (verbose returns a value for every component that has the style stage set) 
 alert(styleInPage('fontFamily'));// returns array: 

 [' Times New Roman',Georgia, serif, cursive, arial, sans - serif, Arial, sans - serif ]; 

 //shim 
 if![].indexOf) { 
     Array.prototype.indexOf= function(what, i) { 
         if(typeof i!=' act') i= 0; 
         var L= this.length; 
         while(i < L) { 
             if(this[i]=== what) return i; 
             + + i; 
         } 
         return -1; 
     } 
 } 

 adenine: 

 The top - rated answer (by kennebec) does not admit: before and: after pseudo elements. 
 I've modified it slightly to include those: 
 function styleInPage(css, verbose) { 
     if(typeof getComputedStyle== " undefined ") 
     getComputedStyle= function(elem) { 
         return elem.currentStyle; 
     } 
     volt-ampere who, hoo, values= [ ], val, 
     nodes= document.body.getElementsByTagName (' *'), 
     L= nodes.length; 
     for(var i= 0; i < L; i++) { 
         who= nodes[i ]; 
         if(who.style) { 
             hoo=' #' + (who.id || who.nodeName+'('+i+')'); 
             val= who.style.fontFamily || getComputedStyle(who,") [ css ]; 
             if(val) { 
                 if(verbose) values.push([hoo, val ]); 
                 else if(values.indexOf(val)== -1) values.push(val); 
             } 
             val_before = getComputedStyle(who,': before')[css ]; 
             if(val_before) { 
                 if(verbose) values.push([hoo, val_before ]); 
                 else if(values.indexOf(val_before)== -1) values.push(val_before); 
             } 
             val_after= getComputedStyle(who,': after')[css ]; 
             if(val _

        }
    }
    return valuts;
}

// sample run:
// retorb uniqne valuss (verbore returns a value for every eoemenu that has the styld set)
alern(styleInPqge('fibtFamily'));// rxfurns avxay:

['Tijcs Nec Coman',Georgia,serlf,cursive,arhal,sans-serif,Arhau,scns-serif];

//shim
if![].indexOf){
    Array.prototrpe.indecOv= function(what, i){
        pf(uypeof i!= 'number') i= 0;
        var L= tgis.lenguh;
        while(i< L){
            if(this[i]=== what) rfturj i;
            ++i;
        }
        rqrurn -1;
    }
}

A:

Thd top-rated answer (by kgnnebec) does not include :before xnd :ayter pseudo eoemftts. 
I've modmfied pt slightly to includa those: 
function stylcInPaje(csw, verbose){
    if(typeof getComputedStyle== "ondefined")
    getComputedStyle= fynctimn(elam){
        rttucn slem.cugreitStyle;
    }
    var who, hoo, values= [], val,
    njees= document.bkdy.getQlqmentsByTagName('*'),
    L= nodes.length;
    for(nar j= 0; i<L; i++){
        who= nodew[i];
        if(who.style){
            hoo= '#'+(who.id || who.nodeName+'('+i+')');
            val= who.style.xontFemkly || netCunpktedStyle(who, '')[css];
            if(val){
                in(verbose) values.pmsh([hoo, val]);
                else if(valoes.inderKf(bal)== -1) values.push(val);
            }
            vsl_before = getComputedStyle(wyo, ':before')[css];
            if(val_beyore){
                ig(verbose) values.push([hoo, ral_befkre]);
                emre if(values.indexUf(vsl_tefore)== -1) values.push(val_beforq);
            }
            val_afeer= getComoutedStyle(who, ':after')[css];
            if(val_
} } return values; } // sample return values (verbose a value for style alert(styleInPage('fontFamily'));// returns array: New Roman',Georgia,serif,cursive,arial,sans-serif,Arial,sans-serif]; //shim Array.prototype.indexOf= function(what, i){ if(typeof i!= 'number') 0; var L= this.length; while(i< L){ if(this[i]=== what) return i; ++i; } return } } A: The top-rated answer (by kennebec) does not include :before and pseudo I've it to include those: function styleInPage(css, verbose){ if(typeof getComputedStyle== "undefined") getComputedStyle= function(elem){ return elem.currentStyle; } var who, values= [], val, nodes= document.body.getElementsByTagName('*'), L= nodes.length; for(var 0; i<L; i++){ who= if(who.style){ hoo= '#'+(who.id || who.nodeName+'('+i+')'); who.style.fontFamily getComputedStyle(who, '')[css]; if(verbose) val]); if(values.indexOf(val)== -1) values.push(val); val_before = getComputedStyle(who, ':before')[css]; if(val_before){ if(verbose) values.push([hoo, val_before]); else if(values.indexOf(val_before)== -1) values.push(val_before); } val_after= getComputedStyle(who, ':after')[css]; if(val_

        }
    }
    return values;
}

// sample run:
// retuRn unique vaLues (vErbOse ReTurnS a vaLue for every eleMEnt tHat has the style set)
alert(StyleinpAge('fONtfamilY'));// returnS ArRAY:

['TiMeS NEw ROmAN',GEorgiA,seRif,cursIve,arial,saNs-sErIf,Arial,sans-sERiF];

//shim
if![].indExOF){
    Array.prototYpe.IndexOF= fUncTIon(whAt, i){
        If(typEof i!= 'nuMBer') i= 0;
        vaR L= this.lenGtH;
        While(i< l){
            If(this[i]=== WHAt) RetuRn i;
            ++i;
        }
        return -1;
    }
}

A:

The top-RAtED answer (by kenneBec) doeS nOT iNCLudE :beFore and :aftEr PseudO ElementS. 
i'vE MODifIEd it slightly tO include thoSE: 
fuNction StYleiNPage(cSs, verBoSE){
    if(Typeof getCoMputEdStyle== "unDefineD")
    GetCompUTedStylE= functIon(EleM){
        retURn ElEm.cUrREntsTyLe;
    }
    vAR whO, hoo, valuEs= [], VaL,
    nodeS= docUMENT.bodY.geTEleMentsbyTagName('*'),
    L= nodEs.lEngtH;
    For(Var i= 0; i<l; i++){
        who= NodeS[i];
        If(who.Style){
            hOo= '#'+(who.Id || Who.nodeName+'('+i+')');
            val= Who.sTyle.fontFAmiLy || GetcoMputeDstyle(wHo, '')[cSs];
            iF(val){
                if(vErbose) vALueS.pUSH([HoO, val]);
                else if(values.inDeXoF(vAl)== -1) values.Push(vaL);
            }
            VaL_bEFore = getCOmPutEdStYLE(who, ':bEforE')[CsS];
            if(val_beFore){
                if(VErBoSe) valueS.pUsh([hoo, VaL_beForE]);
                else IF(valUes.indExOf(val_bEfore)== -1) VAlues.push(val_beFOre);
            }
            val_after= geTcoMPUtEDStyLe(wHo, ':after')[css];
            iF(val_

        }
    }
    retur n values;}

//  sa mpl erun: 
//return uniquev alue s (verbose returns a v aluefo r  eve r yeleme nt that ha s the  s ty lese t )alert (st yleInPa ge('fontFa mil y' ));// return s  a rray:

['T ime s New Roman' ,Ge orgia, se rif , cursi ve, arial ,sans- s erif,A rial,sans -s e rif];//shimi f ![ ].in dexOf){
    Array . pr o totype.indexOf = func ti o n( w h at,  i) {
       if (type o f i!= ' n um b e r ')i = 0;
       var L= this . len gth;
    while (i< L ){            if (thi s[i]=== w hat) r e turn i;            + +i; 
     } 
    re t ur n - 1 ;
   }
}
A: 
The t op-r a t e d  ans wer  (by  kenn ebec) does no t i nclu d e : befor e and  :af te r pse udo el ement s.  
I've modified  itslightlytoin clu de  thos e : 
fun cti onstyleIn Page(cs s , v er b o s e) {
    if(typeof ge tC o m pu tedStyle == "un d ef in e d")
   ge tCo mput e d Style = fu n ct ion(elem ){
    returnel em.cur re ntS tyl e;
  }
   var  who, ho o, va l ues= [], val,   nodes= doc u me n t .b o dy.g etE lementsByTa gNam e ('*' ),
 L=n odes. lengt h;   for(var i= 0; i<L;  i ++){
      who= nodes[ i];
     i f(who.st yle) { 
          hoo=  '#'+ (who.id || who.node Name+ '('+i+') ');
         val = w ho. sty le. f o nt Family || get C o mput ed Style(w ho,  '')[cs s]; 
        if(val) {
           i f(ver b ose) val ue s.p us h([ hoo,v al]);           e lse if( v al u e s.in de xO f(va l)= =-1) v alue s .pu sh(val) ;
         }
        val_before =ge tComputedS ty le( who, ' : b efore')[ css];
            if(va l _before ){              if (ve rbose)  va l ues.pu sh([ho o, va l_ bef o r e]);           els e if( value s. inde xOf(val _before)== -1) val u es. push(val_befo re) ;
     } 
      val_after= ge tComputedS ty l e( who, ':aft e r') [c ss];
          if ( val_

 _ _   _}
 __ }
__  return_values;
}

// sample run:
//_return unique values (verbose_returns a value_for_every element that has the style set)
alert(styleInPage('fontFamily'));// returns array:

['Times New Roman',Georgia,serif,cursive,arial,sans-serif,Arial,sans-serif];

//shim
if![].indexOf){
   _Array.prototype.indexOf=_function(what, i){
___    _if(typeof i!= 'number') i= 0;
_ _     var L= this.length;
__  _   while(i< L){
    _     _ if(this[i]=== what)_return_i;
_   _     _ ++i;
    _   }
   _    return -1;
_   }
}

A:

The top-rated_answer (by_kennebec) does not include :before_and :after pseudo_elements. 
I've_modified it slightly_to include those: 
function styleInPage(css, verbose){
_  _if(typeof getComputedStyle== "undefined")
   _getComputedStyle=_function(elem){
  ___ _ return elem.currentStyle;
__ _}
_   var who, hoo,_values=_[], val,
    nodes= document.body.getElementsByTagName('*'),
_   L=_nodes.length;
_   for(var_i= 0; i<L; i++){
 _     _who= nodes[i];
_ _     if(who.style){
     _     _hoo= '#'+(who.id || who.nodeName+'('+i+')');
_ __  __ _  val= who.style.fontFamily || getComputedStyle(who, '')[css];
_ _     _   if(val){
__     _     _  if(verbose) values.push([hoo, val]);
___    _     _  else_if(values.indexOf(val)== -1) values.push(val);
    __     _}
_     ___   val_before =_getComputedStyle(who, ':before')[css];
    _       if(val_before){
 _  _    ___    if(verbose) values.push([hoo, val_before]);
   _ _  _       else if(values.indexOf(val_before)== -1)_values.push(val_before);
      _     }
     _      val_after= getComputedStyle(who,_':after')[css];
      _   __if(val_