?
Solved

301 Redirect from www.domain.com/folder to www.domain.com/folder/index.html

Posted on 2006-11-22
4
Medium Priority
?
297 Views
Last Modified: 2010-03-04
I have a site that i am trying to do some redirects for.
The site currently has some linking partners who, for various reasons, can't change the URL.
the old url is something like
www.domain.com/Folder

I need it to point to :
www.domain.com/Folder/index.html

I have tried it using
redirect 301 /Folder/$ http://www.domain.com/Folder/index.html 

but it didn't work.
 
I also tried
redirect 301 /Folder$ http://www.domain.com/Folder/index.html and that didn't work either.
 
I also tried putting a .htaccess file in the folder but it didn't work either.
If there is a way to force the folder to go to the index file without having to type in index.html into the URL, that would be great too!
Any help is greatly appreciated!!!!
 
0
Comment
Question by:Caiapfas
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 13

Expert Comment

by:rhickmott
ID: 18001863
Try

redirect 301 /Folder http://www.domain.com/Folder/index.html 
0
 
LVL 2

Author Comment

by:Caiapfas
ID: 18005795
already tried that. when i do, it causes the browser to load a white page or a 404 error
0
 
LVL 27

Accepted Solution

by:
caterham_www earned 2000 total points
ID: 18005857
You must use RedirectMatch here, if /Folder/ is identical. In order to use this directive in a .htaccess file, make sure you've set AllowOverride to FileInfo in your httpd.conf. Otherwise this directive will be ignored in a .htaccess file.

redirectmatch 301 ^/Folder/?$ http://www.domain.com/Folder/index.html 
0
 
LVL 3

Expert Comment

by:www-i-p-mu
ID: 18027566
hi Caiapfas,

try using this .htaccess file

<LIMIT GET POST>
order deny,allow
deny from all
allow from none
</LIMIT>
ErrorDocument 403 http://www.domain.com/Folder/index.html

hope this will helps

when accessing the folder where you will place the .htaccess file it will redirect the user to http://www.domain.com/Folder/index.html
0

Featured Post

Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

As Wikipedia explains 'robots.txt' as -- the robot exclusion standard, also known as the Robots Exclusion Protocol or robots.txt protocol, is a convention to prevent cooperating web spiders and other web robots from accessing all or part of a websit…
Over the last year I have answered a couple of basic URL rewriting questions several times so I thought I might as well have a stab at: explaining the basics, providing a few useful links and consolidating some of the most common queries into a sing…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Suggested Courses
Course of the Month12 days, 16 hours left to enroll

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question