{"id":4993,"date":"2020-06-11T11:30:56","date_gmt":"2020-06-11T11:30:56","guid":{"rendered":"https:\/\/davelevy.info\/wiki\/?p=4993"},"modified":"2023-01-21T19:11:15","modified_gmt":"2023-01-21T19:11:15","slug":"this-site-moving-home","status":"publish","type":"post","link":"https:\/\/davelevy.info\/wiki\/this-site-moving-home\/","title":{"rendered":"This site, moving home"},"content":{"rendered":"<p>I have finally moved this wordpress wiki into the davelevy.info domain from its historic site at wiki.davelevy.info; it&#8217;s now at .\/wiki to be precise. Here&#8217;s how I did it. &#8230;<\/p>\n<p><!--more--><\/p>\n<h3>How to move a wordpress site from a sub domain to domain hosted folder name.<\/h3>\n<ol>\n<li>Use <code>cd ..\/oldwiki; find . | cpio -pvdum ..\/next\/wiki<\/code> to move the old instance to the new location<\/li>\n<li>Change the settings page<\/li>\n<li>Amend the redirects file, <code>Redirect 301 \/ https:\/\/davelevy.info\/wiki\/<\/code><\/li>\n<li>I examined and amended my version of header.php which had hardcoded locations to implement the button menu at the top of the page.<\/li>\n<li>I installed really simple sssl, to deal with the hardcoded images at http and reinstalled the header image, the former may have been overkill.<\/li>\n<li>I then wrote some SQL, which I ran against the blog posts table to replace the content enclosed old URLs. I used the SQL REPLACE function.<\/li>\n<\/ol>\n<p>This was piss easy, why has it taken me so long?<\/p>\n<p>See also:<\/p>\n<blockquote class=\"wp-embedded-content\" data-secret=\"lGvsBsKvfc\"><p><a href=\"https:\/\/davelevy.info\/wiki\/moving-this-wordpress-url-and-domain\/\">Moving this wordpress url and domain<\/a><\/p><\/blockquote>\n<p><iframe loading=\"lazy\" class=\"wp-embedded-content\" sandbox=\"allow-scripts\" security=\"restricted\" style=\"position: absolute; clip: rect(1px, 1px, 1px, 1px);\" title=\"&#8220;Moving this wordpress url and domain&#8221; &#8212; davelevy . info \/ wiki\" src=\"https:\/\/davelevy.info\/wiki\/moving-this-wordpress-url-and-domain\/embed\/#?secret=LqOqnpnIN2#?secret=lGvsBsKvfc\" data-secret=\"lGvsBsKvfc\" width=\"600\" height=\"338\" frameborder=\"0\" marginwidth=\"0\" marginheight=\"0\" scrolling=\"no\"><\/iframe><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I have finally moved this wordpress wiki into the davelevy.info domain from its historic site at wiki.davelevy.info; it&#8217;s now at .\/wiki to be precise. Here&#8217;s how I did it. &#8230;<\/p>\n","protected":false},"author":1,"featured_media":2413,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":"","_share_on_mastodon":"0"},"categories":[3,584],"tags":[917,576,122,911,28],"class_list":["post-4993","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technology","category-wordpress-technology","tag-admin","tag-blogging","tag-dns","tag-technology","tag-wordpress"],"share_on_mastodon":{"url":"","error":""},"jetpack_featured_media_url":"https:\/\/davelevy.info\/wiki\/wp-content\/uploads\/2015\/01\/housebuilding.png","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/posts\/4993","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/comments?post=4993"}],"version-history":[{"count":1,"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/posts\/4993\/revisions"}],"predecessor-version":[{"id":7051,"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/posts\/4993\/revisions\/7051"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/media\/2413"}],"wp:attachment":[{"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/media?parent=4993"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/categories?post=4993"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/davelevy.info\/wiki\/wp-json\/wp\/v2\/tags?post=4993"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}