title: how to get data in descending order when using pagination(using codeigniter )?
body: <p>i have use codeigniter library function for pagination. it works but i didn't get how to display the content in descending order.</p>
  
  <pre><code>public function news($offset = 0) {
      $this-&gt;load-&gt;library('pagination');
      $config['base_url'] = base_url() . "index.php/homepage/inbox_news";
      $config['total_rows'] = $this-&gt;db-&gt;count_all_results('news');;
      $config['per_page'] = 3;
      $config['full_tag_open'] = '&lt;div class="pagination"&gt;';
      $config['full_tag_close'] = '&lt;/div&gt;';
      $this-&gt;pagination-&gt;initialize($config);
      $data['posts'] = $this-&gt;db-&gt;limit(3, $offset)-&gt;get('news')-&gt;result();
      $this-&gt;load-&gt;view('inbox_news', $data);
  }
  </code></pre>
  
  <p>//here news is my table name in database</p>
  
  <p>in the view page, i have done like this</p>
  
  <pre><code>&lt;?php
   foreach ($posts as $row) {
       echo $news = $row-&gt;news;
   }
  echo $this-&gt;pagination-&gt;create_links();
  ?&gt;
  </code></pre>
  
  <p>//it is working but the data is in ascending order by default. what can i do to put it in ascending order?</p>