• Brian

    (@summae)


    I’m trying to set up a local development site to test changes to the live remote site using the same database. I’ve found an interesting article in the codex Running_a_Development_Copy_of_WordPress with instructions on how to use it for 2.5. However this involves inserting the hack in wp-includes/options.php which in my clean 2.5.1 build, does not seem to exist as of yet.
    Does anyone know of how to currently use this hack or some other way of running a local testing site off of the same DB as the live site?

Viewing 9 replies - 1 through 9 (of 9 total)
  • MichaelH

    (@michaelh)

    Why not install WordPress locally, then just make a backup of your ‘live’ database and restore it to your test site?

    See:
    Install WordPress Locally

    Thread Starter Brian

    (@summae)

    Ok, I’m still a novice, but I did attempt this, actually before I posted. I installed Apache, PHP, MySQL and phpMyAdmin, and then installed a clean version of wordpress 2.5.1. I then backed up my live db, and imported it into my local DB. Now, I’m thinking because of links recorded in the DB, when I try to bring up my local site, running as a virtualhost, “http://test-awwa/” I am being redirected to the remote site in my browser, “http://aw… .org”, and I’m clueless as to what to do about this. As far as know, Apache is working fine, as well as the rest, because I viewed test pages in my virtualhosts before I installed wordpress, and I used phpMyAdmin to create the DB for wordpress; wordpress seemed to be running fine before I updated the DB.

    Thread Starter Brian

    (@summae)

    Well I guess for now I’m just going to run an unrelated sandbox locally, but I really would like to know either:

      How to implement the codex article listed above, “Running a Development Copy of WordPress”, in 2.5.1
      How to mirror the DB locally and still be able to get to my local test site.

    Just haven’t gotten a response yet regarding either of these possibilites.
    Thanks for your time in advance.

    benkepes

    (@benkepes)

    2.5.1 doesn’t seem to have wpincludes/options so it seems the hack is broken for 2.5.1

    any other ideas???????????

    Thread Starter Brian

    (@summae)

    None at all, that’s why I’m asking πŸ™‚ .

    benkepes

    (@benkepes)

    ok – sorted – go to wp_options in phpmyadmin/wordpress change site url and home to http://localhost/wordpress

    that should work

    Thread Starter Brian

    (@summae)

    Thanks, will try it tomorrow.

    Thread Starter Brian

    (@summae)

    Hi, that seems to have worked. The one niggling problem I had was the ‘secret key’ inserted in wp-conf.php Before the wordpress site is created. Since I’d already tried to set my local site up, I had to drop the tables in my DB and reinstall wordpress using the same key, which I got from the live site’s DB on line 61 of wp-options, “secret”. Now I’m in the midst of moving the live site’s extra plugins and themes and such over, as well as doing a new restore of the DB, but seems to be going fine.

    Thread Starter Brian

    (@summae)

    Ok, wordpress is now up and running locally, but somehow the permalinks are not working. I can get to the homepage, but no local links from there, just get 404 url not found error. Yet, wp-admin is working, and all posts and pages are listed under manage; I can even edit and view them through the admin panel, but again, the links to these pages posts are not working on the local site.

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Setting up a development / testing environment’ is closed to new replies.