Skip to content
Browse files

Merge branch '4.0/escape-more-menu-attributes' into 4.0-trunk

  • Loading branch information...
2 parents 12d2919 + 6fbfcb7 commit 7e11127f257aa8bbbc6cc43c38d807346c5edf69 @alexmv alexmv committed Mar 7, 2013
Showing with 5 additions and 2 deletions.
  1. +5 −2 share/html/Elements/Menu
View
7 share/html/Elements/Menu
@@ -61,8 +61,8 @@
% if ($child->raw_html) {
<% $child->raw_html |n %>
% } else {
-% my $url = (not $child->path or $child->path =~ m{^\w+:/}) ? $child->path : RT->Config->Get('WebPath').$child->path;
-<a id="<%$item_id%>" class="menu-item <% $child->class || '' %>"<% $child->path ? ' href="'.$url.'"' : '' |n%><% $child->target ? ' target="'.$child->target.'"' : '' |n %>>\
+% my $url = $m->interp->apply_escapes((not $child->path or $child->path =~ m{^\w+:/}) ? $child->path : RT->Config->Get('WebPath').$child->path, 'h');
+<a id="<%$item_id%>" class="menu-item <% $child->class || '' %>"<% $child->path ? ' href="'.$url.'"' : '' |n%><% $child->target ? ' target="'.$m->interp->apply_escapes($child->target, 'h').'"' : '' |n %>>\
<% $child->escape_title ? $m->interp->apply_escapes($child->title, 'h') : $child->title |n %>\
</a>\
% }
@@ -82,3 +82,6 @@ $toplevel => 1
$parent_id => ''
$depth => 0
</%ARGS>
+<%init>
+$id = $m->interp->apply_escapes($id, 'h');
+</%init>

0 comments on commit 7e11127

Please sign in to comment.
Something went wrong with that request. Please try again.