I tried this...now I get a 404 error.  It was working with the two
blocks.  Weird.

When I remove the .htaccess file within /grades/csv/ it works.  The
only problem is that we need that password protection...

On Apr 18, 8:16 pm, "b logica" <[EMAIL PROTECTED]> wrote:
> You shouldn't use 2 blocks like that. Try this:
>
> <IfModule mod_rewrite.c>
>    RewriteEngine On
>    RewriteBase /
>    RewriteRule ^/grades - [L]
>    RewriteRule ^$ app/webroot/    [L]
>    RewriteRule (.*) app/webroot/$1 [L]
> </IfModule>
>
> On Fri, Apr 18, 2008 at 4:15 PM, Jon <[EMAIL PROTECTED]> wrote:
>
> >  I have CakePHP installed, and naturally it uses mod_rewrite to make
> >  the URLs clean.  I made a modification to the htaccess file to allow
> >  me to ignore it for a certain directory.  But then within that
> >  directory, I have an htaccess that defines password protection of that
> >  directory.  Now I get a 404 error.  How can I keep password
> >  protection, but allow it to function as normal?  Here are my files:
>
> >  .htaccess in document root:
> >  <IfModule mod_rewrite.c>
> >     RewriteEngine On
> >     RewriteBase /
> >     RewriteCond %{REQUEST_URI} grades
> >     RewriteRule ^.*$ - [L]
>
> >  </IfModule>
>
> >  <IfModule mod_rewrite.c>
> >    RewriteEngine on
> >    RewriteRule    ^$ app/webroot/    [L]
> >    RewriteRule    (.*) app/webroot/$1 [L]
> >  </IfModule>
>
> >  .htaccess in the directory I want to protect:
> >  AuthType Basic
> >  AuthName "Restricted Area"
> >  AuthUserFile "/home/username/.htpasswds/public_html/grades/csv/passwd"
> >  require valid-user

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to