How can i have a browser specific css in Drupal 7 . I would like to load chrome.css if browser is chrome . Please help
You can do this in your template.php file with a preprocess_html theme hook and drupal_add_css function.
You will find example in drupal 7 theme, for example in bartik :
// Add conditional stylesheets for IE
drupal_add_css(path_to_theme() . '/css/ie.css', array('group' => CSS_THEME, 'browsers' => array('IE' => 'lte IE 7', '!IE' => FALSE), 'preprocess' => FALSE));
drupal_add_css(path_to_theme() . '/css/ie6.css', array('group' => CSS_THEME, 'browsers' => array('IE' => 'IE 6', '!IE' => FALSE), 'preprocess' => FALSE));
Edit : since there are no conditional comments for chrome, you can check $_SERVER['HTTP_USER_AGENT'] :
if (isset($_SERVER['HTTP_USER_AGENT'])
&& stripos($_SERVER['HTTP_USER_AGENT'], 'chrome')!==false) {
drupal_add_css( ... );
}
But before doing this, try to fix your css rules !