This commit is contained in:
Ty Clifford
2026-07-03 07:31:09 -04:00
commit cebb0d3af1
800 changed files with 89782 additions and 0 deletions
+9
View File
@@ -0,0 +1,9 @@
{
"amount-of-items": "Antal af emner",
"home-link": "Hjemme link",
"plugin-data": {
"description": "Navigationsmenu med overordnede og underordnede sider til sidepanelet.",
"name": "Navigation"
},
"show-the-home-link-on-the-sidebar": "Vis hjemme linket på sidepanelet."
}
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Navigation",
"description": "Menü für die Anzeige von veröffentlichten und statischen Inhalten."
},
"home-link": "Hauptseite zeigen",
"show-the-home-link-on-the-sidebar": "Show the home link on the sidebar.",
"amount-of-items": "Anzahl Inhalte"
}
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Navigation",
"description": "Menü für die Anzeige von veröffentlichten und statischen Inhalten."
},
"home-link": "Hauptseite zeigen",
"show-the-home-link-on-the-sidebar": "Show the home link on the sidebar.",
"amount-of-items": "Anzahl Inhalte"
}
+10
View File
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Navigation",
"description": "Navigation menu with parent and child pages for the sidebar."
},
"home-link": "Home link",
"show-the-home-link-on-the-sidebar": "Show the home link on the sidebar.",
"amount-of-items": "Amount of items"
}
+10
View File
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Barra de Navegación",
"description": "Cree tu propio menú de navegación"
},
"home-link": "Enlace de inicio",
"show-the-home-link-on-the-sidebar": "Mostrar el vínculo de inicio en la barra de navegación.",
"amount-of-items": "Cantidad de artículos"
}
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "ناوبری",
"description": "منوی ناوبری به همراه والد و صفحات پایین تر برای نوار کناری."
},
"home-link": "لینک فهرست",
"show-the-home-link-on-the-sidebar": "نمایش لینک فهرست در نوار کناری.",
"amount-of-items": "تعداد آیتم ها"
}
+10
View File
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Navigation",
"description": "Créez votre propre menu de navigation avec les dernières pages ou pages statiques."
},
"home-link": "Lien de la page daccueil",
"show-the-home-link-on-the-sidebar": "Afficher un lien vers la page daccueil dans la barre latérale.",
"amount-of-items": "Quantité darticles"
}
+10
View File
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Navigazione",
"description": "Crea il tuo menu di navigazione con le ultime pagine o con le pagine statiche."
},
"home-link": "Link Home",
"show-the-home-link-on-the-sidebar": "Mostra il collegamento alla home nella barra laterale.",
"amount-of-items": "Quantità di voci"
}
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Navigation",
"description": "サイドバーに親ページと子ページを表示するナビゲーションメニューです。"
},
"home-link": "ホームリンク",
"show-the-home-link-on-the-sidebar": "サイドバーにホームリンクを表示する",
"amount-of-items": "アイテム数"
}
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Navigatiemenu",
"description": "Toont een navigatiemenu met twee niveau's in de zijbalk."
},
"home-link": "Link naar startpagina",
"show-the-home-link-on-the-sidebar": "Toon een link naar de startpagina.",
"amount-of-items": "Aantal items"
}
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Навигация",
"description": "Меню навигации с родительскими и дочерними страницами/записями для боковой панели сайта."
},
"home-link": "Ссылка на домашнюю страницу",
"show-the-home-link-on-the-sidebar": "Показать ссылку на домашнюю страницу на боковой панели сайта.",
"amount-of-items": "Количество элементов"
}
+10
View File
@@ -0,0 +1,10 @@
{
"plugin-data":
{
"name": "Gezinti menüsü",
"description": "Kenar çubuğu için üst ve alt sayfaları içeren gezinme menüsü."
},
"home-link": "Ana sayfa bağlantısı",
"show-the-home-link-on-the-sidebar": "Kenar çubuğundaki ev bağlantısını göster.",
"amount-of-items": "Öge sayısı"
}
+10
View File
@@ -0,0 +1,10 @@
{
"author": "Bludit",
"email": "",
"website": "https://plugins.bludit.com",
"version": "3.22.0",
"releaseDate": "2026-05-10",
"license": "MIT",
"compatible": "3.22",
"notes": ""
}
+125
View File
@@ -0,0 +1,125 @@
<?php
class pluginNavigation extends Plugin
{
public function init()
{
// Fields and default values for the database of this plugin
$this->dbFields = array(
'label' => 'Navigation',
'homeLink' => true,
'numberOfItems' => 5
);
}
// Method called on the settings of the plugin on the admin area
public function form()
{
global $L;
$html = '<div class="alert alert-primary" role="alert">';
$html .= $this->description();
$html .= '</div>';
$html .= '<div>';
$html .= '<label>' . $L->get('Label') . '</label>';
$html .= '<input id="jslabel" name="label" type="text" dir="auto" value="' . htmlspecialchars($this->getValue('label'), ENT_QUOTES, 'UTF-8') . '">';
$html .= '<span class="tip">' . $L->get('This title is almost always used in the sidebar of the site') . '</span>';
$html .= '</div>';
$html .= '<div>';
$html .= '<label>' . $L->get('Home link') . '</label>';
$html .= '<select name="homeLink">';
$html .= '<option value="true" ' . ($this->getValue('homeLink') === true ? 'selected' : '') . '>' . $L->get('Enabled') . '</option>';
$html .= '<option value="false" ' . ($this->getValue('homeLink') === false ? 'selected' : '') . '>' . $L->get('Disabled') . '</option>';
$html .= '</select>';
$html .= '<span class="tip">' . $L->get('Show the home link on the sidebar') . '</span>';
$html .= '</div>';
if (ORDER_BY == 'date') {
$html .= '<div>';
$html .= '<label>' . $L->get('Amount of items') . '</label>';
$html .= '<input id="jsnumberOfItems" name="numberOfItems" type="text" dir="auto" value="' . $this->getValue('numberOfItems') . '">';
$html .= '</div>';
}
return $html;
}
// Method called on the sidebar of the website
public function siteSidebar()
{
global $L;
global $url;
global $site;
global $pages;
// HTML for sidebar
$html = '<div class="plugin plugin-navigation">';
// Print the label if not empty
$label = $this->getValue('label');
if (!empty($label)) {
$html .= '<h2 class="plugin-label">' . htmlspecialchars($L->g($label), ENT_QUOTES, 'UTF-8') . '</h2>';
}
$html .= '<div class="plugin-content">';
$html .= '<ul>';
// Show Home page link
if ($this->getValue('homeLink')) {
$html .= '<li>';
$html .= '<a href="' . $site->url() . '">' . $L->get('Home page') . '</a>';
$html .= '</li>';
}
// Pages order by position
if (ORDER_BY == 'position') {
// Get parents
$parents = buildParentPages();
foreach ($parents as $parent) {
$html .= '<li class="parent">';
$html .= '<a href="' . $parent->permalink() . '">' . $parent->title() . '</a>';
if ($parent->hasChildren()) {
// Get children
$children = $parent->children();
$html .= '<ul class="child">';
foreach ($children as $child) {
$html .= '<li class="child">';
$html .= '<a class="child" href="' . $child->permalink() . '">' . $child->title() . '</a>';
$html .= '</li>';
}
$html .= '</ul>';
}
$html .= '</li>';
}
}
// Pages order by date
else {
// List of published pages
$onlyPublished = true;
$pageNumber = 1;
$numberOfItems = $this->getValue('numberOfItems');
$publishedPages = $pages->getList($pageNumber, $numberOfItems, $onlyPublished);
foreach ($publishedPages as $pageKey) {
try {
$page = new Page($pageKey);
$html .= '<li>';
$html .= '<a href="' . $page->permalink() . '">' . $page->title() . '</a>';
$html .= '</li>';
} catch (Exception $e) {
// Continue
}
}
}
$html .= '</ul>';
$html .= '</div>';
$html .= '</div>';
return $html;
}
}