• Resolved BradTheGeek

    (@bradthegeek)


    Hi.. I am new here, and not a WordPress master, so I hope this is the correct forum.

    I was tasked with building a new website for a person that has multiple business and domains. The site I built was for one of the business, some other domains had sites, others were parked. I built the new site in drupal (sorry). All the sites and domains are (ack) hosted on godaddy. There was one domain that had s broken wordpress installation on one domain, stored in a subfolder. Before launching the new site, as good practice I backed up everything.

    Now, it turns out this other domain, is an important site (even though it was broken before, I cannot prove it to the clients satisfaction).

    It is wordpress, with the cyberchimps business lite theme (which I have used in the past).

    To TS, I installed a fresh wordpress, installed the theme, to a fresh DB in another folder.. it worked. I then pointed this install to the old DB and it no longer works. YOu get some text, by no JS, CSS, or images. The links to images in the generated HTML look correct, but do not work (even though a check site through ftp shows they are, and permissions are fine).

    Any page on the site all produce a WP 404 error, with the menu text (no css or images) and footer all present.

    So, all points to something in the DB being hosed. Not having dug deeply into a wordpress DB (never had to), I have no idea how to fix or pull the old content out. There is not much, but I need to get it working, so any pointers or hints would be appreciated. For any interested the site is http://hhbailenforcement.com/

    Thanks for any help!

Viewing 7 replies - 1 through 7 (of 7 total)
  • It might be a htaccess issue. The old site may have been in the root folder and now you have it http://……/wordpress/ Also you may try outputting the data and do a text search for any referenced to the images folder or CSS folder and see if its pointing to another directory.

    Thread Starter BradTheGeek

    (@bradthegeek)

    Thanks for the feedback. I don’t think it is htaccess. I never moved the site, but I think it was moved at some point and it is a path issue.

    Basic setup is as follows:

    Domain 1 (drupal site, working) path = /

    Domain 2 (hhbailenforcement) path to site = /bail/wordpress

    If you look at the path of a failed image from the resultant HTML in a browser you see something like:
    http://hhbailenforcement.com/wordpress/wp-content/themes/business-lite/images/social/default/facebook.png

    other resources in the page source have similar paths, IE domain/wordpress

    however, the server config already points the site to bail/wordpress so in my mind that means when the HTTP request comes in it is looking for /bail/wordpress/wordpress which is of course incorrect. Not having worked with godaddy hosting before, it seems error logs are turned off, but I have turned them on and will dig through as soon as I can, I expect to see 404’s with incorrect paths like that.

    If I am correct, how do I fix that? Can I run some sort of an update SQL to fix the paths or is there a better fix?

    Thanks again for all the assistance.

    all but one of the dozen errors is with their site jquery libraries. switch to 2012 and see if it’s just the theme

    Hi, I think I might be able to help – sounds like you have not added the correct information for the (old) websites database connection – try this:

    Unzip your backup copy of the site in question onto your computer. Open it up and look for the file called “wp-config.php”. Open up the wp-config file (using “notepad” or better still, “Wordpad”). In it are all the details of the old database….

    Now, got to your server (via cpanel, on your web hosting account) & go to the broken websites (root) folder. Look for the current “wp-config.php” file, and open it up (….right click the file & select “edit” or “code edit” options).

    Go down the items & check that they all match your old backup copy of “wp-config.php”, checking the following:

    – database name
    – database username
    – database password
    – MySQL hostname

    I’m guessing that you’ve inserted the wrong data in one of these, probably database or db username….

    TIP: Another thing to do whilst you are there (& which is important for security) is to insert your unique salt keys (the information on where to get these is listed within the wp-config.php file, just beneath the above items…..).

    Hope this fixes your problem,

    Regards, Karen

    PS: another quick option would be to delete the live database (you can just dump all the tables rather than deleting the complete db) & install the (backup) database again.

    Thread Starter BradTheGeek

    (@bradthegeek)

    wp-config.php is correct. I have even gone so far (see first post) to create, in another folder, a new install of wp and the theme used, with a new database. This works. If I take the new working (albiet with no content) test site and point the wp-config to the old database, it also has the same problems. It is not an authentication error, it is reading some data from the db, eg, the text of the front page is correct, but all links and urls to other resources are incorrect.

    This also tests the version problem, as I have tested with the newest version of the theme.

    As far as deleting the old db and bringing the tables back.. I tried that too.. I pointed the fresh install to its empty db, made sure it was working with the default content. It was. Then I imported the tables from the DB backup to its db, and viola, broken.

    Thread Starter BradTheGeek

    (@bradthegeek)

    I found a solution. The site had been moved, breaking urls. Per moving the moving a WP site doc, I found a couple lines that I added to wp-login that fixed the paths in the DB.

    Thanks all

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Corrupt DB’ is closed to new replies.