title: Fatal error: Call to undefined function mysql_connect() in C:\Apache\htdocs\test.php on line 2
body: <p>Fatal error: Call to undefined function mysql_connect() in C:\Apache\htdocs\test.php on line 2</p>
  
  <p>I've spent 11 hours today trying to get past this ONE problem.</p>
  
  <p>I have installed:
  MySQL 5.1
  Apache 2.2.14
  PHP 5.2.17</p>
  
  <p>these were the versions referred to in the book "PHP and MySQL".</p>
  
  <p>When I run the script:</p>
  
  <pre><code>&lt;?php
  mysql_connect ('localhost', 'root', 'password');
  ?&gt;
  </code></pre>
  
  <p>where localhost, root and password are the REAL values for this given test
  system and all I have seen is:</p>
  
  <p>Fatal error: Call to undefined function mysql_connect() in C:\Apache\htdocs\test.php on line 2</p>