Add items to navbar
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 | <!-- file: hooks/header-extras.php -->
<script>
var navbar = AppGiniHelper.common.getNavbar();
var dropdown = navbar.addDropdown("Help", "question-sign", NavPosition.Right);
dropdown.addDivider("This application");
dropdown.addLink("General help", "#", "_help");
dropdown.addLink("drag & drop", "#", "_help");
dropdown.addDivider();
dropdown.addLink("Required permissions", "#", "_help");
dropdown.addLink("Help on workflow", "#", "_help");
dropdown.addDivider("Related apps");
dropdown.addLink("Help on PDF-File creation", "#", "_help");
dropdown.addDivider("Need help?");
dropdown.addLink("Support", "#", "_help");
// ...
<script>
|
Custom Text & Link
| <!-- file: hooks/header-extras.php -->
<script>
// ...
var navbar = AppGiniHelper.common.getNavbar();
navbar.addText("Click there →");
navbar.addLink("Link", "index.php", "flash");
// ...
<script>
|
Custom Search
| <!-- file: hooks/header-extras.php -->
<script>
// ...
var navbar = AppGiniHelper.common.getNavbar();
navbar.addSearch("attachments_view.php", "search in pdf files");
// ...
</script>
|
ADD LINK
| <!-- file: hooks/header-extras.php -->
<script>
// ...
dropdown.addLink("text", "href", "icon");
// optional 4th parameter: target (string), for example "_self", "_blank", "tab_name"
// ...
</script>
|
ADD BUTTON
| <!-- file: hooks/header-extras.php -->
<script>
// ...
dropdown.addButton("text", function() { /* your code here*/ }, "icon");
// ...
</script>
|
ADD DIVIDER LINE
| <!-- file: hooks/header-extras.php -->
<script>
// ...
dropdown.addDivider();
// ...
</script>
|
ADD DIVIDER WITH TEXT
| <!-- file: hooks/header-extras.php -->
<script>
// ...
dropdown.addDivider("More");
// ...
</script>
|
Add custom search input field
| <!-- file: hooks/header-extras.php -->
<script>
// ...
AppGiniHelper.common.getNavbar().addSearch("url", "placeholder", "value");
// ...
</script>
|
See also