Closed (won't fix)
Project:
JQuery menu
Version:
6.x-2.0
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
9 May 2011 at 15:22 UTC
Updated:
21 Mar 2013 at 13:19 UTC
I really like the functionality of this module. I'm wondering if it's possible to have the expand button appear to the right of the menu title. For example, the current behavior is like this:
Some menu item
[+] Item w/ children
Some other item
I'm asking for this:
Some menu item
Item w/ children [+]
Some other item
Obviously my Javascript knowledge is not great, I know that the HTML is spit out in this section of code but I'm not sure how to manipulate it so that it will spit out the parent item, print the and then show the rest:
function theme_jqmenu_links($title, $path, $options, $state, $classes, $has_children, $editpath = NULL, $edit_text = NULL, $edit_access) {
global $base_path;
$module_path = $base_path . drupal_get_path('module', 'jquerymenu');
$output = '';
// This is the span that becomes the little plus and minus symbol.
$plus = '<span'. (empty($classes) ? '>' : ' class="'. implode(' ', $classes) .'">') .'</span>';
if ($editpath != NULL && user_access($edit_access)) {
$editbox = jqm_edit_box($editpath, $edit_text);
if ($has_children != 0) {
$output .= $editbox . $plus . l($title, $path, $options);
}
else {
$output .= $editbox . l($title, $path, $options);
}
}
else {
if ($has_children != 0) {
$output .= $plus . l($title, $path, $options);
}
else {
$output .= l($title, $path, $options);
}
}
return $output;Any pointers much appreciated!
Comments
Comment #1
pat redmond commentedIt has been more than 12 months since this was posted. Is it still something you are looking for?
Comment #2
FrancoisL commentedHello pat yes this is something I'm now looking for on my side :)
Thanks