PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Forums Hébergement > Forum Serveur - Sécurité et techniques > alt.apache.configuration > How to list a directory if .htaccess redirect is present?
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
alt.apache.configuration Apache web server configuration issues.

How to list a directory if .htaccess redirect is present?

Réponse
 
LinkBack Outils de la discussion
Vieux 12/10/2006, 10h30   #1
Howie
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut How to list a directory if .htaccess redirect is present?

Hi All,

I've spent hours trawling around google to find a solution to
this:

I have a redirect in my top-level web directory which says this:

AllowOverride All
Redirect / http://www.pontinshistory.co.uk
Redirect /index.htm/ http://www.pontinshistory.co.uk

However, I want my server to list files in a lower directory to
allow downloads. So I have made a sub-directory called
"downloads" and placed a new .htaccess file in it containing the
following:

RewriteEngine on
Options +Indexes
IndexOptions +FancyIndexing

However, when I try to access www.pontinshistory.co.uk/downloads/
I get a 500 server error page.

Any ideas? I would be really gratetful!

Regards,

Howard.
--
Pontins History E-Mail: usenet@pontinshistory.co.uk
Please visit www.pontinshistory.co.uk
Skype ID: howie10
Skype phone: 0161 408 0894. Call this number and I will answer it at my PC. (If I'm not there you can leave a message) See www.skype.com.
Howard Coakley
  Réponse avec citation
Vieux 12/10/2006, 11h26   #2
Howie
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: How to list a directory if .htaccess redirect is present?

On Thu, 12 Oct 2006 13:41:10 +0200, Davide Bianchi
<davideyeahsure@onlyforfun.net> wrote:

|> AllowOverride All
|> Redirect / http://www.pontinshistory.co.uk
|> Redirect /index.htm/ http://www.pontinshistory.co.uk
|
|The second one is already redundant, since the first one will bump
|everything away.

OK. Removed that then!

|> However, I want my server to list files in a lower directory to
|> allow downloads.
|
|I'm not enterily sure if it's possible, since the first one will already
|redirect you when you hit the root dir.

Ahh. I thought that If I actually tried to navigate directly to
the /downloads/ directory, the .htaccess in it would override the
one in a higher level.

|> RewriteEngine on
|
|?? why ?

Erm.. not sure. I though it was needed to allow the lower-level
file to be actioned.

|> However, when I try to access www.pontinshistory.co.uk/downloads/
|> I get a 500 server error page.
|
|And in the error log ?
|
Sorry, don't have access to an error log. This is an externally
hosted web site.

Howard.


--
Pontins History E-Mail: usenet@pontinshistory.co.uk
Please visit www.pontinshistory.co.uk
Skype ID: howie10
Skype phone: 0161 408 0894. Call this number and I will answer it at my PC. (If I'm not there you can leave a message) See www.skype.com.
Howard Coakley
  Réponse avec citation
Vieux 12/10/2006, 12h41   #3
Davide Bianchi
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: How to list a directory if .htaccess redirect is present?

On 2006-10-12, Howie <to.reply.pls.see.sig@end.of.message.com.invalid > wrote:
> I have a redirect in my top-level web directory which says this:
>
> AllowOverride All
> Redirect / http://www.pontinshistory.co.uk
> Redirect /index.htm/ http://www.pontinshistory.co.uk


The second one is already redundant, since the first one will bump
everything away.

> However, I want my server to list files in a lower directory to
> allow downloads.


I'm not enterily sure if it's possible, since the first one will already
redirect you when you hit the root dir.

> RewriteEngine on


?? why ?

> However, when I try to access www.pontinshistory.co.uk/downloads/
> I get a 500 server error page.


And in the error log ?

Davide

--
One distinguishing characteristic of BOFHen is attention deficit disorder.
Put me in front of something boring and I can find a near-infinite number
of really creative ways to bugger off.
-- ADB
  Réponse avec citation
Vieux 12/10/2006, 13h34   #4
Davide Bianchi
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: How to list a directory if .htaccess redirect is present?

On 2006-10-12, Howie <to.reply.pls.see.sig@end.of.message.com.invalid > wrote:
>|> However, when I try to access www.pontinshistory.co.uk/downloads/
>|> I get a 500 server error page.
>|
>|And in the error log ?
>|
> Sorry, don't have access to an error log. This is an externally
> hosted web site.


Well, ask your ISP to check it, because an 'internal server error' could
mean anything, could be some module acting up or a problem in the config
file.

Davide

--
A Linux machine! because a 486 is a terrible thing to waste!
  Réponse avec citation
Vieux 12/10/2006, 18h57   #5
Howie
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: How to list a directory if .htaccess redirect is present?

On Thu, 12 Oct 2006 14:34:14 +0200, Davide Bianchi
<davideyeahsure@onlyforfun.net> wrote:

|> Sorry, don't have access to an error log. This is an externally
|> hosted web site.
|
|Well, ask your ISP to check it, because an 'internal server error' could
|mean anything, could be some module acting up or a problem in the config
|file.
|
Hi. I'm having problems persuading my ISP to send me the error
log. Is there a chance that someone here knows if it's possible
to bypass the top-level .htaccess redirect catch-all in order to
allow a sub-directory to be accessed (and show an index)?

--
Pontins History E-Mail: usenet@pontinshistory.co.uk
Please visit www.pontinshistory.co.uk
Skype ID: howie10
Skype phone: 0161 408 0894. Call this number and I will answer it at my PC. (If I'm not there you can leave a message) See www.skype.com.
Howard Coakley
  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 11h57.


Édité par : vBulletin® version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,12904 seconds with 13 queries