function giving me trouble

What I can do:
function createDir($path = ‘/path/to/root/’)

What I need to do:
$server_root = $_SERVER[‘DOCUMENT_ROOT’];
function createDir($path = $server_root)

or this:
function createDir($path = dirname($_SERVER[‘SCRIPT_NAME’]))

are you trying to re-create directory ? $_SERVER[‘DOCUMENT_ROOT’]; and dirname($_SERVER[‘SCRIPT_NAME’]) are already directories …

or i get something wrong ?

Sponsor our Newsletter | Privacy Policy | Terms of Service