[SOLVED] URL Rewrite Error
doomdead
Joined: 2003-04-06
Posts: 174 |
Posted: Tue, 2006-03-07 19:04 |
I have Gallery 2.1 rc1 on IIS6 When I enable url rewrite it appears to function correctly, except for the breadcrumb. any ideas on how to make this work so i can keep it enabled? thanks. |
|
Posts: 389
Can you please post the Gallery section of your httpd.ini file? Thanks.
Posts: 174
# BEGIN Gallery 2 Url Rewrite section (GalleryID: D:\Inetpub\wwwroot\gallery2)
# Do not edit this section manually. Gallery will overwrite it automatically.
RewriteCond Host: www\.robplatt\.com
RewriteRule /modules/rewrite/data/isapi_rewrite/Rewrite.txt /modules/rewrite/data/isapi_rewrite/Works.txt [O]
RewriteCond Host: www\.robplatt\.com
RewriteRule /c/view/([0-9]+).html /main.php?g2_view=comment.ShowAllComments&g2_itemId=$1 [N]
RewriteCond Host: www\.robplatt\.com
RewriteRule /c/view/([0-9]+).html\?(.*) /main.php?g2_view=comment.ShowAllComments&g2_itemId=$1&$2 [N]
RewriteCond Host: www\.robplatt\.com
RewriteRule /c/add/([0-9]+).html /main.php?g2_view=comment.AddComment&g2_itemId=$1 [N]
RewriteCond Host: www\.robplatt\.com
RewriteRule /c/add/([0-9]+).html\?(.*) /main.php?g2_view=comment.AddComment&g2_itemId=$1&$2 [N]
RewriteCond Host: www\.robplatt\.com
RewriteRule /d/([0-9]+)-([0-9]+)/([^\/\?]+) /main.php?g2_view=core.DownloadItem&g2_itemId=$1&g2_serialNumber=$2&g2_fileName=$3 [N]
RewriteCond Host: www\.robplatt\.com
RewriteRule /d/([0-9]+)-([0-9]+)/([^\/\?]+)\?(.*) /main.php?g2_view=core.DownloadItem&g2_itemId=$1&g2_serialNumber=$2&g2_fileName=$3&$4 [N]
RewriteCond Host: www\.robplatt\.com
RewriteRule /v/([^?]+) /main.php?g2_view=core.ShowItem&g2_path=$1 [N]
RewriteCond Host: www\.robplatt\.com
RewriteRule /v/([^?]+)\?(.*) /main.php?g2_view=core.ShowItem&g2_path=$1&$2 [N]
# END Url Rewrite section
Posts: 389
What happens if you in the last rule remove the escape of '?', like this:
RewriteRule /v/([^?]+)?(.*) /main.php?g2_view=core.ShowItem&g2_path=$1&$2 [N]
Posts: 174
That worked, thanks pelle. So what does this mean? Bug in gallery, bug in the iis urlrewrite plugin? and will i have to fix this everytime i change the urlrewrite options (not that i should need to make many changes)...
Posts: 389
Great, it means that it's a bug in Gallery. The fix should be in the next nightly.
Posts: 32
Hi!
What module are you using for IIS to enable rewrite? Is it some kind of isapi filter? Does it work out of the box with gallery2?
Posts: 389
The URL Rewrite module has ISAPI Rewrite support. If you have ISAPI Rewrite proberly setup on your host it'll most likely work out fo the box with Gallery2.