Off-TopicHow to fixed Birthday List On Top V3.3.8

All the various Off-Topic crap here ;)
Previous topicNext topic
User avatar

Topic Author
HarveyWNvm LLC.
Users
Users
Status: Offline
User theme: Dark
Posts: 53
Joined: Nov 3rd, '20, 14:12
    Windows 10 Chrome

How to fixed Birthday List On Top V3.3.8

Post by HarveyWNvm LLC. »

I don't know why I get this error, can you do something, I will put all the codes

Error Stage:
phpBB encountered an error building the container due to an installed extension. For this reason, all extensions have been temporarily disabled. Please try purging your forum cache. All extensions will automatically be re-enabled once the container error is resolved. If this error continues, please visit phpBB.com for support.


Exception: The file "/home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/ext/hrvy/birthdaylistontop/config/services.yml" does not contain valid YAML: The reserved indicator "@" cannot start a plain scalar; you need to quote the scalar at line 5 (near "- @template").

#0 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/vendor/symfony/dependency-injection/Loader/YamlFileLoader.php(117): Symfony\Component\DependencyInjection\Loader\YamlFileLoader->loadFile('/home/vol13_7/e...')
#1 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/phpbb/extension/di/extension_base.php(99): Symfony\Component\DependencyInjection\Loader\YamlFileLoader->load('services.yml')
#2 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/phpbb/extension/di/extension_base.php(63): phpbb\extension\di\extension_base->load_services(Object(Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationContainerBuilder))
#3 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/vendor/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php(71): phpbb\extension\di\extension_base->load(Array, Object(Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationContainerBuilder))
#4 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/vendor/symfony/http-kernel/DependencyInjection/MergeExtensionConfigurationPass.php(39): Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass->process(Object(Symfony\Component\DependencyInjection\ContainerBuilder))
#5 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/vendor/symfony/dependency-injection/Compiler/Compiler.php(140): Symfony\Component\HttpKernel\DependencyInjection\MergeExtensionConfigurationPass->process(Object(Symfony\Component\DependencyInjection\ContainerBuilder))
#6 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/vendor/symfony/dependency-injection/ContainerBuilder.php(789): Symfony\Component\DependencyInjection\Compiler\Compiler->compile(Object(Symfony\Component\DependencyInjection\ContainerBuilder))
#7 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/phpbb/di/container_builder.php(223): Symfony\Component\DependencyInjection\ContainerBuilder->compile()
#8 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/common.php(117): phpbb\di\container_builder->get_container()
#9 /home/vol13_7/epizy.com/epiz_32847785/htdocs/forum/adm/index.php(23): require('/home/vol13_7/e...')
#10 {main}
composer.json code:

Code: Select all

{
   "name": "hrvy/birthdaylistontop",
   "type": "phpbb-extension",
   "description": "Moves the Birthday list to the head of the board",
   "homepage": "https://github.com/HarveyWNvm/nFL-CS.InFo/",
   "version": "V3.3.8",
   "time": "2023-06-11",
   "keywords": "Birthday",
   "license": "GPL-3.0",
   "authors": [{
         "name": "Stefan Salvatore",
         "username": "HarveyWNvm LLC.",
         "email": "harveynomvervevo@gmail.com",
         "homepage": "https://github.com/HarveyWNvm/nFL-CS.InFo/",
         "role": "Extension Editor"
      }],
   "require": {
      "php": ">=7.4.8"
   },
   "extra": {
      "display-name": "Birthday List On Top",
      "soft-require": {
           "phpbb/phpbb": ">=3.3.8,<4.0.*@dev"
      },
      "version-check": {
         "host": "https://github.com/HarveyWNvm/nFL-CS.InFo/",
         "directory": "/versioncheck",
         "filename": "/blot__versions.json"
      }
   }
}
listener.php Code:

Code: Select all

<?php
/**
*
* @package Birthday List On Top Extension
* @copyright (c) 2023 HarveyWnvm
* @license https://opensource.org/license/gpl-3-0/ GNU General Public License version 3
*
*/

namespace hrvy\birthdaylistontop\event;

/**
* @ignore
*/
use Symfony\Component\EventDispatcher\EventSubscriberInterface;

/**
* Event listener
*/
class listener implements EventSubscriberInterface
{
   /** @var \phpbb\template\twig\twig */
   protected $template;

   /**
   * Constructor for listener
   *
   * @param \phpbb\config\config $config phpBB config
   * @param \phpbb\template\twig\twig $template phpBB template
   * @access public
   */
   public function __construct(\phpbb\template\twig\twig $template)
   {
      $this->template = $template;
   }

   /**
   * Assign functions defined in this class to event listeners in the core
   *
   * @return array
   * @static
   * @access public
   */
   static public function getSubscribedEvents()
   {
      return array(
         'core.page_header_after' => 'birthday_list',
      );
   }

   /**
   * Update the template variables
   *
   * @param object $event The event object
   * @return null
   * @access public
   */
   public function birthday_list($event)
   {
      $this->template->assign_vars(array(
         'S_DISPLAY_BIRTHDAY_LIST' => false,
      ));
   }
}
Thanks for the start :buigen: :buigen:
nFL-Cs.InFo Clock to Banner
Image
User avatar

Sniper_E
VIP
VIP
Status: Offline
User theme: Dark
Posts: 1155
Joined: Oct 14th, '14, 17:01
    Windows 10 Chrome

Re: How to fixed Birthday List On Top V3.3.8

Post by Sniper_E »

What does the code look like in your config/services.yml :question:
Image
No is NEVER an Option and NEVER is the only Option when it comes to Giving Up!™
User avatar

ssl
Donator
Donator
Status: Offline
User theme: Dark
Posts: 137
Joined: Aug 19th, '20, 10:54
    Mac OS X Opera

Re: How to fixed Birthday List On Top V3.3.8

Post by ssl »

In ext/hrvy/birthdaylistontop/config edit services.yml file
Find

Code: Select all

           - @template
Replace by

Code: Select all

           - '@template'
Clear the cache after modification


You can also use this extension: https://www.phpbb.com/customise/db/exte ... st_on_top/
phpBB: 3.3.14 | PHP: 8.3
[Some French translation of extensions]
User avatar

Topic Author
HarveyWNvm LLC.
Users
Users
Status: Offline
User theme: Dark
Posts: 53
Joined: Nov 3rd, '20, 14:12
    Windows 10 Chrome

Re: How to fixed Birthday List On Top V3.3.8

Post by HarveyWNvm LLC. »

I will do it after I get home.
User avatar

Topic Author
HarveyWNvm LLC.
Users
Users
Status: Offline
User theme: Dark
Posts: 53
Joined: Nov 3rd, '20, 14:12
    Windows 10 Chrome

Re: How to fixed Birthday List On Top V3.3.8

Post by HarveyWNvm LLC. »

Done and thank you! Lock Post
Previous topicNext topic