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.
Hi,
as far of jquery 1.9 jQuery.browser was removed, and admin_menu get this error:
"Uncaught TypeError: Cannot read property 'msie' of undefined" (admin_menu.js - line:223)
For quick fix use this code:
change line 223:
- if ($.browser.msie && parseInt(jQuery.browser.version) == 6) {
+ if (navigator.userAgent.match(/msie [6]/i)) {
Comment | File | Size | Author |
---|---|---|---|
#2 | admin_menu-ie6detect-1961178-2.patch | 583 bytes | jcisio |
#1 | admin_menu-ie6detect-1961178-1.patch | 531 bytes | tompagabor |
Comments
Comment #1
tompagabor CreditAttribution: tompagabor commentedHere is the patch.
Comment #2
jcisio CreditAttribution: jcisio commentedPatch works as expected. Tested with jQuery 1.10 too. Attached a more verbose patch.
Comment #3
tompagabor CreditAttribution: tompagabor commentedI assigned this issue to myself, os anything is happening with this issue, i do my best to fix this bug.
Comment #4
joelpittetRTBC++ @tompagabor any eta on committing this to dev?
Comment #5
markhalliwellComment #6
Anonymous (not verified) CreditAttribution: Anonymous commented@jcisio & @tompagabor, the only way that last patch works is if you add a "}" in the end:
Drupal.admin.behaviors.hover = function (context, settings, $adminMenu) {
// Hover emulation for IE 6.
- if ($.browser.msie && parseInt(jQuery.browser.version) == 6) {
+ if (navigator.appName == 'Microsoft Internet Explorer' && navigator.userAgent.match(/msie 6/i)) {
$('li', $adminMenu).hover(
function () {
$(this).addClass('iehover');
}); //close function and hover!
Don't really know the state of this issue, but I still have it with all up to date and greeny.
Comment #7
jcisio CreditAttribution: jcisio commentedCorrect issue status.
Comment #8
markhalliwellThis issue duplicates the efforts in #1892074: remove $.browser (Remove IE 6 support) (which were added to the project).
Comment #9
scott.browne CreditAttribution: scott.browne commentedThanks for this quick fix. I found it very quickly too! Happy me!