Closed (fixed)
Project:
Shadowbox
Version:
7.x-4.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
26 Feb 2013 at 14:53 UTC
Updated:
9 Apr 2013 at 18:00 UTC
Hi,
Sharing a code snippet added in my theme .js file to make shadowbox work in openlayers popups. This could help on other dynamic content implementation:
(function ($) {
// Check that shadowbox library is available
if (typeof Shadowbox !== 'undefined') {
Drupal.behaviors.shadowbox = {
attach: function(context, settings) {
if ($('.openlayers-popup').length > 0) {
Shadowbox.setup();
}
}
};
}
})(jQuery);
I hope this will help someone.
Maybe something similar could be added directly to shadowbox module ... I don't know.
Comments
Comment #1
Thithi32 commentedUpdate:
Comment #2
manfer commentedCurrent version calls always clearCache and setup so this is fixed.