Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2003
    Location
    england
    Posts
    95

    Unanswered: Inserting into sql database table

    i have designed the current code, yet on submitting the data nothing appears in my database table

    $dbh=mysql_connect ("localhost", "twqwwsoy_user", "iiyama") or die ('I cannot connect to the database because: ' . mysql_error());
    mysql_select_db ("twqwwsoy_resources");


    $SQL= "INSERT INTO Diary (username, day_id, message) VALUES('$username', '$day', '$message')";

  2. #2
    Join Date
    Jul 2003
    Posts
    7
    Change for the following: mysql_select_db ("twqwwsoy_resources", $dbh);


Posting Permissions

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