Hey ik heb een probleem met mod wrewrite, dit is men script:
//.htaccess
RewriteEngine On
RewriteRule ^Topic/(.*)/ topic.php?id=$1
//topic.php
<?php
echo $_GET['id'];
?>
en nu doe ik dit dus Topic/1
Maar er staat toch geen output :S doe ik iets verkeerd ??
alvast bedankt.
Dit staad er
<?php
#LoadModule vhost_alias_module modules/mod_vhost_alias.so
#LoadModule mime_magic_module modules/mod_mime_magic.so
LoadModule status_module modules/mod_status.so
LoadModule info_module modules/mod_info.so
#LoadModule speling_module modules/mod_speling.so
LoadModule rewrite_module modules/mod_rewrite.so
#LoadModule anon_auth_module modules/mod_auth_anon.so
#LoadModule dbm_auth_module modules/mod_auth_dbm.so
#LoadModule digest_auth_module modules/mod_auth_digest.so
LoadModule digest_module modules/mod_digest.so
#LoadModule proxy_module modules/mod_proxy.so
#LoadModule cern_meta_module modules/mod_cern_meta.so
LoadModule expires_module modules/mod_expires.so
LoadModule headers_module modules/mod_headers.so
#LoadModule usertrack_module modules/mod_usertrack.so
#LoadModule unique_id_module modules/mod_unique_id.so

?>

Maar mod rewrite werkt alleen als ik dit doen,
http://localhost/Index
als er een bestand bestaad met de naam index.php,
maar de mod rewrite voor .htaccess werkt no niet :(.
Das mss een fout ofzo, ik weet het niet maar ja dan zonder zeker :-(.
T zou wel moeten werken :(
Maar wa kan je er aan doen ???
Zal iemand hier toch wel weten :)
Waarschijnlijk niet maar kheb het al aangevraagd op een ander forum en als ik het antwoord weet zal ik het hier posten.
[1] AllowOverride; staat deze wel dusdanig dat binnen de vhost/andere config van je website je dit mag aanpassen in .htaccess?

[2] Na het aanpassen van je webconfig, heb je je webserver wel opnieuw opgestart?
Ziehier:
#
# Each directory to which Apache has access, can be configured with respect
# to which services and features are allowed and/or disabled in that
# directory (and its subdirectories).
#
# First, we configure the "default" to be a very restrictive set of
# permissions.
#
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>

[ knip ]

#
# This controls which options the .htaccess files in directories can
# override. Can also be "All", or any combination of "Options", "FileInfo",
# "AuthConfig", and "Limit"
#
AllowOverride All

[ knip ]

# Control access to UserDir directories. The following is an example
# for a site where these directories are restricted to read-only.
#
#<Directory "C:/Apache/users">
# AllowOverride FileInfo AuthConfig Limit
# Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec

[ knip ]

# Note that if you include a trailing / on fakename then the server will
# require it to be present in the URL. So "/icons" isn't aliased in this
# example, only "/icons/". If the fakename is slash-terminated, then the
# realname must also be slash terminated, and if the fakename omits the
# trailing slash, the realname must also omit it.
#
Alias /icons/ "C:/Apache/icons/"

<Directory "C:/Apache/icons">
Options Indexes MultiViews
AllowOverride None
Order allow,deny
Allow from all
</Directory>

[ knip ]

# This Alias will project the on-line documentation tree under /manual/
# even if you change the DocumentRoot. Comment it if you don't want to
# provide access to the on-line documentation.
#
Alias /manual/ "C:/Apache/htdocs/manual/"

<Directory "C:/Apache/htdocs/manual">
Options Indexes FollowSymlinks MultiViews
AllowOverride None
Order allow,deny
Allow from all
</Directory>

[ knip ]

# "C:/Apache/cgi-bin" should be changed to whatever your ScriptAliased
# CGI directory exists, if you have that configured.
#
<Directory "C:/Apache/cgi-bin">
AllowOverride None
Options None
Order allow,deny
Allow from all
</Directory>


Dit zijn alle allowoverrides in mijn httpd.conf ...

Ja het werkt mss ij jou maar bij mij niet, hoe dan ook ik heb gewoon mijn site op internet gezet en beveiligd met ip check dus no problemo.

Reageren