Results 1 to 2 of 2

Thread: PHP Site - Setting up DB with XAMPP/DW CS4

  1. #1
    Join Date
    Jun 2012
    Posts
    15

    Question PHP Site - Setting up DB with XAMPP/DW CS4

    Hello,

    I've setup a local copy of a php site in DW cs4. I have XAMPP installed and working (used a small test site to verify everything is working). I downloaded a copy of the site's DB and imported it into XAMPP and it seems to work... I took some SQL queries from the code of the site and ran them directly from phpMyAdmin and got results from them. I went into DW and set up a DB connection and when I test the connection (test button) it says the connection was made successfully. When I try to 'live view' the local copy of index.php I get a blank page with a message: "Could not connect to mysql. Please check your database settings." I also found where this message is originating from in config.php... there is an if statement that tests the connection:

    if (!$conn->Connect($DBHOST, $DBUSER, $DBPASSWORD, $DBNAME) ) {
    echo 'error here';
    die();

    I know the DB name is the same, I made sure to import it using the exact same name. When I set up the db connection in DW I used the user root and the pw that goes with that, but the site doesn't contain that info.

    Where would I find out where the site specifies user and pw for the DB?

    What is the DBHOST?


    Thanks for any help you can provide.

    Kirk

  2. #2
    Join Date
    Jun 2012
    Posts
    15
    DBHOST was localhost
    user and pw specified in config.local.php

    Got all that straightened out, but now more issues. When I try to view index.php in a browser, I get a blank page (in FF and Chrome - in IE I'm getting a HTTP 500 error. I have read that there are some logs in XAMPP that should detail what happened to cause the error... anyone know where this error log would be?

Similar Threads

  1. XAMPP - Cannot load PHP
    By icu222much in forum Client & Server Side Scripting (PHP, ASP, JavaScript)
    Replies: 1
    Last Post: 25 May 2011, 11:16 AM
  2. Is it possible that IIS, Xampp that consist of mysql,apache and php in window server
    By newphpbees in forum Client & Server Side Scripting (PHP, ASP, JavaScript)
    Replies: 0
    Last Post: 29 Nov 2010, 06:59 PM
  3. Replies: 1
    Last Post: 05 Aug 2010, 03:50 PM
  4. need Help on Php and Dreaweaver CS4 Pleaseeeeeeeeeeee
    By nextdreamnet in forum Client & Server Side Scripting (PHP, ASP, JavaScript)
    Replies: 1
    Last Post: 19 Oct 2009, 06:40 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •