vendredi 27 février 2015

Fancybox multiple pop ups close form on submit?

I got two popus set up to open one by one, after 1st one is closed, by timer, i want the second one to be closed by the submit button, This is the website : http://merlinmoon.com/ My Code !st pop up is a youtube Iframe HTML: for the Second Pop up



<div id="mews">

<div class="cd-form-wrapper cd-container panelssss">

<form class="cd-form" method="post" action="Believe-Masters.zip" onsubmit="javascript:various2.jQuery.fancybox.close(true);">


<input type="name" id="cd-email" class="cd-email" name="cd-email" placeholder="NAME">
<input type="email" id="cd-email" class="cd-email" name="cd-email" placeholder="EMAIL">
<input type="submit" class="cd-submit" value="">

</form>


</div>


Javascript :



<script>
jQuery(document).ready(function($) {
setTimeout(function(){
$('#custom-stuff-blea .various').trigger('click');
setTimeout(function(){
$.fancybox.close();
}, 192000)
}, 1000);
});
</script>

<script type="text/javascript">

jQuery(document).ready(function($) {
$(".various").fancybox({
maxWidth : 800,
maxHeight : 600,
fitToView : false,
width : '70%',
height : '70%',
autoSize : false,
closeClick : false,
openEffect : 'none',
closeEffect : 'true',

'afterClose': function() {
$("#custom-stuff-blea .various2").fancybox().trigger("click");
}
});
});
</script>
<script type="text/javascript">

jQuery(document).ready(function($) {
$(".various3").fancybox({
maxWidth : 800,
maxHeight : 600,
fitToView : false,
width : '70%',
height : '70%',
autoSize : false,
closeClick : false,
openEffect : 'none',
closeEffect : 'none',

});
});
</script>


I want to notice that onsubmit is not working :(, can you help me ? i will appreciate any help. Regards...


Aucun commentaire:

Enregistrer un commentaire