Jump to content
xisto Community

.htaccess Help

Recommended Posts

I have seen examples for redirecting one file to another using htaccess, redirecting directory structures and other things. However, I want to redirect a directory of files to one file in the root directory. How do I do this?Bare minimum: Send a HTTP 301 status code and redirect the user to a specific page.Optimal task: Send a HTTP 410 status code for the page/resource that the user is trying to access and then redirect the user to a specific page.How do I do this via htaccess or PHP?

Share this post

Link to post
Share on other sites

I'm sorry but I don't understand what you are saying. Could you please tell me what to put in the .htaccess file?

He just said it.Use this: Redirect ^/*/$ / 301
In the root directory.
Give him credit not me.

Share this post

Link to post
Share on other sites

That code only gave me an internal server error (HTTP 500). I tried 302, 301 and 410 and it still does the same thing.

Do you mean that you really created a working /blafile.php and the 301 redirect does not work, or do you mean that you don't understand the /blafile thing ?

Share this post

Link to post
Share on other sites

This is my .htaccess file:

Redirect /xkingdom http://feral.portal.trap17.com/Redirect ^/wdl/$ /gone.php 301
The first line works, the second line doesn't. It actually returns an Internal Server Error:

Internal Server ErrorThe server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, webmaster@portal.trap17.com and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

I have the gone.php file in the root directory of my subdomain.
Edited by FirefoxRocks (see edit history)

Share this post

Link to post
Share on other sites

htaccess.htaccess Help
I have what I think is some type og bot accessing my website and using a lot of bandwidth.
Here's the bot: dc.73.84ae.Static.Theplanet.Com
I tried blocking this way in htaccess
deny from dc.73.84ae.Static.Theplanet.Com
deny from 73.84.*.*
This a a host and I can't find the IP
Any ideas how to block this ??

-question by Paul K

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.