title: how to get single value from array in codeigniter
body: <p>I stored some data to an array using this code</p>
  
  <pre><code>$this-&gt;data['result']    =   $this-&gt;mymodel-&gt;search($keyword);
  </code></pre>
  
  <p>when I print my result by using <code>print_r($this-&gt;data);</code></p>
  
  <p>it shows like this </p>
  
  <pre><code>Array ( [base_url] =&gt; http://localhost/pelikanartline.com/ [result] =&gt; Array ( [0] =&gt; stdClass Object ( [product_id] =&gt; 2 [product_code] =&gt; 167007 [product_name] =&gt; ARTLINE VIVIX HIGHLIGHTERS 10PK YELLOW [product_discription] =&gt; some description [xylene_free] =&gt; y [rohs_compliant] =&gt; y [product_features] =&gt; some text ) ) )
  </code></pre>
  
  <p>now I want to store product_id value to a variable like pro_id. please help me to do this. </p>