Welcome to Discussion Forum, where you can ask questions and receive answers from other members of the community.

How to display fancybox popup when page load : Magento 2

0 like 0 dislike
I want to display popup using fancybox when page load in magento2 . How is it possible ?
 
Please help me....
 
    <!DOCTYPE html>
<html>
<head>
<script type="text/javascript">
require([ 'jquery', 'jquery/ui','fancybox'],  function( $ ) {
 
     $(document).ready(function() {
        $.fancybox("#hidden");
        //alert("a");
    });
 
}); 
</script>
</head>
<body>
<div id="hidden" style="display:none;">
    Hi this is hidden
</div>
 
</body>
</html>
asked May 1, 2017 in Magento by harsh (8,710 points)

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.

Related questions

0 like 0 dislike
0 answers 44 views
1 like 0 dislike
0 answers 68 views
68 views asked Apr 11, 2017 in Magento by harsh (8,710 points)
1 like 0 dislike
1 answer 383 views
383 views asked Mar 6, 2017 in Magento by harsh (8,710 points)
0 like 0 dislike
0 answers 2,486 views
0 like 0 dislike
2 answers 46 views
46 views asked Feb 15, 2017 in Prestashop by harsh (8,710 points)
...