OJS 3.0.2 problem. Can't upload logo: "The file could not be uploaded or revised."

I am encountering the same problem as this: Problem with upload in OJS 3.0 [solved] - #5 by asmecher

The suggestion is to backport to Apache 2.2, but that seems to be quite difficult to do on an Ubuntu Server 16.04 set up. I wonder whether anyone has an alternative solution to this problem.

Thanks.

Hi @Dennis_K,

Have you double-checked your file permissions? It’s possible that you’re encountering the same problem, but it’s more likely that your permissions aren’t set properly in the public directory.

Regards,
Alec Smecher
Public Knowledge Project Team

Dear Alec,

Thanks for the quick response. The permission for the public folder seems
ok. It is readable and writeable by the world. The first time round, I
could upload a logo but once I’ve deleted the old one to upload the new
one, I ran into the problem of “the file could not be uploaded or revised”
error.

1 Like

Hi @Dennis_K,

Are you setting your permissions recursively? It’s not just the public folder but also subfolders. Note that world-write permissions are never safe to use; they’re useful for debugging but shouldn’t be left that way.

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

Dear, I am in the same situation. I’ve already tried to set permissions in the folders unsuccessfully.
When i enable display_errors in config, i get these:

GoogleAnalyticsPlugin::getTemplatePath() should be compatible with Plugin::getTemplatePath($inCore = false) in /mnt/site/portal/ojs/plugins/generic/googleAnalytics/GoogleAnalyticsPlugin.inc.php on line 18

Warning: Declaration of BrowsePlugin::manage($verb, $args, &$message, &$messageParams, &$pluginModalContent = NULL) should be compatible with Plugin::manage($args, $request) in /mnt/site/portal/ojs/plugins/generic/browse/BrowsePlugin.inc.php on line 0

Warning: Declaration of BrowsePlugin::getTemplatePath() should be compatible with Plugin::getTemplatePath($inCore = false) in /mnt/site/portal/ojs/plugins/generic/browse/BrowsePlugin.inc.php on line 0

Warning: Declaration of PdfJsViewerPlugin::getTemplatePath() should be compatible with Plugin::getTemplatePath($inCore = false) in /mnt/site/portal/ojs/plugins/generic/pdfJsViewer/PdfJsViewerPlugin.inc.php on line 0

Warning: Declaration of PKPSubmissionHandler::authorize($request, &$args, $roleAssignments) should be compatible with PKPHandler::authorize($request, &$args, $roleAssignments, $enforceRestrictedSite = true) in /mnt/site/portal/ojs/lib/pkp/pages/submission/PKPSubmissionHandler.inc.php on line 216

Is possible to be a error in browsePlugin? If so, how can i fix it?

Hi @wesin,

Those warnings are cosmetic and can be ignored. You’re likely having trouble detecting MIME types; I’d suggest searching this forum for that message and following some of those threads.

Regards,
Alec Smecher
Public Knowledge Project Team

I found my problem. There was a lack of disk space.

1 Like