JustCarmen / webtrees-fancy-research-links

Fancy Research Links Module for webtrees
http://justcarmen.nl
GNU General Public License v3.0
26 stars 12 forks source link

Error on changing language #68

Closed Manja-S closed 2 years ago

Manja-S commented 2 years ago

I've got a problem, apparently with …/modules_v4/jc-fancy-research-links/resources/views/sidebar.phtml.

When I look at a person and then change the language to any other language than Afrikaans or Nederlands, I get a page full of errors instead of the translated page. The same problem occurs on your own web page, you could try to look at the information on for example Lena Knegt in English.

Errors:

Invalid argument supplied for foreach() …/modules_v4/jc-fancy-research-links/resources/views/sidebar.phtml:23
#0 …/modules_v4/jc-fancy-research-links/resources/views/sidebar.phtml(23): Fisharebest\Webtrees\Webtrees::Fisharebest\Webtrees\{closure}(2, 'Invalid argumen...', '/var/www/qb1045...', 23, Array)
#1 …/app/View.php(183): include('/var/www/qb1045...')
#2 …/app/View.php(278): Fisharebest\Webtrees\View->render()
#3 …/app/Helpers/functions.php(145): Fisharebest\Webtrees\View::make('_jc-fancy-resea...', Array)
#4 …/modules_v4/jc-fancy-research-links/FancyResearchLinksModule.php(249): view('_jc-fancy-resea...', Array)
#5 …/modules_v4/vesta_classic_look_and_feel/resources/views/individual-page-sidebars.phtml(33): JustCarmen\Webtrees\Module\FancyResearchLinks\FancyResearchLinksModule->getSidebarContent(Object(Cissee\WebtreesExt\IndividualExt))
#6 …/app/View.php(183): include('/var/www/qb1045...')
#7 …/app/View.php(278): Fisharebest\Webtrees\View->render()
#8 …/app/Helpers/functions.php(145): Fisharebest\Webtrees\View::make('individual-page...', Array)
#9 …/modules_v4/vesta_classic_look_and_feel/resources/views/individual-page.phtml(62): view('individual-page...', Array)
#10 …/app/View.php(183): include('/var/www/qb1045...')
#11 …/app/View.php(278): Fisharebest\Webtrees\View->render()
#12 …/app/Helpers/functions.php(145): Fisharebest\Webtrees\View::make('individual-page', Array)
#13 …/app/Http/ViewResponseTrait.php(50): view('individual-page', Array)
#14 …/app/Http/RequestHandlers/IndividualPage.php(140): Fisharebest\Webtrees\Http\RequestHandlers\IndividualPage->viewResponse('individual-page', Array)
#15 …/app/Http/Middleware/RequestHandler.php(54): Fisharebest\Webtrees\Http\RequestHandlers\IndividualPage->handle(Object(Nyholm\Psr7\ServerRequest))
#16 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\RequestHandler->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#17 …/modules_v4/vesta_research_suggestions/ResearchSuggestionsModule.php(277): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#18 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Cissee\Webtrees\Module\ResearchSuggestions\ResearchSuggestionsModule->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#19 …/app/Module/HitCountFooterModule.php(154): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#20 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Module\HitCountFooterModule->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#21 …/app/Module/CheckForNewVersion.php(115): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#22 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Module\CheckForNewVersion->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#23 …/app/Http/Middleware/CheckCsrf.php(80): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#24 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\CheckCsrf->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#25 …/vendor/oscarotero/middleland/src/Dispatcher.php(118): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#26 …/app/Webtrees.php(275): Middleland\Dispatcher->dispatch(Object(Nyholm\Psr7\ServerRequest))
#27 …/app/Http/Middleware/Router.php(153): Fisharebest\Webtrees\Webtrees::dispatch(Object(Nyholm\Psr7\ServerRequest), Array)
#28 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\Router->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#29 …/app/Http/Middleware/BootModules.php(60): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#30 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\BootModules->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#31 …/app/Http/Middleware/RegisterGedcomTags.php(54): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#32 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\RegisterGedcomTags->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#33 …/app/Http/Middleware/LoadRoutes.php(75): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#34 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\LoadRoutes->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#35 …/app/Http/Middleware/CheckForNewVersion.php(65): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#36 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\CheckForNewVersion->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#37 …/app/Http/Middleware/UseTransaction.php(45): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#38 …/vendor/illuminate/database/Concerns/ManagesTransactions.php(29): Fisharebest\Webtrees\Http\Middleware\UseTransaction::Fisharebest\Webtrees\Http\Middleware\{closure}(Object(Illuminate\Database\MySqlConnection))
#39 …/app/Http/Middleware/UseTransaction.php(46): Illuminate\Database\Connection->transaction(Object(Closure), 3)
#40 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseTransaction->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#41 …/app/Http/Middleware/DoHousekeeping.php(73): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#42 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\DoHousekeeping->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#43 …/app/Http/Middleware/UseTheme.php(69): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#44 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseTheme->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#45 …/app/Http/Middleware/CheckForMaintenanceMode.php(51): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#46 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\CheckForMaintenanceMode->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#47 …/app/Http/Middleware/UseLanguage.php(71): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#48 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseLanguage->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#49 …/app/Http/Middleware/UseSession.php(78): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#50 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseSession->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#51 …/app/Http/Middleware/UpdateDatabaseSchema.php(57): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#52 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UpdateDatabaseSchema->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#53 …/app/Http/Middleware/UseDatabase.php(118): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#54 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseDatabase->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#55 …/app/Http/Middleware/BadBotBlocker.php(233): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#56 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\BadBotBlocker->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#57 …/app/Http/Middleware/CompressResponse.php(73): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#58 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\CompressResponse->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#59 …/app/Http/Middleware/ContentLength.php(40): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#60 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\ContentLength->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#61 …/vendor/middlewares/client-ip/src/ClientIp.php(65): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#62 …/app/Http/Middleware/ClientIp.php(47): Middlewares\ClientIp->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#63 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\ClientIp->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#64 …/app/Http/Middleware/HandleExceptions.php(90): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#65 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\HandleExceptions->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#66 …/app/Http/Middleware/BaseUrl.php(79): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#67 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\BaseUrl->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#68 …/app/Http/Middleware/ReadConfigIni.php(68): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#69 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\ReadConfigIni->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#70 …/app/Http/Middleware/SecurityHeaders.php(48): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#71 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\SecurityHeaders->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#72 …/app/Http/Middleware/EmitResponse.php(57): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#73 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\EmitResponse->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#74 …/vendor/oscarotero/middleland/src/Dispatcher.php(118): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#75 …/app/Webtrees.php(275): Middleland\Dispatcher->dispatch(Object(Nyholm\Psr7\ServerRequest))
#76 …/app/Webtrees.php(262): Fisharebest\Webtrees\Webtrees::dispatch(Object(Nyholm\Psr7\ServerRequest), Array)
#77 …/index.php(51): Fisharebest\Webtrees\Webtrees->httpRequest()
#78 {main}

Versions: Webtrees 2.1.7 Fancy Research Links: 2.3.0 Vesta: 2.1.7.1.0 (as well as previous version Vesta.2.1.7.0.2, I updated Vesta today but the errors persisted)

JustCarmen commented 2 years ago

Thanks Manja for reporting this problem. I was trying to figure out what was causing the previously reported error (#67), but I couldn't figure it out. I was sure it only happened to unlogged visitors, but I couldn't reproduce it myself. Because I never thought of changing the language.

I haven't solved it yet, but I now know what to look out for. To be continued.

Manja-S commented 2 years ago

Thank you!