I have posted a similar question before.. but then right now there is an issue with the code... The data is getting entered into MySql Database...
PHP FILE:
<html>
<head>
  <title>Enter New Project Details</title>
</head>
<body>
<?php include 'RegProj.html';
$pn=isset($_POST['ProjectName']) ? $_POST['ProjectName'] : '';
$tn=isset($_POST['TaskName']) ? $_POST['TaskName'] : ''; 
$dsc=isset($_POST['Proj_desc']) ? $_POST['Proj_desc'] : ''; 
$date = date('Y-m-d H:i:s');
$serverName = "Swagatha-PC"; 
if($_SERVER['REQUEST_METHOD']=="POST")
{
$conn = mysqli_connect( 'localhost:3307', 'root', '', 'TimeSheet');
if( $conn ) 
{
 echo "Connection established.<br />";
}
else
{
 echo "Connection could not be established.<br />";
 die( print_r( mysqli_connect_errno($conn), true));
} 
$query="Insert Into dbo.Project (DateAdded,ProjectName,TaskName,Proj_desc) 
values ('$date','$pn' ,'$tn' , '$dsc')";
$stmt=mysqli_query($conn,$query);
if($stmt==false)
{
echo "Error in adding Info!! Reload Page and try again!!<br/>";
 die( print_r( mysqli_connect_errno($stmt), true));
}
else
{
 echo " Record Added!!";
}
mysqli_close($conn);
}
?>
</body>
</html>
HTML FILE:
    <html>
   <head>
      <title>Enter New Project Details</title>    
    </head>
<body>
 <form id="project" method = "post" action = "RPMS.php">
         <table>
            <tr>
               <td>Project Name:</td> 
               <td><input type = "text" name = "ProjectName"></td>
            </tr>
            <tr>
               <td>Task Name:</td>
               <td><input type = "text" name = "TaskName"></td>
            </tr>
            <tr>
               <td>Project description:</td>
               <td><textarea name = "Proj_desc" rows = "5" cols = "40"></textarea></td>
            </tr>
            <tr>
               <td>
                  <input type = "submit" name = "submit" value = "Submit" > 
               </td>
            </tr>
         </table>
      </form>
</body>
</html>
The Error looks something like this:
How can i fix it??

 
     
    