Promo Space close after a few seconds
- Posted by Joao (2) Offline
Hello, congratulate the module works perfectly , but wanted advice if you may be close after a few seconds.
Thanks for listening , greetings .
9 years 5 months ago #1
by Joao
Thanks for listening , greetings .
Please Log in or Create an account to join the conversation.
- Posted by TemplatePlazza (5310) Offline
HI, open the file ../modules/mod_tppromospace/assets/script.js, change this code :
to
9 years 5 months ago #2
by TemplatePlazza
jQuery('#button-close').live('click', function(){
jQuery('#tppromospace' ).animate( { opacity: '0' }, { queue: false, duration: 750 });
jQuery('#tppromospace').delay(500).slideUp(400);
jQuery.cookie('tppromospace', '1');
jQuery('#button-close').hide();
jQuery('#button-show').show();
});
to
setTimeout( function(){
jQuery('#tppromospace' ).animate( { opacity: '0' }, { queue: false, duration: 750 });
jQuery('#tppromospace').delay(500).slideUp(400);
jQuery.cookie('tppromospace', '1');
jQuery('#button-close').hide();
jQuery('#button-show').show();
} , 2000 );
Please Log in or Create an account to join the conversation.
- Posted by Joao (2) Offline
Thanks , works almost perfect, has a bug that does not close the window if you open it , any ideas ?
9 years 5 months ago #3
by Joao
Please Log in or Create an account to join the conversation.
- Posted by TemplatePlazza (5310) Offline
Ah, ok. Then re-add the code after the new code, so the code will look like this :
9 years 5 months ago #4
by TemplatePlazza
setTimeout( function(){
jQuery('#tppromospace' ).animate( { opacity: '0' }, { queue: false, duration: 750 });
jQuery('#tppromospace').delay(500).slideUp(400);
jQuery.cookie('tppromospace', '1');
jQuery('#button-close').hide();
jQuery('#button-show').show();
} , 2000 );
jQuery('#button-close').live('click', function(){
jQuery('#tppromospace' ).animate( { opacity: '0' }, { queue: false, duration: 750 });
jQuery('#tppromospace').delay(500).slideUp(400);
jQuery.cookie('tppromospace', '1');
jQuery('#button-close').hide();
jQuery('#button-show').show();
});
Please Log in or Create an account to join the conversation.
- Posted by mariano (4) Offline
Ayoma Hello, you solved your problem? I tried but I can not obtain the claimed effect. If you have solved, could you pass the list of files script.js changed?
Thank you
9 years 4 months ago #5
by mariano
Thank you
Please Log in or Create an account to join the conversation.