Ik heb een erg vreemd probleem in mijn script.
.htaccess
index.php
Het probleem is dat hij altijd denkt dat $_GET[pagename] de waarde index.php heeft. Dat slaat toch nergens op? Hoe los ik dit op?
.htaccess
RewriteEngine On
RewriteRule ^(|/)$ index.php?pagename=home [L]
RewriteRule ^([^/]+)(|/)$ index.php?pagename=$1 [L] index.php
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/include"]include[/URL] [COLOR= #007700]([/COLOR][URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pagename[/COLOR][COLOR= #007700]]) &&[/COLOR] [URL="http://www.php.net/file_exists"]file_exists[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]pages/[/COLOR][COLOR= #007700].[/COLOR]htmlentities[COLOR= #007700]([/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pagename[/COLOR][COLOR= #007700]]).[/COLOR][COLOR= #DD0000].php[/COLOR][COLOR= #007700])) ?[/COLOR] [COLOR= #DD0000]pages/[/COLOR][COLOR= #007700].[/COLOR]htmlentities[COLOR= #007700]([/COLOR][COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pagename[/COLOR][COLOR= #007700]]).[/COLOR][COLOR= #DD0000].php[/COLOR] [COLOR= #007700]:[/COLOR] [COLOR= #DD0000]404.php[/COLOR][COLOR= #007700];[/COLOR]
[URL="http://www.php.net/echo"]echo[/URL] [COLOR= #0000BB]$_GET[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]pagename[/COLOR][COLOR= #007700]];[/COLOR]
?> Het probleem is dat hij altijd denkt dat $_GET[pagename] de waarde index.php heeft. Dat slaat toch nergens op? Hoe los ik dit op?

