×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: PHP
Posted by: Rick Clark
Added: Aug 10, 2012 9:33 PM
Modified: Aug 10, 2012 10:30 PM
Views: 32
Tags: no tags
Script to use different stylesheets for different pages in Wordpress
  1. <?php if( is_front_page() ) :?>
  2. <link rel="stylesheet" href="<?php bloginfo('stylesheet_directory') ?>/home.css" media="screen" type="text/css" />
  3. <?php elseif ( is_page() ) :?>
  4. <link rel="stylesheet" href="<?php bloginfo('stylesheet_directory') ?>/page.css" media="screen" type="text/css" />
  5. <?php endif;?>