469,610 Members | 1,774 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,610 developers. It's quick & easy.

imagepng/jpeg/gif, permissions, Apache and CRON scripts - help

if ($this->isSuccessful && !$hasMogrified) {
@imagecopyresampled($newImage, $image, $config['posX'],
$config['posY'], 0, 0, $config['width'], $config['height'],
$origWidth, $origHeight);
$imageEvalStr = 'if (@!image' . $extArray[$type] . "(\"$newImage\",
\"$this->thumbLocationPath/$this->fileName\", $thumbDimensionInt))
{\n" .
' $this->isSuccessful = false;\n' .
' $this->setErrorArray(array(\'action\' => \'Could not
seem to save image "$this->fileName" onto
"$this->thumbLocationPath"\'));' . "\n" .
' echo "Could not seem to save image \"$this->fileName\"
onto \"$this->thumbLocationPath\";\n' .
"} else {\n" .
" echo 'I am trying to save \"$this->fileName\" onto
\"$this->thumbLocaitonPath\"\n';\n" .

What this snippet is supposed to do is do either imagepng, imagejpeg,
imagegif, imagebmp or imagetiff PHP functions which will save the
image resource object binary contents onto the actual physical image

However, consider this:

I am running a CRON script that runs outside of the document root,
owned by me "phil" who is part of the Apache group. It will
instantiate a class object whose method contains that snippet that
will auto-run that feature, which is found within the document root,
owned by me "phil", and manipulate images that are owned by me "phil"
in directories owned by Apache; the directories having permissions of
0770, the images permissions of 0644.

Nothing happens.

No errors, no warning, no notices, nothing. No images are generated,
nothing at all occurs within the directories whatsoever. I am
suspecting permissions errors but since no errors are being produced I
can't verify what is going on.

What I need to know from someone is this:

How can a CRON script, outside the document root, ultimately affect
images within the document root that the CRON script's owner does not
himself own (but is in the same group as the images' owner)?

I really need help as usual.

Jul 17 '05 #1
0 1498

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Mike Wasilewski | last post: by
2 posts views Thread by gruddo | last post: by
9 posts views Thread by jab3 | last post: by
11 posts views Thread by Dave Schwimmer | last post: by
7 posts views Thread by none | last post: by
6 posts views Thread by kwest | last post: by
30 posts views Thread by Adam Baker | last post: by
reply views Thread by gheharukoh7 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.