.htaccess code please

GGG

Joined: 2008-02-16
Posts: 1
Posted: Sat, 2008-02-16 23:10

Hi, I can't get it to work on my local computer, it won't write to my drupal htaccess file. So can someone post the code that goes in the drupal htaccess file please ( path /gallery2 )? For some reason it wrote a new htaccess file to my c drive :/

 
lvthunder

Joined: 2003-09-12
Posts: 808
Posted: Wed, 2008-03-12 19:40

Here's the code mine used.

<IfModule mod_rewrite.c>
    RewriteEngine On

    RewriteBase /

    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d [OR]
    RewriteCond %{REQUEST_FILENAME} gallery\_remote2\.php
    RewriteCond %{REQUEST_URI} !/index\.php$
    RewriteRule .   -   [L]

    RewriteCond %{THE_REQUEST} /d/([0-9]+)-([0-9]+)/([^/?]+)(\?.|\ .)
    RewriteCond %{REQUEST_URI} !/index\.php$
    RewriteRule .   /gallery2/main.php?g2_view=core.DownloadItem&g2_itemId=%1&g2_serialNumber=%2&g2_fileName=%3   [QSA,L]
    RewriteCond %{THE_REQUEST} /key/([^?/]+)(\?.|\ .)
    RewriteCond %{REQUEST_URI} !/index\.php$
    RewriteRule .   /index.php?q=gallery&g2_view=keyalbum.KeywordAlbum&g2_keyword=%1   [QSA,L]
    RewriteCond %{THE_REQUEST} /v/([^?]+)(\?.|\ .)
    RewriteCond %{REQUEST_URI} !/index\.php$
    RewriteRule .   /index.php?q=gallery&g2_path=%1   [QSA,L]
</IfModule>