Ich bin auch schon etwas weiter. Ich bekomme aber zwei Warnungen des PHP-Code-Sniffers angezeigt, für die main-listener.php und für die constants.php. Die Meldungen sind gleich, ich habe hier mal die für die constans.php eingefügt:
Code: Alles auswählen
FILE: hjw/calendar/includes/constants.php
--------------------------------------------------------------------------------
FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
--------------------------------------------------------------------------------
1 | WARNING | A file should declare new symbols (classes, functions,
| | constants, etc.) and cause no other side effects, or it should
| | execute logic with side effects, but should not do both. The
| | first symbol is defined on line 18 and the first side effect is
| | on line 11.
--------------------------------------------------------------------------------
Code: Alles auswählen
<?php
/**
*
* @package hjw calendar Extension
* @copyright (c) 2020 hjw
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
*
*/
if (!defined('IN_PHPBB'))
{
(Zeile 11) exit;
}
namespace hjw\calendar\includes;
if (!defined('CALENDAR_TABLE'))
{
(Zeile 18) define('CALENDAR_TABLE', $this->table_prefix . 'calendar');
}if (!defined('CALENDAR_PARTICIPANTS_TABLE'))
{
define('CALENDAR_PARTICIPANTS_TABLE', $this->table_prefix . 'calendar_participants');
}
if (!defined('CALENDAR_EVENT_TABLE'))
{
define('CALENDAR_EVENT_TABLE', $this->table_prefix . 'calendar_event');
}
if (!defined('CALENDAR_EVENT_LIST_TABLE'))
{
define('CALENDAR_EVENT_LIST_TABLE', $this->table_prefix . 'calendar_event_list');
}
if (!defined('CALENDAR_SPECIAL_DAYS_TABLE'))
{
define('CALENDAR_SPECIAL_DAYS_TABLE', $this->table_prefix . 'calendar_special_days');
}
if (!defined('CALENDAR_FORUMS_TABLE'))
{
define('CALENDAR_FORUMS_TABLE', $this->table_prefix . 'calendar_forums');
}
if (!defined('FOOTB_MATCHES_TABLE'))
{
define('FOOTB_MATCHES_TABLE', $this->table_prefix . 'footb_matches');
}
if (!defined('FOOTB_TEAMS_TABLE'))
{
define('FOOTB_TEAMS_TABLE', $this->table_prefix . 'footb_teams');
}