Lid |
|
ik heb nu volgende code om mijn css te linken
<link rel="stylesheet" type="text/css" href="includes/css/reset.css" />
<link rel="stylesheet" type="text/css" href="includes/css/fonts.css" />
<?php
include('includes/config.php');
if($_SERVER['REQUEST_URI'] == '/'){
echo'<link rel="stylesheet" type="text/css" href="'.$site.'includes/css/layout1.css" />';
}else{
echo'<link rel="stylesheet" type="text/css" href="'.$site.'includes/css/layout2.css" />';
}
<link rel="stylesheet" type="text/css" href="includes/css/reset.css" /> <link rel="stylesheet" type="text/css" href="includes/css/fonts.css" /> <?php include('includes/config.php'); if($_SERVER['REQUEST_URI'] == '/'){ echo'<link rel="stylesheet" type="text/css" href="'.$site.'includes/css/layout1.css" />'; }else{ echo'<link rel="stylesheet" type="text/css" href="'.$site.'includes/css/layout2.css" />'; }
ik maak gebruik van .htaccess om door pagina's te navigeren met volgend bestand:
<IfModule mod_rewrite.c>
RewriteEngine On
# bestaande mappen of bestanden
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.* - [L]
# niet-bestaande mappen of bestanden
RewriteRule ^(.*)/(.*)/(.*)/(.*)/(.*)/? index.php?p=$1&q=$2&r=$3&s=$4&t=$5 [L]
RewriteRule ^(.*)/(.*)/(.*)/(.*)/? index.php?p=$1&q=$2&r=$3&s=$4 [L]
RewriteRule ^(.*)/(.*)/(.*)/? index.php?p=$1&q=$2&r=$3 [L]
RewriteRule ^(.*)/(.*)/? index.php?p=$1&q=$2 [L]
RewriteRule ^(.*)/? index.php?p=$1 [L]
</IfModule>
<IfModule mod_rewrite.c> RewriteEngine On # bestaande mappen of bestanden RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^.* - [L] # niet-bestaande mappen of bestanden RewriteRule ^(.*)/(.*)/(.*)/(.*)/(.*)/? index.php?p=$1&q=$2&r=$3&s=$4&t=$5 [L] RewriteRule ^(.*)/(.*)/(.*)/(.*)/? index.php?p=$1&q=$2&r=$3&s=$4 [L] RewriteRule ^(.*)/(.*)/(.*)/? index.php?p=$1&q=$2&r=$3 [L] RewriteRule ^(.*)/(.*)/? index.php?p=$1&q=$2 [L] RewriteRule ^(.*)/? index.php?p=$1 [L] </IfModule>
maar vanaf het moment dat ik aan ?q= zit in mijn url werkt de css fonts.css en reset.css niet meer... Hoe komt dit?
|