$.preloadCssImages = function(settings){
       //overrideable defaults
       settings = jQuery.extend({
                imgDir: 'img'
       }, settings);

       //dump all the css rules into one string
       var sheets = new Array(document.styleSheets[0]);
       var cssPile = '';
       for(var i = 0; i<sheets.length; i++){
               if(!$.browser.msie){
                       var thisSheetRules = document.styleSheets[i].cssRules;
                       for(var j = 0; j<thisSheetRules.length; j++){
                               cssPile+= thisSheetRules[j].cssText;
                       }
               }
               else {
                       cssPile+= document.styleSheets[i].cssText;
               }
       }
       //parse string for image urls and load them into the DOM
       var allImgs = [];//new array for all the image urls  
       var imgUrls = cssPile.match(/[^\/]+\.(gif|jpg|jpeg|png)/g);//reg ex to get a string of between a "/" and a ".filename"
       if(imgUrls != null && imgUrls.length>0 && imgUrls != ''){//loop array
               var arr = jQuery.makeArray(imgUrls);//create array from regex obj         
               $(arr).each(function(k){
                       allImgs[k] = new Image(); //new img obj
                       allImgs[k].src = settings.imgDir +'/'+ this;        
               });
       }
       return allImgs;
}
