Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I wanted to redirect localhost/~mu/ to localhost/~mu/branches_index/ and created a .htaccess file with a Redirect /~mu/ /~mu/branches_index/. That did not work out as expected since it changed every single files, even in other folders.

Then I created an index.php with the simple content of:

<?php
header('location:branches_index/');
?>

The .htaccess file is deleted.

If I now open localhost/~mu/, I end up at:

http://localhost/~mu/branches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.phpbranches_index/index.php

If I open localhost/~mu/index.php, I end up at localhost/~mu/branches_index/.

Rebooting did not help and I am pretty sure the .htaccess there is gone.

How can I fix this?

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

You probably used a permanent redirect which has been cached by your browser, just clear the cache.

share|improve this answer
    
Yep, that explains it. +1 for thinking of the permanent that I forgot. –  queueoverflow Feb 4 '12 at 18:50
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.