Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Add jQuery Responsive Menu Plugin which turns your site's navigation into a dropdown (
) when your browser is at mobile widths. Default switchWidth: 768
/**
* Add Javascript for responsive mobile menu
*/
drupal_add_js(drupal_get_path('theme', 'skeletontheme') .'/js/jquery.mobilemenu.js');
drupal_add_js('jQuery(document).ready(function($) {
$("#navigation .content > ul").mobileMenu({
prependTo: "#navigation",
combine: false,
switchWidth: 768,
topOptionText: "Select page"
});
});',
array('type' => 'inline', 'scope' => 'header'));
//EOF:Javascript
Comments
Comment #1
gtsopour CreditAttribution: gtsopour commentedJust committed http://drupalcode.org/project/skeletontheme.git/commit/661fa67
Comment #2
gtsopour CreditAttribution: gtsopour commentedDocumentation
Responsive Drupal Skeleton theme Multi-level CSS/Superfish menus - http://drupal.org/node/1919042
Comment #3
sk33lz CreditAttribution: sk33lz commentedFYI, there is a module for that.
http://drupal.org/project/tinynav
Comment #4
gtsopour CreditAttribution: gtsopour commentedThanks sk33lz for this info.
George
Comment #5.0
(not verified) CreditAttribution: commentedChanged body text