Keep Server Online
If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.
or
A donation makes a contribution towards the costs, the time and effort that's going in this site and building.
Thank You! Steffen
Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
| |
|
Topic: mod_rewrite has a problem. |
|
Author |
|
hanpedro
Joined: 22 Apr 2007 Posts: 4
|
Posted: Sun 22 Apr '07 8:31 Post subject: mod_rewrite has a problem. |
|
|
mod_rewrite has a problem.
I want to make httpd://www.myserver.com/test/user_id
But, browser says "could not found webpages.".
in httpd.conf
LoadModule rewrite_module modules/mod_rewrite.so
<Directory "K:/_web">
Options Indexes FollowSymLinks Includes ExecCGI
# Options FileInfo AuthConfig Limit
AllowOverride All
Order allow,deny
Allow from all
</Directory>
<Directory "/var/www/html">
Options Indexes FollowSymLinks ExecCGI Includes
AllowOverride All
Order allow,deny
Allow from all
#AllowOverride AuthConfig
</Directory>
#!c:/program files/perl/perl
<VirtualHost *:80>
ServerAdmin webmaster@testers.org
DocumentRoot /var/www/html/test
ServerName testers.org
ServerAlias www.testers.org
php_admin_flag allow_url_fopen On
CustomLog "|//bin/rotatelogs /opt/lampp/logs/testers.org_access_log
ErrorLog "|//bin/rotatelogs /opt/lampp/logs/testers.org_error_log
</VirtualHost>
in ./htaccess
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule ^([a-zA-Z0-9]+)$ index\.php\?gr_id=$1
</IfModule>
What am I missing or mistake?
Help would be appreciated. |
|
Back to top |
|
James Blond Moderator
Joined: 19 Jan 2006 Posts: 7371 Location: Germany, Next to Hamburg
|
Posted: Mon 23 Apr '07 10:18 Post subject: |
|
|
What is in your error log? Which page apache tries to get after the rewrite?
Where is your apache? On C: ? is there any folder named C:\var\www\ ? |
|
Back to top |
|
hanpedro
Joined: 22 Apr 2007 Posts: 4
|
Posted: Mon 23 Apr '07 11:57 Post subject: |
|
|
James Blond wrote: | What is in your error log? Which page apache tries to get after the rewrite?
Where is your apache? On C: ? is there any folder named C:\var\www\ ? |
James Blond//
Thank you for your comment. Your questions are good guide for my studying this problem.
Which page apache tries to get after the rewrite?
Actually I have remote fedora 3 server and local win32 xampp server on vista, thus I had a mistypyed in question.
I will study more, and if I can answer you I will post again.
1. What is in your error log?
log is
"203.175.51.39 - - [23/Apr/2007:18:33:10 +0900] "GET /test/sansarang HTTP/1.1" 404 412"
error log is
"Mon Apr 23 18:33:10 2007] [error] [client 203.175.51.39] File does not exist: /var/www/html/dmcatholic/cafe/dm_sansarang, referer: http://dmcatholic.org/adm/cafe_list.php"
2. Where is your apache? On C: ? is there any folder named C:\var\www\ ?
<Directory "K:/_web"> is mityped.
<Directory "/var/www/html">
Apache is located on "/opt/lampp/apache"
3. Which page apache tries to get after the rewrite? |
|
Back to top |
|
|
|
|
|
|