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.
There is an issue with lazy loading #attached library for IE (7-9).
I've attached an example module, which is a strip down from the user-modal (currently in my sandbox).
Enable and try on chrome/ firefox -- tabs are ok.
Try on IE -- it fails.
Then you can uncomment the following lines:
function user_modal_init() {
// FIXME: IE bug, library isn't loaded.
// Uncomment the following link to see it working.
// drupal_add_library('system', 'ui.tabs');
Refresh and it will of course work.
Comment | File | Size | Author |
---|---|---|---|
user_modal.tar_.gz | 1.56 KB | amitaibu |
Comments
Comment #1
Damien Tournoud CreditAttribution: Damien Tournoud commentedI sense this is a duplicate of #1071818: Lazy-loading CSS fails in IE.
Comment #2
amitaibu@Damz,
I'm not sure if it's the same, as there it's about CSS, and here it's about JS (in the example module it's jquery UI tabs).
Comment #3
sunIndeed, given the detailed analysis in #1071818: Lazy-loading CSS fails in IE, that issue should focus on the CSS @import problem with IE only.
Comment #4
JeremyFrench CreditAttribution: JeremyFrench commentedI still have a feeling this is related to the CSS issue. Adding a library just calls
drupal_add_js()
anddrupal_add_css()
. In the case of the ui.tabs it will loadjquery.ui.tabs.css
(ad possibly jquery.ui.css). So if #1071818: Lazy-loading CSS fails in IE is not fixed then this will never work.There is a patch for #1071818 now. If you would like to test it for this as well we can mark as duplicate.
Comment #5
nod_updated patch for IE #1071818: Lazy-loading CSS fails in IE, please test.
Comment #6
nod_Need testing
Comment #7
nod_