title: Codeigniter redirect add dynamic 3rd URI segment
body: <p>I'd like to get this to redirect to <code>welcome/stats/3</code> asuming <code>site_id</code> is <code>3</code></p>
  
  <pre><code>function add_keyword()
  {
      $data = array(
          'keyword' =&gt; $this-&gt;input-&gt;post('keywords'),
          'depth' =&gt; $this-&gt;input-&gt;post('depth'),
          'site_id' =&gt; $this-&gt;input-&gt;post('site_id')
      );
  
      $site_id = $this-&gt;input-&gt;post('site_id');
  
      $this-&gt;site_model-&gt;add_keyword($data);
      redirect('welcome/stats/', $site_id); 
  }
  </code></pre>