• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
User Guide errors

#1
There are a few errors in the user guide on this page

Quote:public function view($slug = NULL)
{
       $model = new NewsModel();

       $data['news'] = $model->getNews($slug);

       if (empty($data['news']))
       {
               throw new \CodeIgniter\PageNotFoundException('Cannot page the page: '. $slug);
       }

       $data['title'] = $data['news'][0]['title'];

       echo view('Templates/Header', $data);
       echo view('News/Index', $data);
       echo view('Templates/Footer');
}

<?php
echo '<h2>'.$news['title'].'</h2>';
echo $$news['text'];

page I assume it should be find
[0] shouldn't be there
Index should be View
$ shouldn't be there
Reply


Messages In This Thread
User Guide errors - by george--fb - 06-28-2016, 06:39 PM
RE: User Guide errors - by kilishan - 06-28-2016, 08:00 PM
RE: User Guide errors - by ciadmin - 06-28-2016, 08:07 PM
RE: User Guide errors - by kilishan - 06-28-2016, 08:17 PM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.