title: can't get value from associative array when using foreach loop
body: <p>I have been staring at this for the last hour and can't seem to understand why this is not working. The code below gets the info from the table, which is in an array (example below the code).</p>
  
  <pre><code>$post_id = 228;
  
  $content_post = get_post($post_id);
  $content = $content_post-&gt;post_content;
  
  global $wpdb;
  
  $results =$wpdb-&gt;get_results("SELECT * FROM wp_article_hyperlinks"); 
  
  foreach ($results as $result){
  // $url = $result["url"];
  // $title = $result["title"];
  
      echo '&lt;pre&gt;';
      var_dump($result["title"]);
      echo '&lt;/pre&gt;';
  }
  }
  </code></pre>
  
  <p>I am trying to get the title value, but the above just dumps a blank screen. When I run a <code>foreach</code> with a key and value all I get is <code>int</code> or <code>NULL</code> when I use the key.</p>
  
  <pre><code>object(stdClass)#717 (4) {
    ["ID"]=&gt;
    string(1) "1"
    ["time"]=&gt;
    string(19) "2018-08-22 12:30:29"
    ["title"]=&gt;
    string(15) "gluteus maximus"
    ["url"]=&gt;
    string(86) "/wp-content/blahblah"
  }
  </code></pre>
  
  <p>I have compared it to other code/posts on SO and W3Schools and I'm pretty sure that whatever I'm missing is pretty basic but I can't see it.</p>