OJS 3.1.1.0 Can´t upload image Logo

Greetings to all, I installed the new ojs 3.1.1.0 and I can not upload an image for the logo. Can you help me.
temporal_1

In the same way it does not allow me to upload a .css file, the same message appears.

i don’t understand the message, but maybe it help

It is not the same problem. The message that appears to me says “The file could not be uploaded, please try again or contact the administrator if the problem persists.”

I need urgent help, I have contacted my hosting provider to tell me the route of the mime types and he has indicated it to me. But the problem was not solved.
Then they told me:

The problem it presents is with the database when recognizing the function that makes the entry of information record, this occurs because it appears to be entering data invalid or null as indicated by the error log.

[18-May-2018 22:46:11 UTC] PHP Strict Standards: Declaration of PKPUsageEventPlugin::getEnabled() should be compatible with LazyLoadPlugin::getEnabled($contextId = NULL) in /home/nydsigel/public_html/disertante.com/lib/pkp/plugins/generic/usageEvent/PKPUsageEventPlugin.inc.php on line 0
[18-May-2018 22:46:11 UTC] PHP Strict Standards: Declaration of LensGalleyPlugin::register() should be compatible with LazyLoadPlugin::register($category, $path, $mainContextId = NULL) in /home/nydsigel/public_html/disertante.com/plugins/generic/lensGalley/LensGalleyPlugin.inc.php on line 0

This is due to the fact that currently in the last update the strict mode is activated in the servers, to avoid injection in web pages and Online systems, as precautionary measures against possible attacks. You should check how the information is entered into the database and verify that the information does not contain invalid, null or void data, as this is generating errors.

They told me:
That I must identify the file that makes the entry of the information to the database and add some kind of validation of the information so that it does not have null data. Additional within the database that your OJS system uses verify that you do not have this type of data.

Also Reviewing the folders I noticed that the images I want to upload if they are uploaded but saved in a temporary folder and there they stay.

WHAT DO I HAVE TO DO. HELP ME

Hi @Pandora_ramin,

If you see the file appearing in the temporary area, then the problem is either

  • file permissions, or
  • MIME type identification problems.

Are you sure you’ve set permissions everywhere they need to be set? Where have you set file permissions? Specifics will help eliminate this as a possible cause.

The “strict standards” messages your host points out are just warnings and will not cause problems.

Regards,
Alec Smecher
Public Knowledge Project Team

I thank you very much for your help. Seriously, thank you very much.
All the folders I have given permission 777 to test if the problem is fixed and nothing happens. Ex:
The folder where the publications are saved
/home/publicaciones/ (777)
• Journals (777)
1(777)
• scheduledTaskLogs(777)
• Site (777)
• Temp (777) Here the files that I upload are saved
………

The public folder and its subfolders also have persimmons 777
But the problem is not fixed.

Something important that my hosting provider told me about the magic.mime file is that I do not have access since my service is shared, even though he told me that the route is:
application / magic.mime.

Could it be that the fact that I can not see the Application folder also prevents OJS from reading the magic.mime file?

Hi @Pandora_ramin,

If you don’t have access to your own magic.mime file, it’s best to leave that line commented out in your config.inc.php. This should cause PHP to use its own built-in database.

Logos get uploaded into subdirectories of the public directory. Have you gone more than 2 levels deep in your permission changes? Make sure everything below public is set to allow PHP to manage files there. If whatever tool you’re using to manage permissions has a “recursive” option, that’s the surest way.

Regards,
Alec Smecher
Public Knowledge Project Team

If I have reviewed the subfolders and they also have permission 777 and nothing changes, I still can not upload the images.
I left the line commented as you indicated me and nothing happens.
Any other idea.
Please do not give up. Help me

Hi @Pandora_ramin,

The specific subfolder to check will be public/journals/1, where 1 is the journal ID (you can check this in the journals table in the database). Also check to ensure all files in that directory are also set with the right permissions.

Failing that, you might also check whether your server has SELinux extensions enabled (you’ll probably have to ask your ISP to check this).

Regards,
Alec Smecher
Public Knowledge Project Team

I went back to review the permissions and they are fine (777) folder and subfolders. In reference to the SELINUX extensions I will ask and tell you. Thank you.

I thank you very much asmecher, for all the help given and for not having left me alone with this problem with my magazine.
I told you that I contacted my hosting provider and I asked him what you told me and they told me that they enabled the CHMOD function for my PHP
After this I tried my site once more and finally it worked, now it allows me to upload the files normally. I fixed my problem
Many thanks. I hope this solution will help another with the same problem.
Vanessa :hugs::smile:

Hi @Pandora_ramin,

Excellent, glad to hear it’s working! As you’re learning, there’s a lot of variety in server environments and that can make it very hard to figure out what’s happening.

Regards,
Alec Smecher
Public Knowledge Project Team