Hej mam problem, nie wyświetla mi się kod od WP Wrapper. Takie okienko, które ma wyskakiwać co 25 sekund w prawym rogu z informacją.
Kod Wrappera
<?php wp_footer(); ?>
<div style="display:none">
<audio id="notify" src="https://notificationsounds.com/soundfiles/389bc7bb1e1c2a5e7e147703232a88f6/file-sounds-900-you-know.mp3">
</div>
<div class="private_notifier" style="cursor:pointer">
</div>
<script>
var arrayStrings = [
"TEKST 1","TEKST 2","TEKST 3"
];
$(document).ready(function(){
setInterval(function() {
var value = Math.floor(Math.random() * arrayStrings.length) + 1;
var content = '<div style="position:fixed;right:50px;bottom:80px;width:350px;height:200px;background:#191d2e;border-radius:20px;z-index:100000"><p style="text-align:center;font-weight:bold;margin-top:25px;"><img src="LINK DO TWOJEGO LOGO" style="width:180px;height:40px;"/><span style="color:#ffffff"></br></br>Ktoś właśnie pobrał:</span></br><span style="color:#d81e5b">'+arrayStrings[value-1]+'</span></p></div>';
$('.private_notifier').html(content);
document.getElementById('notify').play();
setTimeout(function() { $(".private_notifier").html(''); }, 10000);
}, 25000);
$('.private_notifier').on('click', function(){
$(this).html('');
});
});
</script>
Kod footer.php
</div> <!-- / boxed container -->
</div> <!-- / wrapper -->
<footer>
<div class="boxed-container">
<div class="footer-columns">
<?php
dynamic_sidebar( 'smt_footer_sidebar' );
$total_widgets = wp_get_sidebars_widgets();
$cnt = count( $total_widgets['smt_footer_sidebar'] );
?>
<div class="clear"></div>
</div>
<div class="footer-menu">
<?php wp_nav_menu(array(
'depth'=>0,
'theme_location' => smt_getOption( 'menu', 'mobile' ),
'menu_class' => 'nav-menu'
)); ?>
</div>
<style>
@media only screen and (min-width:801px) {
footer .widget { width: <?php echo (102-2*$cnt)/$cnt; ?>%; }
#<?php echo $total_widgets['smt_footer_sidebar'][$cnt-1]; ?> { margin-right:0; }
}
</style>
</div>
<div class="footer_txt">
<div class="boxed-container">
<div><?php echo smt_getOption( "layout","footertext" ); ?></div>
<div class='smthemes'>Designed by <a href='http://www.hoverboardofficiel.fr/' target='_blank'>http://www.hoverboardofficiel.fr/</a>, thanks to: <a href='http://theme.today/' target='_blank'>Free WordPress themes</a>, <a href='http://www.dpthemes.com/' target='_blank'>Free WordPress themes</a> and <a href='http://corstone.biz' target='_blank'>CorStone.biz</a></div>
</div>
</div>
</footer>
<?php wp_footer(); ?>
<?php get_template_part( 'extras/social' ); ?>
<script type="text/javascript"><!--//--><![CDATA[//><!--
<?php
$superfish = array();
switch( smt_getOption( 'menu','effect' ) ) {
case 'standart':
$superfish[ 'animation' ] = 'animation: {width:"show"}';
break;
case 'slide':
$superfish[ 'animation' ] = 'animation: {height:"show"}';
break;
case 'fade':
$superfish[ 'animation' ] = 'animation: {opacity:"show"}';
break;
case 'fade_slide_right':
$superfish[ 'onBeforeShow' ] = 'onBeforeShow: function(){ this.css("marginLeft","20px"); }';
$superfish[ 'animation' ] = 'animation: {"marginLeft":"0",opacity:"show"}';
break;
case 'fade_slide_left':
$superfish[ 'onBeforeShow' ] ='onBeforeShow: function(){ this.css("marginLeft","-20px"); }';
$superfish[ 'animation' ] = 'animation: {"marginLeft":"0",opacity:"show"}';
break;
}
$superfish[ 'autoArrows' ] = 'autoArrows: ' . ( ( smt_getOption( 'menu','arrows' ) ) ? 'true' : 'false' );
$superfish[ 'dropShadows' ] = 'dropShadows: false';
$superfish[ 'speed' ] = 'speed: ' . smt_getOption( 'menu', 'speed' );
$superfish[ 'delay' ] = 'delay: ' . smt_getOption( 'menu', 'delay' );
?>
jQuery(function(){
jQuery( 'ul.nav-menu' ).superfish( {
<?php echo implode( ', ', $superfish ); ?>
});
});
/**** SEARCH ****/
jQuery( document ).on( 'click', '#search-trigger', function() {
if ( jQuery( this ).hasClass( 'active' ) ) {
jQuery( this ).removeClass( 'active' );
jQuery( 'header .search-box' ).slideUp();
} else {
jQuery( this ).addClass( 'active' );
jQuery( 'header .search-box' ).slideDown();
}
});
//--><!]]></script>
<script>
/***** MAIN MENU *****/
jQuery( document ).on( 'click', '#menu-trigger', function() {
if ( jQuery( this ).hasClass( 'active' ) ) {
jQuery( this ).removeClass( 'active' );
jQuery( '#main-menu' ).hide();
} else {
jQuery( this ).addClass( 'active' );
if ( jQuery( '.slider' ).length ) {
jQuery( '#main-menu ul.nav-menu' ).height( jQuery( '.slider' ).height()-100 );
}
if ( jQuery( '.slider' ).length && jQuery(document).width() > 1480 ) {
jQuery( '#main-menu ul.nav-menu' ).css( 'left', ( jQuery( '.slider' ).width()-1080 )/2+1080+'px' );
}
jQuery( '#main-menu' ).show();
}
});
</script>
<?php wp_footer(); ?>
<div style="display:none">
<audio id="notify" src="https://notificationsounds.com/soundfiles/389bc7bb1e1c2a5e7e147703232a88f6/file-sounds-900-you-know.mp3">
</div>
<div class="private_notifier" style="cursor:pointer">
</div>
<script>
var arrayStrings = [
"TEKST 1","TEKST 2","TEKST 3"
];
$(document).ready(function(){
setInterval(function() {
var value = Math.floor(Math.random() * arrayStrings.length) + 1;
var content = '<div style="position:fixed;right:50px;bottom:80px;width:350px;height:200px;background:#191d2e;border-radius:20px;z-index:100000"><p style="text-align:center;font-weight:bold;margin-top:25px;"><img src="LINK DO TWOJEGO LOGO" style="width:180px;height:40px;"/><span style="color:#ffffff"></br></br>Ktoś właśnie pobrał:</span></br><span style="color:#d81e5b">'+arrayStrings[value-1]+'</span></p></div>';
$('.private_notifier').html(content);
document.getElementById('notify').play();
setTimeout(function() { $(".private_notifier").html(''); }, 10000);
}, 25000);
$('.private_notifier').on('click', function(){
$(this).html('');
});
});
</script>
</body>
</html>