Skip to main content

htaccess 301 Redirect Guide

htaccess 301 Redirect Guide

Handy guide from the team at Sitepoint…

http://www.sitepoint.com/the-missing-guide-301-redirects-for-mac-and-pc/

Update

I kept finding the old page would appear at the end of the new page URL as a query string... which was annoying... so after some digging I found that this worked.

RewriteRule ^oldpage.html.*$ http://www.domainname.com/newpage.html? [R=301,L] 

This was found here on the Biostall site.

Main Category
  • HTML and CSS
  •  
 
Jon Moore

Search form

Jon Moore

Tips 'n' Snips

 
  • Home
  • General
  • Drupal
    • Drupal 6
    • Drupal 7
    • Module Building
  • HTML & CSS
  • Javascript
  • jQuery
  • PHP
    • CodeIgniter
    • Handy Functions
    • MySQL
  • WordPress
  • About

BBC Technology News

  • General election 2019: Reddit says UK-US trade talks document leak 'linked to Russia'
  • 'How smart home tech helps me live independently'
  • NHS e-health systems 'risk patient safety'
  • General election 2019: Labour pledges to electrify UK bus fleet
  • Sweden's Ericsson to pay over $1bn to settle US corruption probe
More

Sitepoint

  • The Real Future of Remote Work is Asynchronous
  • 7 Ways Developers Can Contribute to Climate Action
  • How to Divert Traffic Using IP2Location in a Next.js Website
  • 10 Zsh Tips & Tricks: Configuration, Customization & Usage
  • Building a Habit Tracker with Prisma, Chakra UI, and React
More

Heart Internet

  • Sponsor Neil Hunter’s amazing Antarctic expedition – for Diabetes UK
  • 15 web design books of 2019 that you should read
  • 12 podcasts for every creative person’s commute
  • Ten TED Talks every designer and web creative should watch before 2019 is over
  • The rise of the robots: Will AI take over graphic design?
More
 

Backend Coders

  • PHP
  • Handy PHP Functions
  • PHP MySQL

Frontend Coders

  • HTML & CSS
  • jQuery
  • Javascript

CMS/CMF Systems

  • Drupal
  • Drupal 6 Specific
  • Drupal 7 Specific
  • Drupal Module Building
  • WordPress

About

  • Home
  • About
 

© Jon Moore 2019

All stock images are from www.istockphoto.com