title: Show mysql data in php using the $_GET['id'] coming in from the URL
body: <p>I'm getting the 'id' from the URL, but I can't seem to use it to select other pieces of data from the same row.  I'm trying to show Film_Title (the name of the row in MySQL) using the Film_ID.  In this case the Film_ID is coming in from the URL like this: /film.php?id=58.</p>
  
  <p>How do I use that id to select Film_Title?  Here's my code:</p>
  
  <pre><code>if (isset($_GET['id'])) {
      $id = trim($_GET['id']); 
      $Film_Title = trim($_POST['Film_Title']);
  
      $sql = "SELECT Film_Title FROM Films WHERE Film_ID=?";
  
      require_once 'includes/MySQL.php';  
      require_once 'includes/db.php';
  
      $db = new MySQL($dbconfig['host'], $dbconfig['user'], $dbconfig['password'], $dbconfig['database']);
      $stm = $db-&gt;dbConn-&gt;prepare($sql);
      $stm-&gt;execute(array($id, $Film_Title));
      echo "&lt;h3&gt;film record $Film_Title has been selected&lt;/h3&gt;";
  
  }
  </code></pre>