Re issue 105 fix

also addresses #116 and to some degree #134 although that one was close as the handling is for css, but I put up a better lighter part of that code and pulled that in here.