Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
valencia
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
9
Issues
9
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Gruppo Web
valencia
Commits
3542c744
Commit
3542c744
authored
Aug 31, 2014
by
Riccardo Padovani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
All links in the trail now are active, not only the bottom one
parent
f1129685
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
12 deletions
+23
-12
template.php
template.php
+23
-12
No files found.
template.php
View file @
3542c744
...
...
@@ -231,20 +231,31 @@ function valencia_links__system_main_menu($vars) {
* Follows http://design.ubuntu.com/web-style-guide/scaffolding#navigation
*/
function
valencia_header_menu
(
$vars
)
{
// Var with all HTML of the menu
$html
=
'<ul>'
;
// Var with all HTML of the menu
$html
=
'<ul>'
;
foreach
(
$vars
[
'links'
]
as
$key
=>
$link
)
{
// To print every menu voice only one, see Drupal API
if
(
is_numeric
(
$key
))
{
$link_title
=
$link
[
'#title'
];
$link_href
=
$link
[
'#href'
];
$html
.=
'<li>'
.
l
(
$link_title
,
$link_href
,
array
(
'html'
=>
'true'
))
.
'</li>'
;
}
}
foreach
(
$vars
[
'links'
]
as
$key
=>
$link
)
{
// To print every menu voice only one, see Drupal API
if
(
is_numeric
(
$key
))
{
$link_title
=
$link
[
'#title'
];
$link_href
=
$link
[
'#href'
];
if
(
$link
[
'#original_link'
][
'in_active_trail'
])
{
$html
.=
'<li>'
.
l
(
$link_title
,
$link_href
,
array
(
'html'
=>
'true'
,
'attributes'
=>
array
(
'class'
=>
array
(
'active'
))))
.
'</li>'
;
}
else
{
$html
.=
'<li>'
.
l
(
$link_title
,
$link_href
,
array
(
'html'
=>
'true'
))
.
'</li>'
;
}
}
}
$html
.=
'</ul>'
;
return
$html
;
$html
.=
'</ul>'
;
return
$html
;
}
/**
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment