Failed to open stream: no such file or directory

16 years 3 months ago #55162 by j0ly
hey guys,

I'm getting the following error and i was wondering if someone could help me with it.

When a user uploads a photo to the gallery they get the following error (snipped out my info)


Warning: copy(/snip/images/comprofiler/plug_profilegallery/index.html) [function.copy]: failed to open stream: No such file or directory in /home/snip/components/com_comprofiler/plugin/user/plug_cbprofilegallery/cb.profilegallery.php on line 362
Failed to be add index.html to the plugin gallery - please contact administrator!


Thank

Scott

Please Log in to join the conversation.

16 years 3 months ago #55300 by PerroLoco
I'm getting the same thing, though my error message is slightly different:

[code:1]Warning: copy(/snip/images/comprofiler/plug_profilegallery/index.html):
failed to open stream: No such file or directory in
/snip/components/com_comprofiler/plugin/user/plug_cbprofilegallery/cb.profilegallery.php
on line 362
Failed to be add index.html to the plugin gallery - please contact administrator![/code:1]

I checked all folder permissions and they're all 755 or 775.

Running:
Joomla 1.0.12
CB 1.1
CB Profile Gallery 1.0 RC2++ [build:26-JUN-2007]

Please Log in to join the conversation.

16 years 3 months ago #55301 by PerroLoco
Another note. Even though this error appears, the user's directory DOES get created and the image is uploaded. All is well except that the error shows up without apparent cause.

I found that if I created a directory for the user BEFORE I tried to upload a gallery image, the error didn't appear. Perhaps there's a sequence of events issue in the code?

I dunno - just hoping to help.

Thanks.

Please Log in to join the conversation.

16 years 3 months ago #55320 by PerroLoco
I think I see what's happening. As a security precaution, nearly every directory in a Joomla install has an index.html file added to prevent directory browsing.

This error is being generated when the CB Profile Gallery plugin script attempts to copy an index.html file into the user directory that is being created to house the uploaded files for that user. For some reason, the script is looking for the source index.html file (the one to create a copy of) in the wrong place. Or perhaps I've accidentally blown away the file it's looking for somewhere along the line. Either way, it errors when it can't find the index.html file it wants to copy.

I think you can get by this by copying one of the basic index.html files found in nearly every other directory into your /images/comprofiler/plug_profilegallery/ directory.

I did it and it worked fine after that. Hope it works for you.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.336 seconds

Facebook Twitter LinkedIn