title: How to echo specific value from database?
body: <p>Here's the layout of my table (<code>content</code>):</p>
  
  <pre><code>id, shortcode, message
  1, blinds01, Random Message
  2, shutters88, Random Message
  3, windows12, Random Message
  </code></pre>
  
  <p>Here's the PHP I'm using to get all of the rows:</p>
  
  <pre><code>&lt;?php
  $host = "removed";
  $user = "removed";
  $pass = "removed";
  $database = "removed";
  
  $mysqli = new mysqli($host, $user, $pass, $database);
  
  $query = "SELECT * FROM `content`";
  
  $mysqli-&gt;close();
  ?&gt;
  </code></pre>
  
  <p>What I'm having issues with is not understanding how to echo data.</p>
  
  <p>For example, what PHP code what I use to echo the <code>message</code> column where <code>id = 2</code>?</p>
  
  <p>I know that I could just update my query to get that specific information, but I need to get a lot of different <code>message</code> fields on the same page and don't want to be querying the database 100 times per page load (which is why I'm querying all rows in the table).</p>
  
  <p>Any help would be appreciated.</p>