Pastebin

Sitelogo responsive

von Kirk (12.05.2022 21:01)
Beschreibung:
site_logo_responsive_module.php ohne $mode Auswertung
Snippet erstellt:
12.05.2022 21:01
Snippet wird automatisch gelöscht:
09.09.2022 21:01

Dein Code:
  1. <?php
  2. /**
  3. *
  4. * Sitelogo responsive extension for the phpBB Forum Software package.
  5. * @copyright (c) 2017 - 2022 Kirk https://reyno41.bplaced.net/phpbb
  6. * @license GNU General Public License, version 2 (GPL-2.0-only)
  7. *
  8. */
  9.  
  10. namespace kirk\slr\acp;
  11.  
  12. class site_logo_responsive_module
  13. {
  14.         public $page_title;
  15.         public $tpl_name;
  16.         public $u_action;
  17.  
  18.         public function __construct()
  19.         {
  20.                 global $phpbb_container;
  21.                 $this->phpbb_container          = $phpbb_container;
  22.                 $this->language                         = $phpbb_container->get('language');
  23.         }
  24.  
  25.         public function main()
  26.         {
  27.                 /** @var \kirk.slr.controller.acp $acp_controller */
  28.                 $acp_controller         = $this->phpbb_container->get('kirk.slr.controller.acp');
  29.  
  30.                 // Load a template from adm/style for our ACP page
  31.                 $this->tpl_name         = 'acp_site_logo_responsive_settings';
  32.  
  33.                 // Set the page title for our ACP page
  34.                 $this->page_title       = $this->language->lang('ACP_SITE_LOGO_RESPONSIVE') . ' &hyphen; ' . $this->language->lang('ACP_SITE_LOGO_RESPONSIVE_RESPONSIVE_SETTINGS');
  35.  
  36.                 // Make the $u_action url available in our ACP controller
  37.                 $acp_controller->set_page_url($this->u_action);
  38.  
  39.                 $acp_controller->{'slr_settings'}();
  40.         }
  41. }

Quellcode

Hier kannst du den Code kopieren und ihn in deinen bevorzugten Editor einfügen. Alternativ kannst du den gesamten Eintrag auch als Datei herunterladen.