Parse error: syntax error, unexpected 'try' (T_TRY) in E:\wamp64\www\project-trial\install.php on line 10 : <p>I am trying to install the database for my project with this file - install.php
Code Below: </p>

<pre><code>&lt;?php
/*
** Open a connection with the database via PDO to create a new database and 
tables with structure &amp; insert initial values.
*/

require "config.php"
/*
** CREATING DATABASE CONNECTION**
*/
try{
   $conn = new PDO("mysql:host=$host", $username, $password, $options);
   $sql = file_get_contents("data/init.sql");
   $conn-&gt;exec($sql);
   echo "Databse and Tables created successfully. :)";
}catch(PDOException $error){
   echo $sql."&lt;br&gt;".$error-&gt;getMessage();
}
?&gt;
</code></pre>

<p>If I remove the try...catch implementation. Then it shows error unexpected $conn.
Has this anything to do with the PDO object creation. Wouldn't PDO run with<br>
PHP 5.6.35. I am using WAMP 3.0. </p>
