Closed rshost closed 1 year ago
@asmecher this is fixed in the repository. It looks like the bootstrap3
theme needs a release from the stable-3_3_0
branch to support 3.3.x. Is that something you can do fairly quickly? Or would you rather wait until we have time to fix a few more issues for it?
I've released a new build of bootstrap3; is this issue ready to be closed?
Thanks for the quick fix!
Describe the bug
When calling the OJS index site with Bootstrap3 theme plugin (version 3.2.0.4 from plugin gallery) enabled, the following PHP Fatal Error is produced:
PHP Fatal error: Uncaught Error: Call to a member function eof() on array in /var/www/html/ojs/lib/pkp/classes/template/PKPTemplateManager.inc.php:1447 ...
This originates from line 50 in
indexSite.tpl
iterating over all journals:{iterate from=journals item=journal}
Indeed line 80 in
IndexHandler.inc.php
passes on an array:'journals' => $journalDao->getAll(true)->toArray(),
,while
PKPTemplateManager.inc.php -> smartyIterate
seems to expect an iterator:$iterator = $smarty->getTemplateVars($params['from']);
The default index site uses
{foreach from=$journals item=journal}
instead.Looking through the Bootstrap3 repo the main branch and the branch stable-3_3_0 (which according to version.xml is 3.2.0.3) both use {foreach ...}. I couldn't find a version 3.2.0.4 in the repo. To me it looks like the archive the plugin gallery points to should be updated.
To Reproduce Steps to reproduce the behavior:
What application are you using? OJS version 3.3.0-11