Categories

有特色的模板

JS Animated. 如何实现jQuery“华丽弹出”灯箱插件

Norman Fisher 2014年1月21日
Rating: 3.4/5. From 7 votes.
Please wait...

本教程将向您展示如何实现jQuery Magnific Popup lightbox plugin 到你的JS动画模板中.

JS Animated. 如何实现jQuery“华丽弹出”灯箱插件

Magnific Popup是一个快速,轻,移动友好和响应 lightbox 模态对话框 plugin 使用 jQuery library. 要看它的实际效果,你可以 在CodePen上玩一些例子. 将其添加到您的页面:

  1. Download Magnific-Popup-master.zip from http://github.com/dimsemenov/Magnific-Popup  在你的电脑上打开它.

    js_animated_jquery_magnific_popup_lightbox_plugin_implementing_1
  2. Copy the dist 文件夹,并将其粘贴到 site 模板包的文件夹.

    js_animated_jquery_magnific_popup_lightbox_plugin_implementing_2
  3. Open the .html 文件中包含要应用的图像 plugin 并将库和样式表添加到DreamWeaver中的 tag:
    
      
    
     
       
    
     
      
    
    js_animated_jquery_magnific_popup_lightbox_plugin_implementing_3
  4. 找出图像为e的直线.g.
  5. 
    
  6. 然后把它改成
  7. 
        
    
    
    js_animated_jquery_magnific_popup_lightbox_plugin_implementing_4
  8. 在images文件夹中应该有image_big.JPG和image_small.jpg相应.
  9. js_animated_jquery_magnific_popup_lightbox_plugin_implementing_5
  10. 要初始化弹出窗口,请将以下内容添加到 .html 在交易结束前提交 tag or in the footer 您的网站(关闭前) tag:
  11. 
    
    js_animated_jquery_magnific_popup_lightbox_plugin_implementing_6
  12. 保存更改并在web中检查您的页面 browser:图像应该在一个 lightbox with a title. 您的站点应该在远程/本地服务器上启动并运行,以便查看 plugin in action.
js_animated_jquery_magnific_popup_lightbox_plugin_implementing_7

有关如何使用的更多信息 plugin,请参阅官方手册: http://dimsemenov.com/plugins/magnific-popup/documentation.html#initializing_popup

请随时查看下面的详细视频教程:

JS Animated. 如何实现jQuery“华丽弹出”灯箱插件
这个条目被张贴了出来 JS动画教程, 使用HTML, 使用jQuery脚本 and tagged implement, lightbox, Magnific, popup, use. Bookmark the permalink.

Submit a ticket

如果您仍然无法找到关于您的问题的足够的教程,请使用以下链接向我们的技术支持团队提交请求. 我们将在接下来的24小时内为您提供我们的帮助和协助: Submit a ticket