Directory is not writable: /var/www/cgi-bin/../images at /var/www/cgi-bin/getgraph.pl
was the output to Millers code.
and if I try to write to /tmp/blah.$format it works fine.
I wonder if it will work if I do a sudo chmod a+x to my /var/www directory. but if I do what does that mean :)
exelent thanks here is the error
Can't write file: Permission denied at /var/www/cgi-bin/getgraph.pl line 80.
how do i give the "browser" or w/e it is permission
that is part of the weirdness here is what I have
#### snipet #####
print "test ";
open(IMG, ">../images/the_image.$format") or die "Can't write file: $!";
print "test ";
#####end snipet ######
The first "test" shows up on the web page but the error from the open doesn't, nor does the second...
Cool I changed it to that and it did not fix the problem. That line still fails for some reason when I run it through the form on my index.php
(it works when I sudo run it)
anything else you could think of?
ok how do I get it to open in a different folder.
/var/www/cgi-bin for apache 2 what would / mean? my system / or would it be "www/"
and where would be a good place to do the store?
So what I have done is made a cool .pl script which opens the database takes out some data, uses GD:graph to make a nice line graph and it creates the graph, the line of interest is
open(IMG, ">graph/the_image.$format") or die $1;
this line works when I run the script.
HERE IS WHERE IT BREAKS...
What I want to do is take a number (say from a for loop 1,2,...) make it 4 bytes long(in representation) and append it to a string like this.
$theString.=the4ByteNumber; # "xxxxxx0001" for example
Hi, I am trying to take a number format it as a 32 bit(4 byte) unsigned integer, then append it to a string.
the string I want is the follow "#0001", where the integer was 12. does this make sense? so this is what I thought I should do it
$string = "#";
$int = pack('L',1)
$string.=...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.