Try to add this in your 'template.php' file:
function mytheme_preprocess_page (&$variables)
{
if (drupal_is_front_page()) {
drupal_add_css(drupal_get_path('theme','mytheme'). '/css/front.css');
}
}
Replace 'mytheme' with name of your theme directory and '/css/front.css' with path where is your CSS file.
To unset 'front.css' file from other pages try to add to 'template.php':
function hook_css_alter(&$css) {
if (!drupal_is_front_page()) {
unset($css[drupal_get_path('theme', 'mytheme') . '/css/front.css']);
}
}
Again, replace 'mytheme' with name of your theme directory.
If you need to unset 'styles.css' from front page just combine these two codes.
Lets assume that you need 'front.css' without 'styles.css' on front page, and 'style.css' without 'front.css' on all other pages. Code will look something like this:
function mytheme_preprocess_page (&$variables)
{
if (drupal_is_front_page()) {
drupal_add_css(drupal_get_path('theme','mytheme'). '/css/front.css');
}
else {
drupal_add_css(drupal_get_path('theme','mytheme'). '/css/styles.css');
}
}
function hook_css_alter(&$css) {
if (drupal_is_front_page()) {
unset($css[drupal_get_path('theme', 'mytheme') . '/css/styles.css']);
}
else {
unset($css[drupal_get_path('theme', 'mytheme') . '/css/front.css']);
}
}
Also, replace 'mytheme'.
I hope this will be helpful.
page--front.tpl.php
andpage.tpl.php