I have a script which builds a pdf document and then inserts it into a directory with the chmod 777. We have gone into shell and changed all the document permissions to 777 as well to try to solve this problem and also changed the user from apache to the correct owner of the files.
I am still getting this error tho:
Warning: stat failed for (errno=2 – No such file or directory)
[code=php]
$this->attachment = ‘/home/httpd/virtualhosts/someurl.com/subdomains/development/public_html/admin/quotes/’.$attachment.’.pdf’;
if (file_exists($this->attachment))
{
$file = fopen($this->attachment,’rb’);
$data = fread($file,filesize($fileatt));
fclose($file);
}
How can the file exist yet not be found?
thanks in advance