Results 1 to 3 of 3

Thread: Conection

  1. #1
    Join Date
    Jun 2005
    Posts
    2

    Conection

    Hello!
    I'm using this PHP code as a conection:

    # FileName="Connection_php_mysql.htm"
    # Type="MYSQL"
    # HTTP="true"
    $hostname_uploadfile = "localhost";
    $database_uploadfile = "databasename";
    $username_uploadfile = "uername";
    $password_uploadfile = "";
    $uploadfile = mysql_pconnect ("localhost", "username", "") or die ('I cannot connect to the database because: ' . mysql_error());
    mysql_select_db ("databasename");

    When it loads it is OK, nobugs, but when i try to login my page returs this:

    Transaction failed!
    Your SQL:
    select * from users where name='user' and username='pass'
    Error Msg:
    No Database Selected

    Please help!

    Regards

  2. #2
    Join Date
    Feb 2003
    Posts
    1,048
    What is the code for the login?

  3. #3
    Join Date
    Jun 2005
    Posts
    2

    Thank you!!!

    I just resolve it, it has to do with login script.

    thank you anyway.

Posting Permissions

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