title: Parse error: syntax error, unexpected '$connection' (T_VARIABLE) in C:\xampp\htdocs\final\newmail.php on line 7
body: <p>When I run this code:</p>
  
  <pre><code>&lt;?php
  
  $reuser = $_GET['ruser'];
  $mail = $_GET['msg']; 
  $sender = $_GET['senderr']
  
  $connection = mysql_connect("localhost","root");
  mysql_select_db("final");
  
  if(!$connection){
      die('could not connect:'.mysql_error());
  }
  
  $sql = "INSERT INTO mails (sender,to,message,)
  VALUES ('$sender','$reuser','$mail')";
  
  mysql_query($sql) or die("error".mysql_error());
  mysql_close($connection);
  ?&gt;
  </code></pre>
  
  <p>I get this error:</p>
  
  <blockquote>
    <p>Parse error: syntax error, unexpected '$connection' (T_VARIABLE) in C:\xampp\htdocs\final\newmail.php on line 7</p>
  </blockquote>
  
  <p>I don't know what the problem is – can anyone help me please?</p>