Welcome Guest, Not a member yet? Register   Sign In
CodeIgniter Documentation Example Code Error | Explained and Fixed
#5

(02-17-2016, 02:40 PM)Narf Wrote: The slash may be unnecessary, but the example is not in fact erroneous - multiple slashes should be and are in fact automatically reduced to a single one by PHP.

Quote:php > mkdir(__DIR__.DIRECTORY_SEPARATOR.'foo');
php > touch(__DIR__.DIRECTORY_SEPARATOR.'foo'.DIRECTORY_SEPARATOR.'bar');
php > var_dump(file_exists(__DIR__.DIRECTORY_SEPARATOR.'/////////////foo//////////////////////////////bar'));
bool(true)

So while I don't mind adjusting the docs, I'm more interested in the specifics of your environment, so we'd know why this is happening.

Can't believe that you're actually right. Now I'm trouble replicating the issue.. dam. Confused
Reply


Messages In This Thread
RE: CodeIgniter Documentation Example Code Error | Explained and Fixed - by phpdevsami - 02-17-2016, 04:56 PM



Theme © iAndrew 2016 - Forum software by © MyBB