CodeIgniter Forums
USING V2.2.3 PROBLEM - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forum-5.html)
+--- Forum: General Help (https://forum.codeigniter.com/forum-24.html)
+--- Thread: USING V2.2.3 PROBLEM (/thread-62727.html)



USING V2.2.3 PROBLEM - jon12345 - 08-19-2015

if ( ! file_exists(APPPATH.'/views/pages/'.$page.'.php'))
{
// Whoops, we don't have a page for that!
show_404();
}


Fatal error: Call to undefined function file_exits() in C:*********

IT GIVES ME AN ERROR.. KINDLY HELP ME OUT. THANKS


RE: USING V2.2.3 PROBLEM - mwhitney - 08-19-2015

It looks like you may need to copy/paste your code and the error message directly over to the forum. Your error message doesn't match your code in this case, as the error message implies a typo in your code which isn't reflected in the code itself.


RE: USING V2.2.3 PROBLEM - freddy - 08-19-2015

as mwhitney you need to copy and paste your script so we can debug it together


RE: USING V2.2.3 PROBLEM - includebeer - 08-23-2015

(08-19-2015, 03:25 AM)jon12345 Wrote: if ( ! file_exists(APPPATH.'/views/pages/'.$page.'.php'))
{
// Whoops, we don't have a page for that!
show_404();
}


Fatal error: Call to undefined function file_exits() in C:*********

IT GIVES ME AN ERROR.. KINDLY HELP ME OUT. THANKS

You have a typo.
file_exists() is defined in system/core/Codeigniter.php and is always available.


RE: USING V2.2.3 PROBLEM - mwhitney - 08-24-2015

Actually, file_exists() is defined by PHP, which makes it even more likely that there's a typo, but the typo is clearly not in the code that was included in the question.


RE: USING V2.2.3 PROBLEM - includebeer - 08-24-2015

(08-24-2015, 08:30 AM)mwhitney Wrote: Actually, file_exists() is defined by PHP

True! I had too much beer when I replied it was defined in CI ! Confused