Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 4.2.0 nicht PHP 8 kompatibel #17

Open
gitpurzel opened this issue Jan 5, 2022 · 0 comments
Open

Version 4.2.0 nicht PHP 8 kompatibel #17

gitpurzel opened this issue Jan 5, 2022 · 0 comments

Comments

@gitpurzel
Copy link

Es dürfte aber leicht zu korrigieren sein.
Die Funktion join() ist ein Alias auf implode(). Die Parameter dürfen bereits seit PHP4 vertauscht sein und müssen es seit PHP8; siehe https://www.php.net/manual/de/function.implode.php

$ diff CalendarImport.php.orig CalendarImport.php
39c39
<         $arrCalendars = $this->Database->prepare("SELECT id FROM tl_calendar WHERE id IN (" . join($arrCalendars, ',') . ") AND ical_source = ?")
---
>           $arrCalendars = $this->Database->prepare("SELECT id FROM tl_calendar WHERE id IN (" . join(',', $arrCalendars) . ") AND ical_source = ?")
839c839
<                             $arrFields['cep_participants'] = join($attendees, ',');
---
>                             $arrFields['cep_participants'] = join(',', $attendees);
854c854
<                             $arrFields['cep_contact'] = join($contacts, ',');
---
>                             $arrFields['cep_contact'] = join(',', $contacts);

und

$ diff ContentICal.php.orig ContentICal.php      
94c94
<         $this->Template->href = $this->addToUrl("ical=" . join($arrCalendars, ',') . "&title=" . urlencode($this->strTitle));
---
>         $this->Template->href = $this->addToUrl("ical=" . join(',', $arrCalendars) . "&title=" . urlencode($this->strTitle));

Siehe auch https://community.contao.org/de/showthread.php?82244-die-Erweiterung-und-PHP-8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant