Hi,
I have a Drupal module within which I make the following call (using a jpgraph function).

$graph->Stroke("/public_html/graphPic.png");
This command should basically show my graph as a picture.

I get the following error:

ERROR: Can't write to file "/public_html/graphPic.png". Check that the process running php has enough permission.

I changed the folder attributes from 744 to 777 but still I can't write to this folder.

In the drupal module I am the admin user calling this function.

Any thoughts what could be wrong?

thank you in advance for your help!

Comments

konordo’s picture

Maybe you should try Recursive chmoding? Just a thought...

--------------------------------------------
Konordo Ltd
http://www.konordo.com

styro’s picture

already exists, it will be the file permissions not the directory permissions that need changing. Directory permissions are only for adding new files.

It sounds like a webserver filesystems thing not a Drupal thing. If you still can't get it working, maybe your webhost has done something to prevent you adding world writable permissions to your home directory or other directories?

--
Anton
New to Drupal? | Troubleshooting FAQ
Example knowledge base built with Drupal

mrbkonline’s picture

When I changed the directory to this:
$graph->Stroke("healthcare.png");

then it worked, i.e. it put the file into my root folder. I think I don't need a leading "/", that might be causing the problem.

thank you for responding!