title: Fatal error: Call to undefined function sqlsrv_connect()
body: <p>I have come across quite a few post regarding the same subject question, however I am still unable to resolve it and so I ask. I am trying to connect to sql in my php script. My connection string is:</p>
  
  <pre><code>/* Specify the server and connection string attributes. */
  $serverName = "xxx-PC\SQLExpress";
  $connectionOptions = array("Database"=&gt;"Salesforce");
  $conn = sqlsrv_connect($serverName, $connectionOptions);
  if($conn === false)
  {
        die(print_r(sqlsrv_errors(), true));
  }
  </code></pre>
  
  <p>I have installed and included the following in my <code>php.ini</code> file located under the wamp folder: <code>C:\wamp\bin\php\php5.4.16</code>:</p>
  
  <pre><code>extension=c:/wamp/bin/php/php5.4.16/ext/php_sqlsrv_53_ts.dll
  </code></pre>
  
  <p>My <code>wampserver</code> is running fine and so are the <code>wampapache</code> and <code>wampsqld</code> services. I am able to execute php.exe successfully. However I am unable to make the connection to <code>SQL Server 2008 R2</code> where my database is located. Please help!</p>
  
  <p>EDIT 1: The wamp server is running the wampmysql service while I am trying to connect to <code>SQL Server 2008 R2</code>. Could this be the reason? Should I be using <code>MySQL</code> instead of <code>SQL</code>? Any pointers?</p>
  
  <p>EDIT 2: I do not see <code>sqlsrv</code> section at all when I run <code>phpinfo()</code> though I have added <code>extension=php_sqlsrv_54_ts.dll</code> in the <code>php.ini</code> file located in the bin folder of the wamp server. </p>
  
  <p><img src="https://i.stack.imgur.com/WAckT.png" alt="enter image description here"></p>