[TYPO3] .htaccess & SimulateStaticDocuments creates infinite redirection loops

Lynne Mickley lynne at seasonsforsuccess.com
Tue Jun 13 22:19:14 CEST 2006


Christopher:

Thanks for your quick reply. You're faster than my webhost--and even better,
the problem has been resolved!! Although I'm not exactly sure how...

One of the latest things my webhost's techs did last night was put a copy of
the .htaccess file in the root of my website. Which of course just sent it
reeling back into the redirection loop. You'd think they would've made sure
their "fix" was actually helpful or not, but this is what I've come to
expect from them. Sigh. You'd think *I'd* learn not to beat my head against
their brick wall, asking for help.

Anyway, I disabled *that* .htaccess file when I discovered it this morning.
I originally had the .htaccess file in the /index directory, and still had a
disabled copy there.

So I decided to start with your #1 solution, since it was the easiest. I
deleted the .htaccess file from the root, deleted the .htaccess file from
/index, and copied over a new default .htaccess into /index. I was sure it
wouldn't work, because I *swear* this is exactly the same setup I'd tried
numerous times before, but lo and behold my site is back to normal!! And all
the links are working! I'm not sure why it's working now when it didn't
before, but I'll take it!

I agree that it's odd to have the "root" of Typo3 in /index instead of /.
That's because when I first installed Typo3 on my webhost's old server, it
wouldn't allow me to install to the root. It had to be in a directory. (Or
maybe I was too stupid to figure out how to move it to the root. That's also
possible.) When I recreated the site on the new server (my webhost required
my site be moved but couldn't figure out how to do it themselves) I kept it
in /index because that's what I was used to. I believe I could've installed
it into the root this time, and could move it now, but I've learned in Typo3
(as in life) if it ain't broke, don't fix it. Anyway, that's why I have
http://www.seasonsforsuccess.com/ redirecting to
http://seasonsforsuccess.com/index/.  ;-)

Again, thank you for help. Sometimes all it takes is for someone
knowledgeable to come stand over your shoulder for things to suddenly repair
themselves. I wish you worked for my webhost...

--Lynne

> Hello,
>
> On 6/13/06, Watkins: Seasons For Success <lynne at seasonsforsuccess.com>
wrote:
> > Here's my problem in a nutshell: The standard Typo3 .htaccess file is
> > suddenly causing a redirection loop with my Typo3 root page. The root
page
> > redirects itself to itself to itself, etc....until it eventually times
> > itself out from exhaustion. ;-) If I disable the .htaccess file, the
main
> > page loads and everything *looks* fine, even the link paths. But all the
> > links (those pointing to Typo3 pages) just get redirected back to the
root
> > page. If I disable SimulateStaticDocuments, the resulting links work
fine.
> > If I leave SimulateStaticDocuments enabled and just add the line,
> > "config.simulateStaticDocuments = PATH_INFO", the links also work fine.
But
> > I *really really like* the .html links created by SSD instead and would
like
> > them back!
>
> <big snip>
>
> Nicely asked question...The only thing missing is the .htaccess file,
> but since you've used the default, we can probably figure that out.
>
> The way your site is set up is slightly odd though; why do you have
> the redirect from / to /index/ ? I'm about positive that's the um
> 'root' of your problem if you'll forgive the pun. There are several
> approaches you can take (though they're all about equivalent):
>
> 1. Change the .htaccess file so it's rewriting inside the /index/
> directory; I suspect this is where the loop comes from: if .htaccess
> redirects all requests for non-existent directories and files to
> /index.php and the root of the site redirects everything to /index/
> and .htaccess redirects that back to /index.php...and so on...
>
> 2. Move the site out of /index/ to / This may, in the long run, have
> some seo benefits for you as well.
>
> 3. Have your host point requests for your domain to the /index/ directory.
>
> I'd opt for 2. The usual cautions about backing things up and
> carefully documenting the steps you take so that you can un-do what
> you've done apply here...
>
>
> -Christopher
>




More information about the TYPO3-english mailing list