Topic: index.php in gallery permission

When I create a gallery with svManager, the permission of the index.php file in the gallery folder (example: g1, g2, etc.) is 666 and when I try to visualize this page, I receive the following message:

500 - Internal Server Error
If you are the webmaster of this site please log in to Cpanel and check the Error Logs. You will find the exact reason for this error there.
Common reasons for this error are:
Incorrect file/directory permissions: Above 755.
In order files to be processed by the webserver, their permissions have to be equal or below 755. You can update file permissions with a FTP client or through cPanel's File Manager.
Incorrect Apache directives inside .htaccess file.
Make sure you have not specified unsupported directives inside the local .htaccess file. Such include PHP settings and Apache module settings.

Now if I set manually, via FTP, the permissin of index.php to 755, I can watch the gallery but if I modify the includes/constants.php to try to set the permission on 755 without my ftp setting, the setting doesn't happen.

What I should change to have an automatic set of index.php of the gallery to 755?

This www enbsp com/svmanager/g3/ is a gallery with permission of index.php on 755.

This www enbsp com/svmanager/g4/ is a gallery with permission of index.php on 666.

Thanks

Re: index.php in gallery permission

You should be ok if you set the gallery folder permissions to 0755. That is on g1, g2 etc.

...if I modify the includes/constants.php to try to set the permission on 755 without my ftp setting, the setting doesn't happen.

I'm not sure why this is not working for you. Have you done it this way? The default settings are:

// Attempt to set permissions on new gallery folders (default is false)
define('NEW_GALLERY_CHMOD', false);
// Permissions for new gallery folders (only if NEW_GALLERY_CHMOD is true)
define('NEW_GALLERY_DIR_MODE', 0755);

And you would need to change this to:

// Attempt to set permissions on new gallery folders (default is false)
define('NEW_GALLERY_CHMOD', true);
// Permissions for new gallery folders (only if NEW_GALLERY_CHMOD is true)
define('NEW_GALLERY_DIR_MODE', 0755);

Note that this only changes the permissions for new gallery folders not existing ones.

jack

Jack Hardie
SimpleViewer Support Team.

Re: index.php in gallery permission

I changed in constants.php "false" to "true" the new gallery chmod but the folder of the new gallery takes permission 755 and index.php takes still 666.

My server doesn't show the page index.php with permission 666.

Exist a solution for to set permission 755 to index.php, or a server configuration (.htaccess or similar) to visualize the page index.php with permission 666?

Sorry for my english... but my first language is napoletan.

Thanks.

Re: index.php in gallery permission

We  have had this problem before for the permissions on the gallery folder but I think it's the first time we have a server that gives a problem with the permissions of the index.php file.

Is it a Linux server? If it is Linux then the permissions on new files are set by the user mask or umask setting. Try contacting your server administration or help-desk and explain the problem to them. Ask them if it is possible to change the umask setting so a php script will create new files with permissions 755.

Actually, I think 644 on files and 755 on folders would be ok as well and would probably be better.

jack

Jack Hardie
SimpleViewer Support Team.

Re: index.php in gallery permission

The server is a Linux server and the svmtest shown all green points.

I don't know is the new files are set by the user mask or umask setting and I don't know how to verify this...

Re: index.php in gallery permission

I have emailed a new version of svManager for you to try.

jack

Jack Hardie
SimpleViewer Support Team.

Re: index.php in gallery permission

Thanks for the new version but the index.php of the gallery doesn't run.

This is the link to the new test gallery: www enbsp com/svmanager2/g1/

In this gallery the index.php has permission 666 and I understood that on my server this permission doesn't permit to run the index.php.

Re: index.php in gallery permission

GREAT!

In include/constants.php I changed

define('NEW_GALLERY_CHMOD', false);

to

define('NEW_GALLERY_CHMOD', true);

and now the gallery is running:  www enbsp com/svmanager2/g2/

Thank you very much!!!