This forum has been moved here:
Helicon Tech Community Forum

ISAPI_Rewrite 3.0 (Forum Locked Forum Locked)
 Helicon Tech : ISAPI_Rewrite 3.0
Subject Topic: Drupal 7, IIS, Win2k3 and imagecache
Author
Message |
jgionet76
Newbie


Joined: 25 January 2012
Location: Canada
Posts: 3
Posted: 25 January 2012 at 10:39am

Hi,

I've been searching and testing a bunch of solutions to try and get
imagecache working properly under Windows 2003 and IIS6 and I haven't had
much luck.

I have drupal installed in mysite.com/drupal

my /drupal/.htaccess file contains these entries:

Code:

# Helicon ISAPI_Rewrite configuration file
# Version 3.1.0.87

RewriteEngine on

# Modify the RewriteBase if you are using Drupal in a subdirectory or in a
# VirtualDocumentRoot and the rewrite rules are not working properly.
# For example if your site is at http://example.com/drupal uncomment and
# modify the following line:
RewriteBase /drupal
#
# If your site is running in a VirtualDocumentRoot at http://example.com/,
# uncomment the following line:
# RewriteBase /

# Rewrite URLs of the form 'x' to the form 'index.php?q=x'.
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]


my /drupal/sites/default/files/.htaccess contains these lines:

Code:

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteRule ^(.*)$ /index.php?q=sites/default/files/$1 [L,QSA]


When I try and insert any images in any content type I still end up with
broken images. It doesn't seem like imagecache is working properly with
cleanURL.

The error.log only shows this:
Code:
[1/25/2012 11:05:54]
d:\web\wwwroot\drupal\sites\default\files\.htaccess - Loaded
successfully


Everything else seems to be working properly when it comes the rewrite
rules.
Any ideas? Am I missing something?

Thanks
Back to Top
 
Guests
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -160
Posted: 26 January 2012 at 7:36am

Hello,

Just as it is declared in our article, please, make sure you have found the file %PATH_TO_DRUPAL%/sites/default/settings.php, where %PATH_TO_DRUPAL% has been edited with
the following line of code:

Code:
$conf[ 'clean_url' ] = 1;


Regards
Andrew
Back to Top
 
jgionet76
Newbie


Joined: 25 January 2012
Location: Canada
Posts: 3
Posted: 26 January 2012 at 8:39am

AndrushkaUS wrote:
Hello,

Just as it is declared in our article, please, make sure
you have found the file
%PATH_TO_DRUPAL%/sites/default/settings.php, where
%PATH_TO_DRUPAL% has been edited with
the following line of code:

Code:
$conf[ 'clean_url' ] = 1;


Regards
Andrew


I have CleanURL enabled in my Drupal Config. I did
however insert that line you suggested and I still end up
with the same results. Images aren't being created/loaded
when I upload them to be used in my content.

All my other paths such as /admin or /user or
/content/whateverpage all work fine.
Back to Top
 
Guests
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -160
Posted: 27 January 2012 at 3:54am

Well,

What happens is ISAPI_Rewrite also rewrites you images and .css.
The solution - to have all image links as root-relative or absolute. That was the reason for Clean URL to be applied.

This idea might spot come lite on the issue.

Regards
Andrew
Back to Top
 
jgionet76
Newbie


Joined: 25 January 2012
Location: Canada
Posts: 3
Posted: 27 January 2012 at 1:25pm

I found a weird fix to make it work..
I deleted the
%PATH_TO_DRUPAL%/sites/default/files/.htaccess file and
created a folder called the same thing to prevent a new
.htaccess file from being created.

mkdir %PATH_TO_DRUPAL%/sites/default/files/.htaccess

now all works perfectly! For whatever reason.. having a
REAL .htaccess file in that directly doesn't work properly.

weird wild stuff
Back to Top
 

Sorry, you can NOT post a reply.
This forum has been locked by a forum administrator.

Printable version Printable version