OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



OJS error: Cannot use a scalar value as an array

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
The Public Knowledge Project Support Forum is moving to http://forum.pkp.sfu.ca

This forum will be maintained permanently as an archived historical resource, but all new questions should be added to the new forum. Questions will no longer be monitored on this old forum after March 30, 2015.

OJS error: Cannot use a scalar value as an array

Postby martinv » Tue Jan 08, 2013 7:44 am

Hi,

A user has been setting up a journal on our multi-journal OJS v. 2.3.8.0 site. With display_errors and show_stacktrace on, he encountered the following errors in a number of places, eg. on the Journal's "About" page (http://journals.domain/index.php/jnl-abbr/about):

ojs2 has produced an error Message: WARNING: Cannot use a scalar value as an array In file: C:\Inetpub\wwwroot\path-to\ojs\classes\journal\JournalSettingsDAO.inc.php At line: 80 Stacktrace: Server info: OS: WINNT PHP Version: 5.2.6 Apache Version: N/A DB Driver: mysql DB server version: 4.1.12a-nt-max-log

So far, the error has not prevented the user from completing an action and turning stacktrace and error display off hides the messages, but I am concerned that severe problems (such as those mentioned in viewtopic.php?f=8&t=9379 "Article editorial process page broken for all roles") may occur once the journal becomes actively used.

I have not found any null values in the journal_settings table. Locale is either an empty string or 'en_US'.

This journal was created after upgrading from OJS 2.3.6. Only this one journal's about pages show the error, other journals created previously under earlier versions do not.

I would appreciate assistance with solving this error. Please let me know if any additional information is required. System info and the full stack trace follow below the signature.

Regards,
Martin

Basic system info:
OS platform WINNT
PHP version 5.2.6
Apache version Not available
Database driver mysql
Database server version 4.1.12a-nt-max-log
Microsoft IIS 6.0

Stack trace:
ojs2 has produced an error Message: WARNING: Cannot use a scalar value as an array In file: C:\Inetpub\wwwroot\software\pkp\ojs\classes\journal\JournalSettingsDAO.inc.php At line: 80 Stacktrace: File: C:\Inetpub\wwwroot\software\pkp\ojs\classes\journal\JournalSettingsDAO.inc.php line 80 Function: PKPApplication->errorHandler(2, "Cannot use a scalar value as an array", "C:\Inetpub\wwwroot\software\pkp\ojs\classes\journal\JournalSettingsDAO.inc.php", 80, Array(5)) File: C:\Inetpub\wwwroot\software\pkp\ojs\pages\about\AboutHandler.inc.php line 43 Function: JournalSettingsDAO->getJournalSettings("3") File: (unknown) line (unknown) Function: AboutHandler->index(Array(0), Object(Request)) File: C:\Inetpub\wwwroot\software\pkp\ojs\lib\pkp\classes\core\PKPRouter.inc.php line 370 Function: call_user_func(Array(2), Array(0), Object(Request)) File: C:\Inetpub\wwwroot\software\pkp\ojs\lib\pkp\classes\core\PKPPageRouter.inc.php line 266 Function: PKPRouter->_authorizeInitializeAndCallRequest(Array(2), Object(Request), Array(0), False) File: C:\Inetpub\wwwroot\software\pkp\ojs\lib\pkp\classes\core\Dispatcher.inc.php line 129 Function: PKPPageRouter->route(Object(Request)) File: C:\Inetpub\wwwroot\software\pkp\ojs\lib\pkp\classes\core\PKPApplication.inc.php line 180 Function: Dispatcher->dispatch(Object(Request)) File: C:\Inetpub\wwwroot\software\pkp\ojs\index.php line 65 Function: PKPApplication->execute() Server info: OS: WINNT PHP Version: 5.2.6 Apache Version: N/A DB Driver: mysql DB server version: 4.1.12a-nt-max-log
martinv
 
Posts: 2
Joined: Tue Jan 08, 2013 7:30 am

Re: OJS error: Cannot use a scalar value as an array

Postby martinv » Tue Jan 08, 2013 8:20 am

PS: date.timezone is set in php.ini
martinv
 
Posts: 2
Joined: Tue Jan 08, 2013 7:30 am

Re: OJS error: Cannot use a scalar value as an array

Postby asmecher » Sat Feb 28, 2015 8:11 am

Hi all,

See this thread:
viewtopic.php?f=8&t=10899#p42264

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 10015
Joined: Wed Aug 10, 2005 12:56 pm


Return to OJS Technical Support

Who is online

Users browsing this forum: Google [Bot], Yahoo [Bot] and 4 guests