Ero sivun ”Widget:PopupMenu” versioiden välillä
Järvi-meriwikistä
Rivi 4: | Rivi 4: | ||
<script type="text/javascript"> | <script type="text/javascript"> | ||
− | function <!--{$id|escape:'quotes'}--> | + | function <!--{$id|escape:'quotes'}-->_func() { |
var id = "<!--{$id|escape:'quotes'}-->"; | var id = "<!--{$id|escape:'quotes'}-->"; | ||
Rivi 11: | Rivi 11: | ||
jQuery('#' + id + '_container').append(button); | jQuery('#' + id + '_container').append(button); | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
jQuery('#' + id + '_content').css('position', 'absolute'); | jQuery('#' + id + '_content').css('position', 'absolute'); | ||
Rivi 37: | Rivi 30: | ||
} | } | ||
− | + | function <!--{$id|default:popupmenu|escape:'html'}-->_jQueryTest() { | |
+ | if ( typeof window.jQuery == 'undefined' ) { | ||
+ | setTimeout( function(){ <!--{$id|default:popupmenu|escape:'html'}-->_jQueryTest() }, 300); | ||
+ | } else { | ||
+ | <!--{$id|default:popupmenu|escape:'html'}-->_func(); | ||
+ | } | ||
+ | } | ||
+ | setTimeout( function(){ <!--{$id|default:popupmenu|escape:'html'}-->_jQueryTest() }, 300 ); | ||
</script> | </script> | ||
</includeonly> | </includeonly> |