TalkPHP

TalkPHP (http://www.talkphp.com/forums.php)
-   Absolute Beginners (http://www.talkphp.com/absolute-beginners/)
-   -   if require_once else (http://www.talkphp.com/absolute-beginners/6139-if-require_once-else.html)

nefus 02-28-2012 03:42 PM

if require_once else
 
Is there a way to do an IF ELSE statement with require_once?

nefus 02-28-2012 04:25 PM

oh wait, I figured it out... doh!
you use !require_once

tony 02-29-2012 06:07 PM

Hehe, self discovery feels good sometimes. but yeah, requre_once does return values to test logic on.

nefus 03-05-2012 01:25 AM

Yea, best to do an if (file_exists($filename)) to make sure before the require.


All times are GMT. The time now is 10:37 PM.

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0