mirror of
https://github.com/danpros/htmly.git
synced 2026-04-19 03:56:21 +05:30
Always add slash
This commit is contained in:
parent
82a5cce7a4
commit
5c5b94e83a
2 changed files with 3 additions and 3 deletions
|
|
@ -2021,7 +2021,7 @@ function parseNode($node, $child = null) {
|
|||
}
|
||||
}
|
||||
|
||||
$li .= '<a href="'.$node->slug.'">'.$node->name.'</a>';
|
||||
$li .= '<a href="'.htmlspecialchars(rtrim($node->slug, '/') . '/', FILTER_SANITIZE_URL).'">'.$node->name.'</a>';
|
||||
if (isset($node->children)) {
|
||||
$li .= parseNodes($node->children, true, null);
|
||||
}
|
||||
|
|
@ -2047,7 +2047,7 @@ function parseNode($node, $child = null) {
|
|||
}
|
||||
}
|
||||
|
||||
$li .= '<a class="dropdown-toggle" data-toggle="dropdown" href="'.$node->slug.'">'.$node->name.'<b class="caret"></b></a>';
|
||||
$li .= '<a class="dropdown-toggle" data-toggle="dropdown" href="'.htmlspecialchars(rtrim($node->slug, '/') . '/', FILTER_SANITIZE_URL).'">'.$node->name.'<b class="caret"></b></a>';
|
||||
if (isset($node->children)) {
|
||||
$li .= parseNodes($node->children, true, null);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue