Commit | Line | Data |
---|---|---|
8659eb86 | 1 | # User Menu Package Installation Plugin |
c8b654e0 MS |
2 | |
3 | Registers new user menu items. | |
4 | ||
5 | ## Components | |
6 | ||
7 | Each item is described as an `<usermenuitem>` element with the mandatory attribute `name`. | |
8 | ||
9 | ### `<parent>` | |
10 | ||
ca3f33cf | 11 | <span class="label label-info">Optional</span> |
c8b654e0 MS |
12 | |
13 | The item’s parent item. | |
14 | ||
15 | ### `<showorder>` | |
16 | ||
ca3f33cf | 17 | <span class="label label-info">Optional</span> |
c8b654e0 MS |
18 | |
19 | Specifies the order of this item within the parent item. | |
20 | ||
21 | ### `<controller>` | |
22 | ||
23 | The fully qualified class name of the target controller. | |
24 | If not specified this item serves as a category. | |
25 | ||
26 | ### `<link>` | |
27 | ||
28 | Additional components if `<controller>` is set, | |
29 | the full external link otherwise. | |
30 | ||
31 | ### `<iconclassname>` | |
32 | ||
c1b5007e | 33 | !!! info "Use an icon only for top-level items." |
c8b654e0 MS |
34 | |
35 | Name of the Font Awesome icon class. | |
36 | ||
37 | ### `<options>` | |
38 | ||
ca3f33cf | 39 | <span class="label label-info">Optional</span> |
c8b654e0 MS |
40 | |
41 | The options element can contain a comma-separated list of options of which at least one needs to be enabled for the menu item to be shown. | |
42 | ||
43 | ### `<permissions>` | |
44 | ||
ca3f33cf | 45 | <span class="label label-info">Optional</span> |
c8b654e0 MS |
46 | |
47 | The permissions element can contain a comma-separated list of permissions of which the active user needs to have at least one for the menu item to be shown. | |
48 | ||
49 | ### `<classname>` | |
50 | ||
51 | The name of the class providing the user menu item’s behaviour, | |
52 | the class has to implement the `wcf\system\menu\user\IUserMenuItemProvider` interface. | |
53 | ||
54 | ||
55 | ||
56 | ## Example | |
57 | ||
9a3f5fa3 MS |
58 | {jinja{ codebox( |
59 | "xml", | |
60 | "package/pip/userMenu.xml", | |
61 | "userMenu.xml" | |
62 | ) }} |