⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

Error in CI index.php



FoxfireTX

FoxfireTX
  • profile picture
  • Member

Posted 13 February 2018 - 19:18 PM

I am new to both php and CI but really want to use grocerycrud for a website.  So I purchased and downloaded the template for gc, installed CodeIgniter and headed for the  GC YouTube tutorial, only to discover that I can't get beyond the first two minutes because of an error message in the index.php.  The error message is:

 

syntax error, unexpected 'public' (T_PUBLIC), expecting end of file in C:\xampp\htdocs\grocery-crud-demo\index.php on line 316

 

 

My localhost is running php 7.1.  I've tried adding a ';' to the end of line 316, tried adding a ?> to the end of the page and neither gets me beyond this message. Any help will be appreciated as it is frustrating to get an error message just running the index.php for the tutorial video.

 

Thanks!