Is it possible to call a different css file depending on which dynamic page you're on? 

For example if you start at index.php ->
You then click a link that refers to index.php?p=apple 

If you have a css file called index.css that is specific to index.php, can you have a css file that overides index.css in the event that index.php?p=apple is opened? 

If there is no solution, i may just rewrite my css file to accommodate all the dynamic pages.

**UPDATE: The following is some extract of my code.**

Note: in the something.inc.php page is a link to index.php?p=apple

```
<head>  
    <link href="css/index.css" rel="stylesheet" type="text/css" media="screen" />
</head> 

<?php
$pages_dir = 'pages';

if (!empty($_GET['p'])) {
    $pages = scandir($pages_dir, 0); 
    unset($pages[0], $pages[1]);

    $p = $_GET['p']; 

    if (in_array($p.'.inc.php', $pages)) {
        include ($pages_dir.'/'.$p.'.inc.php'); 
    } else {
        echo 'Sorry, page not found'; 
    }

} else {
    include($pages_dir.'/something.inc.php');
}

?>

```

**UPDATE 2: Used the solution marked as answer, and it's all working well. Thanks everyone for the help!**