I've recently started learning PHP and MySQL from the book Beginning PHP5, Apache, MySQL Web Development. Several of the authors listed this site in thier "bios" in the book, so I'm hoping I can find someone familiar w/ the book enough to help me.
Anyways, in chapter three which basically introduces MySQL, I am running into a problem with the first line of the first program. 'creating a database'
<?php
$connect = mysql_connect("localhost", "bp5am", "bp5ampass") or die ("Hey loser, check your server connection.");
//The above line is the one it bombs out on, so not bothering with the rest of the code.
?>
When I try and load it from http://localhost/createmovie.php it gives me the error
Fatal error: Call to undefined function mysql_connect() in C:\Program Files\Apache Group\Apache2\test\createmovie.php on line 2
I do have MySQL installed, and running. I've got the bp5am user set up like it said to do in the book... but I can't seem to figure out why this isn't working. I haven't really coded much in about ten years (C and C++ mostly) but it seems to me this error is saying that "mysql_connect()" a function that should be defined isn't.... and I've really no idea how to fix it, and haven't been able to figure it out from the book.
Any help would be muchly appreciated.