I'm experiencing a weird problem here, and maybe someone can shed some light on it.
I have the following code that fails on me with error Warning: mkdir(/home/jab/components/com_mos-chat/): No such file or directory:
if(!file_exists($this->componentDir()) && !mkdir($this->componentDir(),0777))
{
$this->setError(1,"Failed to create directory'" . $this->componentDir() . "'");
return false;
}
This is running on NetBSD/PHP 4.3.9. I have found that if I enclose the $this->componentDir() argument in quotes it works fine. The weird thing is that the same works on Linux or OS X box using the same PHP setup.
What am I missing? Thanks!