detect filetypes in css rather than javascript