Tipmoose
Member
I am running into some sort of pathing problem while trying to create a new widget/widget definition. Im creating the widget class in my addons folder under AntlerApps/MostUsersOnline/XF/Widget. The widget I am creating has to extend XF\Widget\AbstractWidget. Any attempt to reference the XF version of AbstractWidget from my class fails with the below error. I have tried setting up class extensions for AbstractWidget to my widget. Same error. The *only* thing that will make this work is if I have an AbstractWidget.php file (and class) in the same location as my own widget. That can't be the right way to do this.
Are there any special rules needed for creating ones own widget that I'm not following? I have to be making some kind of basic error.
The error I am getting is:
Fatal error: Class 'AntlerApps\MostUsersOnline\XF\Widget\AbstractWidget' not found in /var/www/public/xenforo/src/addons/AntlerApps/MostUsersOnline/XF/Widget/MostUsersOnline.php on line 5
Here is the content of my widget class
<?php
namespace AntlerApps\MostUsersOnline\XF\Widget;
class MostUsersOnline extends AbstractWidget
{
}
Are there any special rules needed for creating ones own widget that I'm not following? I have to be making some kind of basic error.
The error I am getting is:
Fatal error: Class 'AntlerApps\MostUsersOnline\XF\Widget\AbstractWidget' not found in /var/www/public/xenforo/src/addons/AntlerApps/MostUsersOnline/XF/Widget/MostUsersOnline.php on line 5
Here is the content of my widget class
<?php
namespace AntlerApps\MostUsersOnline\XF\Widget;
class MostUsersOnline extends AbstractWidget
{
}