+ Reply to Thread
Results 1 to 10 of 10

Thread: can anyone help please, cant connect to db

  1. #1
    Member convictor is on a distinguished road
    Join Date
    Dec 2009
    Location
    south africa
    Posts
    35
    Thanks
    1
    Thanked 4 Times in 1 Post
    Rep Power
    0

    can anyone help please, cant connect to db

    i have tried several scripts, the latest i tried now with riderz's simple php forum.
    no matter how i do it, i just cant get scrits to connect to the datbase. i follow instructions to the letter, but to no avail, i added a db user to the db i want to use, edited the files, config etc, with the db username and password, but i just keep on getting erroer
    Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'moboholi_conrad'@'localhost' (using password: YES) in /home/mobiholi/public_html/main_forum.php on line 9
    cannot connect

    should i change in the script where it show localhost to something else? please, i would appreciate it if someone can help me

  2. #2
    Senior Member bOrN2pwn is on a distinguished road bOrN2pwn's Avatar
    Join Date
    Mar 2009
    Location
    South Africa
    Posts
    136
    Thanks
    7
    Thanked 11 Times in 8 Posts
    Blog Entries
    1
    Rep Power
    1

    Are you using a free or paid server that could be your problem.
    WapLive
    Code:
    <?php
    $str = "Hello world. It's a beautiful day.";
    print_r (explode(" ",$str));
    ?>
    






    [Only Registered Users Can See Links Click Here To Register]

    Sites HACKED
    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]

    [Only Registered Users Can See Links Click Here To Register]

  3. #3
    Senior Member bOrN2pwn is on a distinguished road bOrN2pwn's Avatar
    Join Date
    Mar 2009
    Location
    South Africa
    Posts
    136
    Thanks
    7
    Thanked 11 Times in 8 Posts
    Blog Entries
    1
    Rep Power
    1

    Paid server should look like this

    PHP Code:
    $dbname "name_name "//change to your mysql database name
    $dbhost "localhost"//database host name
    $dbuser "name_name2 ";
    $dbpass "123456 "
    Name is whatever you called your databases

    Free Hosting

    PHP Code:
    $dbname "name_name "//change to your mysql database name
    $dbhost "http://sql.yoursqldomain.com "//database host name
    $dbuser "name_name2 ";
    $dbpass "123456"
    Hope you get the picture
    WapLive
    Code:
    <?php
    $str = "Hello world. It's a beautiful day.";
    print_r (explode(" ",$str));
    ?>
    






    [Only Registered Users Can See Links Click Here To Register]

    Sites HACKED
    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]

    [Only Registered Users Can See Links Click Here To Register]

  4. #4
    Member convictor is on a distinguished road
    Join Date
    Dec 2009
    Location
    south africa
    Posts
    35
    Thanks
    1
    Thanked 4 Times in 1 Post
    Rep Power
    0

    [QUOTE=bOrN2pwn;48696]Paid server should look like this

    PHP Code:
    $dbname "name_name "//change to your mysql database name
    $dbhost "localhost"//database host name
    $dbuser "name_name2 ";
    $dbpass "123456 "
    Name is whatever you called your databases

    Free Hosting

    PHP Code:
    $dbname "name_name "//change to your mysql database name
    $dbhost "http://sql.yoursqldomain.com "//database host name
    $dbuser "name_name2 ";
    $dbpass "123456"
    Hope you get the picture[/QUOTE

    im using paid hosting, and the first one you show is how i did it, i even asked the host, and his reply was the same. what freak me out, i tried out some of the scripts one get in fantastico, and it install without any problem, and it work too. i cant even get a online/ hits script to connect. i checked out the php configuration on the cpanel, and i see there global regiter is set to off. can that be the problem? and how can i set it on, cause i see there the server administator can set it to on

  5. #5
    Senior Member huwad is on a distinguished road huwad's Avatar
    Join Date
    Apr 2009
    Posts
    201
    Thanks
    1
    Thanked 8 Times in 4 Posts
    Rep Power
    1

    I think his on paid hosting.. try to go to your mysql databases.. and give permision to access your database

    first you must add user to database


    2nd assign privilege.. better to check all, and its done
    Last edited by huwad; 08-02-10 at 03:41.


    hacking is like sex. you get in, you get out and you pray you left nothing behind.

    Need Cash? [Only Registered Users Can See Links Click Here To Register] ($_$)


    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]

    [Only Registered Users Can See Links Click Here To Register]

    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]

    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]

  6. #6
    Member convictor is on a distinguished road
    Join Date
    Dec 2009
    Location
    south africa
    Posts
    35
    Thanks
    1
    Thanked 4 Times in 1 Post
    Rep Power
    0

    i did that too, yesterday i tried a smf forum, and it auto installed too without problem, and running without problem.
    But stuff that i want to connect dont wanna lol, its really freaking me out

  7. #7
    Senior Member kei_ki7 is on a distinguished road kei_ki7's Avatar
    Join Date
    Jun 2009
    Location
    Philippines
    Posts
    304
    Thanks
    10
    Thanked 3 Times in 3 Posts
    Rep Power
    1

    did you edit the two config.php already?
    Earn Extra Cash ONLINE !!
    [Only Registered Users Can See Links Click Here To Register]

    Make Money Online
    Register here for FREE:
    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]
    [Only Registered Users Can See Links Click Here To Register]

  8. #8
    Member convictor is on a distinguished road
    Join Date
    Dec 2009
    Location
    south africa
    Posts
    35
    Thanks
    1
    Thanked 4 Times in 1 Post
    Rep Power
    0

    Yes i edited the config files on some scripts i wanted to try out, some lava scripts, one toplist, and now the online script, as well as the simple forum that riderz had here in tutorials. Nothing..

  9. #9
    Junior Member ksg91 is on a distinguished road ksg91's Avatar
    Join Date
    Jan 2010
    Posts
    24
    Thanks
    0
    Thanked 1 Time in 1 Post
    Rep Power
    0

    first create table of some name and then put all details like database name, host, username, password in your config file. and remember, username and password of mysql database user may be different from your ACCOUNT/CP's un and pw.

  10. #10
    Junior Member sanju is on a distinguished road sanju's Avatar
    Join Date
    Jan 2010
    Location
    W.B (India)
    Posts
    7
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Rep Power
    0

    Localhost function may not working in ur hosting. Findout the database server host address by go to ur database and replace it with 'localhost'. I think ur prob be solvd
    [Only Registered Users Can See Links Click Here To Register]

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Similar Threads

  1. Mobile connect only script
    By ripkk2tfk in forum REQUEST FORUM
    Replies: 5
    Last Post: 25-09-09, 09:16
  2. Connect this Gbook to my Login database.
    By infested13 in forum REQUEST FORUM
    Replies: 5
    Last Post: 23-03-09, 20:20
  3. Help! Connect.php (wap)
    By DarkWizardLT in forum Coding Forum
    Replies: 11
    Last Post: 17-05-08, 21:27
  4. How To Connect To Databse At Leadhoster.com
    By futurewap in forum Scripts Forum
    Replies: 2
    Last Post: 10-07-07, 17:28

Bookmarks

Posting Permissions

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

SEO by vBSEO