http-status-code-301

301 Htaccess Redirect Rule

Need help with an 301 htaccess redirect rule doing the following for all the files in these paths: www.name.com/wordA/wordB/* to www.name.com/new_word/wordA/wordB/* we are basically adding "new_word" to the new url string. ...

301 Redirect Rule

Need help with an 301 htaccess redirect rule doing the following: www.name.com/wordA/wordB/* to www.name.com/WordNEW/wordA/wordB/* we are basically adding "WordNew". I have three wordA and five wordB for a total of 15 path variations. ...

Is 301 the correct redirect code for "fake" subdomains?

My site assigns each user a fake subdomain along the lines of http://username.mysite.com/ which redirects to http://mysite.com/shop/username The second link is the one used internally, is assigned as link rel="canonical", and what I want to display in the browser as the correct url, the subdomain is basically just a convenience fo...

301 redirection help on wordpress

Hello all friends, I'm searching for a 301 redirect rules in .htaccess for the last one week. I have visited many similar pages here too. But all are not working for me. So I'm asking help from masters like you. I'm using wordpress blogging platform. Before I was using Joomla and that time so many 404 errors was there on my website. T...

Redirect htaccess Based On Partial Folder Name

I have a set of dated folders I want to move into one container folder. That is 20011104 20011008 will now be in archive/20011104 archive/20011104 is there any way to htaccess redirect these in a few lines, rather than one redirect for each. There are hundreds. Is it possible to do a wildcard like 200* such that all such requests get...

Help with 301 redirect (Simple concept, per directory control)

Hi guys, I'm trying to get a set of 301 redirects working for a client site, and I'm getting a bit stuck. I have about 17 different directories that have .html content fileswhich I am moving across to Wordpress. What I am trying to do is create a simple, single .htaccess file with redirects in that will allow me to redirect all the .ht...

301 redirect from mod_rewrite RewriteMap program

I'm using mod_rewrite's RewriteMap directive to process URLs. My RewriteMap program is a PHP script and everything is running fine. I'm able to map friendly URLs to PHP program + ID. Anyway, what I want to do is return a 301 redirect for certain URLs. For example, if someone puts in the URL: http://www.example.com/directory1 Then I wan...

https 301 errors and SEO

This question is related to a few tools that are returning errors and that I am not sure what to do about them, if anything. At: http://andylangton.co.uk/online-tools/http-status-analyser if I analyze http://drchrono.com I get "Status code is 301. Status is Moved Permanently to https://drchrono.com/." This makes sense but if I then a...

301 Redirect of Static HTML to Dynamic PHP Page

After upgrading our website, many old links that people have in blogs, etc. are now going to our 404 error page. An example is: (using h#p b/c I'm a new user and can't post links) h#p://www.site.com/pressreleases/some_release.html h#p://www.site.com/pressreleases/another_release.html These items are now part of a db-driven site and wo...

PHP 301 Redirect Idea

I posted this earlier http://stackoverflow.com/questions/1915824/301-redirect-of-static-html-to-dynamic-php-page But have a new idea, and am wondering if there are any issues why I should NOT do this... If someone tries to go to a dead page on our site like: (domain)/somepage.html That now exists here: (domain)/dynamic.php?id=1 It...

301 redirect - add a slash for index page

How do you set a 301 redirect in .htaccess to add the forward slash to your document root if someone links to you without it? According to the research I have done most search engines consider the following URL's as two different URL's. mydomain.com (no forward slash) mydomain.com/ (forward slash) I've tried this (plus many others): ...

301 redirects in Grails

I'm currently doing my Grails 301 URL-redirects using the following quite cumbersome "servlet style" method: def action = { ... if (shouldRedirect) { response.status = 301 response.setHeader("Location", "http://url/to/redirect/to.html") render("") return false } ... } Is there any cleaner and more compact Groov...

Issue with redirection of a folder with mod_alias

Another question following on from this thread. The only remaining item that I can't solve is that there is a listing for an now non-existent folder '/team/', but if I add this into my .htaccess file, it breaks all other .htaccess entries for files in that folder, i.e. redirect 301 /team/ /team.html redirect 301 /team/joe_bloggs.htm /t...

How to identify if referrer is a 301 redirect

I'm implementing a slug system for my website at the moment. I plan to redirect invalid slugs to the correct on that is stored in the database. E.g. http://example.com/11/wrong-slug Hit db, check if 11's slug is wrong-slug if not do 301 redirect http://example.com/11/right-slug Detect 301 and inform user that they foll...

Redirect 301 & Mod Rewrite Issues

I have a online store that, for example, is located here: hxxp://domain.com/store/ Within the store directory's .htaccess file I have this: Options +FollowSymlinks RewriteEngine on RewriteBase /store/ RewriteCond %{HTTP_HOST} !^www.domain.com$ RewriteRule ^(.*)$ http://www.domain.com/store/$1 [R=301] RewriteRule ^/?$ directory.php Rewr...

How can I handle HTTP redirects in my Perl application?

I use this Perl subroutine to get a line from a webpage, which I then split to get the information I require to proceed. This has worked for a dozen years. sub capture_line { my $page_to_get = $_[0]; my $host_to_get_text = $_[1]; my $port = 80; my $buf = &HTTPGet($page_to_get, $host_to_get_text, $port); my $image_capture...

Rails redirect_to "www.somewebsite.com" with GET/POST parameters?

Hi, I'm trying to issue a redirect_to in one of my controllers to a fully qualified URL + I want to pass in some parameters In the controller for site A I do: redirect_to: "www.siteB.com/my_controller/my_action?my_parameter=123" Is there a nicer way to do this in rails? ...

301 Redirect with Glassfish

Hi, I'm looking for a way to do a 301 redirect on Glassfish, similar to what you could do with a .htaccess file on Apache by writing something like this: redirect 301 /old/old.htm http://www.mydomain.com/new.htm ...

301 redirect on IBM WCM

On IBMs Web Content Management System how can I setup a 301 redirect, I can't seem to find any information on how to do this. The version of WCM the site is running is 6.0.1.4 ...

htaccess redirect 301

Google says that the content is duplicated www.example.com/pagedcontent/page3 / www.example.com/pagedcontent/page3 I redirected using redirect 301 for each page, but as they are already more than 150 pages would like to use a single instruction in the htaccess. How to do? Please I want to redirect to www.example.com/pagedcontent/pa...