{"id":967,"date":"2010-02-12T14:25:17","date_gmt":"2010-02-12T19:25:17","guid":{"rendered":"http:\/\/mattclare.ca\/blog\/?p=967"},"modified":"2010-02-12T14:25:17","modified_gmt":"2010-02-12T19:25:17","slug":"updated-url","status":"publish","type":"post","link":"https:\/\/mattclare.ca\/blog\/2010\/02\/12\/updated-url\/","title":{"rendered":"Updated URL"},"content":{"rendered":"<p>I changed the URL of my blog!<\/p>\n<p>It all started with <a href=\"http:\/\/mattclare.ca\/wordpress\">mattclare.ca\/wordpress<\/a> because that&#8217;s the software I chose to use to use back when I wanted to try this blogging thing out in 2004.\u00c3\u201a\u00c2\u00a0 Shortly after that I regretted the choice (or lack there of) of the url <a href=\"http:\/\/mattclare.ca\/wordpress\">mattclare.ca\/wordpress<\/a>.\u00c3\u201a\u00c2\u00a0 A much better choice would have been <a href=\"http:\/\/mattclare.ca\/blog\">mattclare.ca\/blog<\/a><\/p>\n<p>It took a lot of work to get the pretty URLs working, plus there&#8217;s the issue of visitors to my blog and search engines still having the old URLs.\u00c3\u201a\u00c2\u00a0 Because of this I was hesitant to change the URL, but today after a lot of research and modelling, I finally switched the URL.\u00c3\u201a\u00c2\u00a0 I had been testing redirecting <a href=\"http:\/\/mattclare.ca\/blog\">\/blog<\/a> to <a href=\"http:\/\/mattclare.ca\/wordpress\">\/wordpress<\/a> since I re-did the main page of my website, but\u00c3\u201a\u00c2\u00a0 today I took the big plunge.<\/p>\n<p>The most important thing was to setup the redirect via the Apache web server I use in a way that preserved my Google ranking.\u00c3\u201a\u00c2\u00a0 The trick (<a href=\"http:\/\/www.google.com\/support\/webmasters\/bin\/answer.py?hl=en&amp;answer=93633\">according to Google<\/a>) is to send the 301 header with the redirect.<\/p>\n<p>The &#8220;httpd.conf&#8221; config line was<\/p>\n<pre>RewriteRule \/wordpress(.*) \/blog$1 [R=301,NC,L]<\/pre>\n<p>Please let me know if you see anything that doesn&#8217;t work anymore!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I changed the URL of my blog! It all started with mattclare.ca\/wordpress because that&#8217;s the software I chose to use to use back when I wanted to try this blogging thing out in 2004.\u00c3\u201a\u00c2\u00a0 Shortly after that I regretted the choice (or lack there of) of the url mattclare.ca\/wordpress.\u00c3\u201a\u00c2\u00a0 A much better choice would have&hellip; <a class=\"continue\" href=\"https:\/\/mattclare.ca\/blog\/2010\/02\/12\/updated-url\/\">Continue Reading<span> Updated URL<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[4,1,18,44],"tags":[],"_links":{"self":[{"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/posts\/967"}],"collection":[{"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/comments?post=967"}],"version-history":[{"count":2,"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/posts\/967\/revisions"}],"predecessor-version":[{"id":969,"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/posts\/967\/revisions\/969"}],"wp:attachment":[{"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/media?parent=967"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/categories?post=967"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mattclare.ca\/blog\/wp-json\/wp\/v2\/tags?post=967"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}