mirror of
https://github.com/sbrl/Pepperminty-Wiki.git
synced 2024-11-25 17:23:00 +00:00
Add link to tag list at the bottom of the list of apges that belong to a specific tag
This commit is contained in:
parent
e30fe16748
commit
ea10480183
3 changed files with 9 additions and 5 deletions
|
@ -2859,7 +2859,7 @@ register_module([
|
||||||
{
|
{
|
||||||
$content .= " <li><a href='?action=list-tags&tag=" . rawurlencode($tag) . "' class='mini-tag'>$tag</a></li>\n";
|
$content .= " <li><a href='?action=list-tags&tag=" . rawurlencode($tag) . "' class='mini-tag'>$tag</a></li>\n";
|
||||||
}
|
}
|
||||||
$content .= "</ul>";
|
$content .= "</ul>\n";
|
||||||
|
|
||||||
exit(page_renderer::render("All tags - $settings->sitename", $content));
|
exit(page_renderer::render("All tags - $settings->sitename", $content));
|
||||||
}
|
}
|
||||||
|
@ -2880,6 +2880,8 @@ register_module([
|
||||||
$content = "<h1>$tag</h1>\n";
|
$content = "<h1>$tag</h1>\n";
|
||||||
$content .= generate_page_list($pagelist);
|
$content .= generate_page_list($pagelist);
|
||||||
|
|
||||||
|
$content .= "<p>(<a href='?action=list-tags'>All tags</a>)</p>\n";
|
||||||
|
|
||||||
exit(page_renderer::render("$tag - Page List - $settings->sitename", $content));
|
exit(page_renderer::render("$tag - Page List - $settings->sitename", $content));
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -2910,7 +2912,7 @@ function generate_page_list($pagelist)
|
||||||
<time title='" . date("l jS \of F Y \a\\t h:ia T", $pageindex->$pagename->lastmodified) . "'>" . human_time_since($pageindex->$pagename->lastmodified) . "</time>
|
<time title='" . date("l jS \of F Y \a\\t h:ia T", $pageindex->$pagename->lastmodified) . "'>" . human_time_since($pageindex->$pagename->lastmodified) . "</time>
|
||||||
<span class='tags'>$tags</span></li>";
|
<span class='tags'>$tags</span></li>";
|
||||||
}
|
}
|
||||||
$result .= " </ul>";
|
$result .= " </ul>\n";
|
||||||
|
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
|
@ -113,7 +113,7 @@
|
||||||
"author": "Starbeamrainbowlabs",
|
"author": "Starbeamrainbowlabs",
|
||||||
"description": "Adds a page that lists all the pages in the index along with their metadata.",
|
"description": "Adds a page that lists all the pages in the index along with their metadata.",
|
||||||
"id": "page-list",
|
"id": "page-list",
|
||||||
"lastupdate": 1450292650,
|
"lastupdate": 1450608845,
|
||||||
"optional": false
|
"optional": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
|
@ -41,7 +41,7 @@ register_module([
|
||||||
{
|
{
|
||||||
$content .= " <li><a href='?action=list-tags&tag=" . rawurlencode($tag) . "' class='mini-tag'>$tag</a></li>\n";
|
$content .= " <li><a href='?action=list-tags&tag=" . rawurlencode($tag) . "' class='mini-tag'>$tag</a></li>\n";
|
||||||
}
|
}
|
||||||
$content .= "</ul>";
|
$content .= "</ul>\n";
|
||||||
|
|
||||||
exit(page_renderer::render("All tags - $settings->sitename", $content));
|
exit(page_renderer::render("All tags - $settings->sitename", $content));
|
||||||
}
|
}
|
||||||
|
@ -62,6 +62,8 @@ register_module([
|
||||||
$content = "<h1>$tag</h1>\n";
|
$content = "<h1>$tag</h1>\n";
|
||||||
$content .= generate_page_list($pagelist);
|
$content .= generate_page_list($pagelist);
|
||||||
|
|
||||||
|
$content .= "<p>(<a href='?action=list-tags'>All tags</a>)</p>\n";
|
||||||
|
|
||||||
exit(page_renderer::render("$tag - Page List - $settings->sitename", $content));
|
exit(page_renderer::render("$tag - Page List - $settings->sitename", $content));
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -92,7 +94,7 @@ function generate_page_list($pagelist)
|
||||||
<time title='" . date("l jS \of F Y \a\\t h:ia T", $pageindex->$pagename->lastmodified) . "'>" . human_time_since($pageindex->$pagename->lastmodified) . "</time>
|
<time title='" . date("l jS \of F Y \a\\t h:ia T", $pageindex->$pagename->lastmodified) . "'>" . human_time_since($pageindex->$pagename->lastmodified) . "</time>
|
||||||
<span class='tags'>$tags</span></li>";
|
<span class='tags'>$tags</span></li>";
|
||||||
}
|
}
|
||||||
$result .= " </ul>";
|
$result .= " </ul>\n";
|
||||||
|
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue