G60corrado
Technical User
Hey Guys/Girls
I'm just getting started with Mysql and PHP. I've used the add packages function through Red Hat 8.0 to get it set up.
My question is I get this when I try to connect to the database
Fatal error: Call to undefined function: mysql_connect() in /var/ on line 13
Do I need to edit something in php.ini?? Any help would be awsome. Thanks
My code is
<?
$dbuser = 'root';
$dbhost = 'localhost';
$dbpass = 'password';
$dbname = 'test2';
$dbtble = 'books';
$mysql_link = mysql_connect($dbhost,$dbuser,$dbpass);
$column = mysql_list_fields($dbname,$dbtble,$mysql_link);
for($i=0; $i< mysql_num_fields($column); $i++ )
{
print mysql_field_name($column,$i )."<br>";
}
?>
I'm just getting started with Mysql and PHP. I've used the add packages function through Red Hat 8.0 to get it set up.
My question is I get this when I try to connect to the database
Fatal error: Call to undefined function: mysql_connect() in /var/ on line 13
Do I need to edit something in php.ini?? Any help would be awsome. Thanks
My code is
<?
$dbuser = 'root';
$dbhost = 'localhost';
$dbpass = 'password';
$dbname = 'test2';
$dbtble = 'books';
$mysql_link = mysql_connect($dbhost,$dbuser,$dbpass);
$column = mysql_list_fields($dbname,$dbtble,$mysql_link);
for($i=0; $i< mysql_num_fields($column); $i++ )
{
print mysql_field_name($column,$i )."<br>";
}
?>