wp admin - Launch wordpress site to local computer from live website backed-up

admin2025-06-02  2

A previous developer has created a wordpress site in the live server. Now after seeing the live website, it caught my attention that the website plugins, same with the theme, were buggy due to long term no update. I tried backing up the live then edit it to my local computer. What I did was,

-export the db then import it to myphpadmin 
-download the website using filezilla then install it to htdocs in drive c.
-tried configuring the db wp-options siteurl and home to localhost/main

The tutorial for what I did above can be found here.

Now the website is in my local computer. The next problem is that I can't seem to connect to wp-login.php. Every time I type localhost/main/wp-login the error, Object not found! returns. If i make it to localhost/main/wp-login.php or localhost/main/wp-admin, these errors pop-up

Warning: Cookie paths cannot contain any of the following ',; \t\r\n\013\014' in C:\xampp\htdocs\main\wp-login.php on line 446

Warning: Illegal string offset 'remember' in C:\xampp\htdocs\main\wp-includes\user.php on line 41

Warning: Cannot assign an empty string to a string offset in C:\xampp\htdocs\main\wp-includes\user.php on line 41

Warning: Illegal string offset 'user_login' in C:\xampp\htdocs\main\wp-includes\user.php on line 56

Fatal error: Uncaught Error: Cannot create references to/from string offsets in C:\xampp\htdocs\main\wp-includes\user.php:56 Stack trace: #0 C:\xampp\htdocs\main\wp-login.php(806): wp_signon('', '') #1 {main} thrown in C:\xampp\htdocs\main\wp-includes\user.php on line 56

What is it the problem here? Thanks in advance.

A previous developer has created a wordpress site in the live server. Now after seeing the live website, it caught my attention that the website plugins, same with the theme, were buggy due to long term no update. I tried backing up the live then edit it to my local computer. What I did was,

-export the db then import it to myphpadmin 
-download the website using filezilla then install it to htdocs in drive c.
-tried configuring the db wp-options siteurl and home to localhost/main

The tutorial for what I did above can be found here.

Now the website is in my local computer. The next problem is that I can't seem to connect to wp-login.php. Every time I type localhost/main/wp-login the error, Object not found! returns. If i make it to localhost/main/wp-login.php or localhost/main/wp-admin, these errors pop-up

Warning: Cookie paths cannot contain any of the following ',; \t\r\n\013\014' in C:\xampp\htdocs\main\wp-login.php on line 446

Warning: Illegal string offset 'remember' in C:\xampp\htdocs\main\wp-includes\user.php on line 41

Warning: Cannot assign an empty string to a string offset in C:\xampp\htdocs\main\wp-includes\user.php on line 41

Warning: Illegal string offset 'user_login' in C:\xampp\htdocs\main\wp-includes\user.php on line 56

Fatal error: Uncaught Error: Cannot create references to/from string offsets in C:\xampp\htdocs\main\wp-includes\user.php:56 Stack trace: #0 C:\xampp\htdocs\main\wp-login.php(806): wp_signon('', '') #1 {main} thrown in C:\xampp\htdocs\main\wp-includes\user.php on line 56

What is it the problem here? Thanks in advance.

Share Improve this question edited Mar 11, 2019 at 8:08 fuxia 107k39 gold badges255 silver badges461 bronze badges asked Mar 11, 2019 at 2:20 marvin castromarvin castro 354 bronze badges 3
  • Maybe the wp-config.php has some weird entries. Check that first, the other errors are probably just side effects. – fuxia Commented Mar 11, 2019 at 8:11
  • @fuxia I already tried changing the db and it works then changed to what I needed then proceeded to the error again. – marvin castro Commented Mar 11, 2019 at 8:18
  • 1 What version of PHP is your live running, compaared to that on your dev box? – Kinnectus Commented Mar 11, 2019 at 14:02
Add a comment  | 

1 Answer 1

Reset to default -1

You can use the same domain name for your site if you edit your local 'hosts' file to point the domain name to the IP address of your local server. That will override DNS lookup for the domain name.

I'd first ensure that the wp-options table has the correct URLs (two places). Then I'd temporarily disable all the plugins by renaming the local plugin folder to something else. You could also rename the active theme's folder to something else,so that one of the 'twenty' themes will be used.

The intent of all that is to bring the installation to a base level. Once you get the base level working, then start adding themes and plugins back. And update everything. (Also ensure your local PHP version is 7.x.)

转载请注明原文地址:http://conceptsofalgorithm.com/Algorithm/1748820584a313999.html

最新回复(0)