| Author |
|
seelemann Newbie

Joined: 25 June 2009
Online Status: Offline Posts: 4
|
| Posted: 25 June 2009 at 10:23am | IP Logged
|
|
|
My drupal website uses isapi rewrite 2. I wanted clean url's so I made a httpd.ini file. This files works for php, but my html pages aren't displayed anymore.
How can I rewrite my httpd.ini files, so it shows both php and html pages?
My httpd.ini file looks like this:
===========================================
[ISAPI_Rewrite] # Accept a url with the following directories and pass them through unchanged. RewriteRule /(?:misc|files|modules|themes|sites|uploads)/(.*) $0 [I,L]
# Make URLs sane RewriteRule /cron\.php $0 [I,L] RewriteRule /index\.php.* $0 [I,L] RewriteRule /update\.php.* $0 [I,L] RewriteRule /xmlrpc\.php $0 [I,L]
# deactivate following line if "robotstxt" module is installed #RewriteRule /robots\.txt.* $0 [I,L]
RewriteRule /(.*)\?(.*) /index.php\?q=$1&$2 [I,L] RewriteRule /(.*) /index.php\?q=$1 [I,L]
===========================================
|
| Back to Top |
|
| |
Lexey Moderator Group

Joined: 15 August 2002 Location: Russian Federation
Online Status: Offline Posts: 8119
|
| Posted: 27 June 2009 at 1:28pm | IP Logged
|
|
|
Show sample working (php) and non-working (html) URIs, please.
|
| Back to Top |
|
| |
seelemann Newbie

Joined: 25 June 2009
Online Status: Offline Posts: 4
|
| Posted: 28 June 2009 at 2:34pm | IP Logged
|
|
|
Well I've renamed the httpd.ini, so the html works.
http://deheerenvanaemstel.nl/index.html is html. The http://deheerenvanaemstel.nl/index.php doens't show.
If I name the httpd.ini correct, the php works and the html doesn't show.
The php is form my drupal install.
|
| Back to Top |
|
| |
Lexey Moderator Group

Joined: 15 August 2002 Location: Russian Federation
Online Status: Offline Posts: 8119
|
| Posted: 29 June 2009 at 6:17am | IP Logged
|
|
|
Try to add the following rule just after the "
# Make URLs sane" line:
RewriteRule [^.?]+\.html(?:\?.*)? $0 [I,L]
|
| Back to Top |
|
| |
seelemann Newbie

Joined: 25 June 2009
Online Status: Offline Posts: 4
|
| Posted: 29 June 2009 at 8:20am | IP Logged
|
|
|
Thanks, I tried it but it doesn't seem to work. Is there something else I can do to make it work?
|
| Back to Top |
|
| |
Lexey Moderator Group

Joined: 15 August 2002 Location: Russian Federation
Online Status: Offline Posts: 8119
|
| Posted: 30 June 2009 at 5:55am | IP Logged
|
|
|
Show a new httpd.ini (with the given rule), a non-working test URL and a corresponding IIS log record, please.
|
| Back to Top |
|
| |
seelemann Newbie

Joined: 25 June 2009
Online Status: Offline Posts: 4
|
| Posted: 01 July 2009 at 9:49am | IP Logged
|
|
|
new httpd.ini (with the given rule):
[ISAPI_Rewrite] # Accept a url with the following directories and pass them through unchanged. RewriteRule /(?:misc|files|modules|themes|sites|uploads)/(.*) $0 [I,L]
# Make URLs sane RewriteRule /cron\.php $0 [I,L] RewriteRule /index\.php.* $0 [I,L] RewriteRule /update\.php.* $0 [I,L] RewriteRule /xmlrpc\.php $0 [I,L] RewriteRule [^.?]+\.html(?:\?.*)? $0 [I,L]
# deactivate following line if "robotstxt" module is installed #RewriteRule /robots\.txt.* $0 [I,L]
RewriteRule /(.*)\?(.*) /index.php\?q=$1&$2 [I,L] RewriteRule /(.*) /index.php\?q=$1 [I,L]
a non-working test URL: http://www.deheerenvanaemstel.nl/index.html
a corresponding IIS log record I don't know what that is and where I can find it. Looked it op with google without result. What do you mean with it?
|
| Back to Top |
|
| |
Lexey Moderator Group

Joined: 15 August 2002 Location: Russian Federation
Online Status: Offline Posts: 8119
|
| Posted: 02 July 2009 at 5:47am | IP Logged
|
|
|
Config looks fine.
Quote:
| I don't know what that is and where I can find it. |
|
|
Read IIS documentation about logging. By default IIS log files are being stored in the %SISTEM32%\Log directory.
|
| Back to Top |
|
| |