- This topic has 7 replies, 2 voices, and was last updated 5 years, 12 months ago by Tom.
December 3, 2014 at 1:23 pm #51106Maarten
Help! What happened?
Today I moved my website to the root directory of my website,
all was working fine. But all at once my layout got lost and I cannot acces wp-admin anymore.
Is my database down? How would I be able to reset this?
Great! Good start for my website 😉
Thanks for the help!December 3, 2014 at 1:24 pm #51107Maarten
PS: my website link is http://www.deheuvel.beDecember 3, 2014 at 1:25 pm #51108TomLead DeveloperLead Developer
Before moving your website to the root directory, did you change your Site URL and Home URL in “Settings > General”?
If not, you’ll have to set them either through the database, or like this: http://codex.wordpress.org/Changing_The_Site_URL
Set the Site URL to the new URL (since you switched directories) – and you should be good to go.
Also, you may need to replace URLs within your content to the new URL – I suggest this plugin: https://wordpress.org/plugins/velvet-blues-update-urls/
Hope this helps 🙂December 3, 2014 at 1:29 pm #51109Maarten
Weird thing is I DID all these things! Everything was fine at first but after an hour or so everything got lost? And I didn’t change anything in settings, only thing I was doing was changing my settings in Google Analytics?December 3, 2014 at 1:31 pm #51110TomLead DeveloperLead DeveloperDecember 3, 2014 at 1:34 pm #51111Maarten
Weird thing is everything was working correctly for more than one hour! Then I started editing my settings in Google Analytics and everything went wrong? Is it possible my wordpress just cannot acces the database at the moment?December 3, 2014 at 1:42 pm #51116Maarten
Everything fixed 🙂
I know where I went wrong: while changing for the first time I did something wrong and had to undo my actions with following code:
<blockquote>If You Have Accidentally Changed your WordPress Site URL Suppose you accidentally changed the URIs where you cannot move the files (but can still access the login page, through a redirection or something). wp-login.php can be used to (re-)set the URIs. Find this line: require( dirname(__FILE__) . '/wp-load.php' ); and insert the following lines below: //FIXME: do comment/remove these hack lines. (once the database is updated) update_option('siteurl', 'http://your.domain.name/the/path' ); update_option('home', 'http://your.domain.name/the/path' );</blockquote>
And I forgot to remove this line 🙂 probably after accessing wp-login, it changed directories again. I’m sorry for my hysterical reaction 🙂December 3, 2014 at 2:06 pm #51128
- You must be logged in to reply to this topic.