Man what I hard row to ho, I didnt know what I was getting into when I started messing with PHP.
Ive gotten to the part where Im connecting to databases, the part Im REALLY interested in, and wouldnt ya know it.....stuck!
The mannual I am using now uses the old function mysql_db_query, which is now gone bye bye. Could someone point me to an expamle of using the replacements functions, mysql_query and mysql_db_select? Complete with proper string variables and all that good stuff? Of if anyone knows off hand could they impart this knowledge to me in a reply.
For clarity sake, Ill include the code that has me stuck: (This code sends data to a database via form entries)
<HEAD>
<TITLE>Creating a Table</TITLE>
</HEAD>
<BODY>
<?php
$Host = "localhost";
$User = "administrator";
$Password = "";
$DBName = "NewDatabase";
$TableName = "Feedback";
$Link = mysql_connect ($Host, $User, $Password);
$Query = "CREATE table $TableName (id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
FirstName TEXT, LastName TEXT, EmailAddress TEXT, Comments TEXT)";
if (mysql_db_query ($DBName, $Query, $Link)) {
print ("The query was successfully executed!<BR>\n");
} else {
print ("The query could not be executed!<BR>\n");
} }
mysql_close ($Link);
?>
</BODY>
Sorry for the length =(