Urgent - Please answer this question on database name and host name

Discussion in 'MySQL' started by chillingbreeze, Sep 3, 2008.

  1. #1
    I'm installing a script and it is asking these fields to enetr:

    Database host -

    Database name -

    Database user -

    password

    **

    I used "localhost" as database host but it is not accepting :(. How can I locate the host name that goes correct

    Same way, I created a database name through mySQL, I hope it'd work but main issue is thise host name..

    It'd be a great favor from anybody who answers..

    Many Thanks
     
    chillingbreeze, Sep 3, 2008 IP
  2. pubdomainshost.com

    pubdomainshost.com Peon

    Messages:
    1,277
    Likes Received:
    21
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Where is your site hosted, is it on your own machine or on the network with a web hosting company.

    If it is your machine you may type in cmd:/> hostname {this would give you your computer name}
    If it is with a web hosting company, read their documents - they would mention the appropriate connection string to allow you to connect to database.

    HTH
     
    pubdomainshost.com, Sep 3, 2008 IP
  3. chillingbreeze

    chillingbreeze Well-Known Member

    Messages:
    1,075
    Likes Received:
    65
    Best Answers:
    0
    Trophy Points:
    130
    #3
    Hey Guys... I I got the answer :) Thanks for help phpdomainhost.com :)
     
    chillingbreeze, Sep 3, 2008 IP
  4. justinlorder

    justinlorder Peon

    Messages:
    4,160
    Likes Received:
    61
    Best Answers:
    0
    Trophy Points:
    0
    #4
    refer to wordpress typical setting

    define('DB_NAME', 'wp2'); // The name of the database
    define('DB_USER', 'admin'); // Your MySQL username
    define('DB_PASSWORD', 'admin'); // ...and password
    define('DB_HOST', 'localhost'); // 99% chance you won't need to change this value
    define('DB_CHARSET', 'utf8');
    define('DB_COLLATE', '');

    In most case, you should quote the content you filled in.

    I guess you are a newbie to php N mysql. You will soon get to know it. It is easy.
     
    justinlorder, Sep 3, 2008 IP