How To Create A Backend Widget

Otsikko

OldNew
11How To Create A Backend Widget

Kestolinkki

OldNew
11how_to_create_a_backend_widget

Sisältö

OldNew
1# How To Create a Backend Widget
12
3Backend widgets are boxes of content that are displayed in the backend
4dashboard. Widgets are plug 'n play, meaning that if you upload a
5widget folder it is automatically loaded. A widget is defined by a
6folder named .widget at the end e.g. admin/mywidget.widget/. Inside the
7folder you need to create a configuration file config.inc.php that
8defines the widget and the file to load. See below for an example.
9
10```php admin/mywidget.widget/config.inc.php
11
12 return [
13 'name' => 'My App',
14 'file' => 'widget.inc.php', // The file to load that is holding the content
15 'priority' => 0,
16 ];
17```
18
19```php admin/mywidget.widget/widget.inc.php
20
21Hello World
22
23Lorem ipsum dolor
24```
25
26## See Also
27
28* [How to Create An Admin App](how_to_create_an_admin_app)

Muokannut litecart 29 jouluk. 2023 kello 04:28

This website uses no cookies and no third party tracking technology. We think we can do better than others and really think about your privacy.