{"id":31528,"date":"2013-12-11T10:54:38","date_gmt":"2013-12-11T15:54:38","guid":{"rendered":"http:\/\/www.templatemonster.com\/help\/?p=31528"},"modified":"2013-12-25T09:47:33","modified_gmt":"2013-12-25T14:47:33","slug":"js-animated-how-to-implement-jquery-prettyphoto-lightbox-plugin","status":"publish","type":"post","link":"https:\/\/www.templatemonster.com\/help\/js-animated-how-to-implement-jquery-prettyphoto-lightbox-plugin.html","title":{"rendered":"JS Animated. How to implement jQuery &#8220;prettyPhoto&#8221; lightbox plugin"},"content":{"rendered":"<p>This  tutorial is going to show you how to implement the jQuery prettyPhoto lightbox  plugin into your JS Animated template.<\/p>\r\n\r\n<a href=\"http:\/\/www.youtube.com\/watch?v=Ymwp3lGHdgs?width=1280&amp;height=720\" rel=\"prettyPhoto\">JS Animated. How to implement jQuery &#8220;prettyPhoto&#8221; lightbox plugin<\/a>\r\n\r\n<p class=\"info-box\">PrettyPhoto is a jQuery lightbox clone. It supports not only images, but also videos, flash, YouTube, iframes and ajax. It\u2019s a full blown media lightbox.<\/p> To add it  to your page:<\/p>\r\n\r\n<ol>\r\n  <li><p>Download <strong>prettyPhoto_compressed_3.1.5.zip<\/strong> from <a href=\"http:\/\/www.no-margin-for-errors.com\/projects\/prettyphoto-jquery-lightbox-clone\/\" rel=\"nofollow\" target=\"_blank\">http:\/\/www.no-margin-for-errors.com\/projects\/prettyphoto-jquery-lightbox-clone\/<\/a> \u00a0on your computer and unpack it.<\/p>\r\n\r\n<a href=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_1.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_1-300x152.jpg\" alt=\"js_animated_jquery_prettyphoto_lightbox_plugin_implementing_1\" width=\"300\" height=\"152\" class=\"alignnone size-medium wp-image-31530\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_1-300x152.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_1-150x76.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_1.jpg 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n\r\n<\/li>\r\n  <li><p>Copy the <strong>js <\/strong>and <strong>css<\/strong> folders from  the unzipped package and paste them into the <strong>site<\/strong> folder of your template package. Since you already have folders with the same  names there, you will be asked to replace them. This will just add the files in  these folders to them, so just go ahead and agree to the replacement.<\/p>\r\n\r\n<a href=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_2.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_2-300x139.jpg\" alt=\"js_animated_jquery_prettyphoto_lightbox_plugin_implementing_2\" width=\"300\" height=\"139\" class=\"alignnone size-medium wp-image-31531\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_2-300x139.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_2-150x69.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_2.jpg 824w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n\r\n<\/li>\r\n  <li><p>Open the <strong>.html<\/strong> file with the  image you want to apply the plugin to\u00a0and add the libraries and the table of styles to it in DreamWeaver to the <strong>&lt;head&gt;<\/strong> section:<\/p>\r\n\r\n<pre class=\"brush:js\">\r\n&lt;link rel=&quot;stylesheet&quot; href=&quot;css\/prettyPhoto.css&quot; type=&quot;text\/css&quot; media=&quot;screen&quot; title=&quot;prettyPhoto main stylesheet&quot; charset=&quot;utf-8&quot; \/&gt;\r\n\r\n&lt;script src=&quot;js\/jquery.prettyPhoto.js&quot; type=&quot;text\/javascript&quot; charset=&quot;utf-8&quot;&gt;&lt;\/script&gt; \r\n<\/pre>\r\n\r\n<a href=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_3.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_3-300x132.jpg\" alt=\"js_animated_jquery_prettyphoto_lightbox_plugin_implementing_3\" width=\"300\" height=\"132\" class=\"alignnone size-medium wp-image-31532\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_3-300x132.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_3-150x66.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_3.jpg 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n<\/li>\r\n\r\n  <li><p>Find the line with the  image, e.g.:<\/p><\/li>\r\n  \r\n  <pre class=\"brush:html\">\r\n&lt;img src=&quot;images\/image_small.jpg &quot; alt=&quot;&quot; \/&gt;\r\n  <\/pre>\r\n    <p>And change  it to:<\/p>\r\n\r\n<pre class=\"brush:html\">    \r\n&lt;a href=&quot;images\/image_big.jpg&quot; rel=&quot;prettyPhoto&quot; title=&quot;Single Photo&quot;&gt;&lt;img src=&quot;images\/image_small.jpg &quot; alt=&quot; &quot; \/&gt;&lt;\/a&gt;    \r\n<\/pre>\r\n\r\n<a href=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_4.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_4-300x137.jpg\" alt=\"js_animated_jquery_prettyphoto_lightbox_plugin_implementing_4\" width=\"300\" height=\"137\" class=\"alignnone size-medium wp-image-31533\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_4-300x137.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_4-150x68.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_4.jpg 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>      \r\n      \r\n      <p><p>In the  images folder there should be image_big.jpg and image_small.jpg accordingly.<\/p><\/p>\r\n\r\n<a href=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_5.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_5-300x154.jpg\" alt=\"js_animated_jquery_prettyphoto_lightbox_plugin_implementing_5\" width=\"300\" height=\"154\" class=\"alignnone size-medium wp-image-31534\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_5-300x154.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_5-150x77.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_5.jpg 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>      \r\n      \r\n      <li><p>Initialize prettyPhoto:  add the following to your <strong>.html<\/strong> file right before the closing<strong> &lt;\/head&gt; <\/strong> tag:<\/p><\/li>\r\n      \r\n<pre class=\"brush:js\">      \r\n&lt;script type=&quot;text\/javascript&quot; charset=&quot;utf-8&quot;&gt;\r\n$(document).ready(function(){\r\n$(&quot;a[rel^='prettyPhoto']&quot;).prettyPhoto();\r\n});\r\n&lt;\/script&gt;\r\n<\/pre>\r\n\r\n<a href=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_6.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_6-300x137.jpg\" alt=\"js_animated_jquery_prettyphoto_lightbox_plugin_implementing_6\" width=\"300\" height=\"137\" class=\"alignnone size-medium wp-image-31535\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_6-300x137.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_6-150x68.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_6.jpg 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>\r\n\r\n       <li>Save the  changes and\u00a0 check your page in a web browser: the image should be opening  in a lightbox.<\/li>\r\n\r\n<a href=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_7.jpg\"><img loading=\"lazy\" src=\"\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_7-300x151.jpg\" alt=\"js_animated_jquery_prettyphoto_lightbox_plugin_implementing_7\" width=\"300\" height=\"151\" class=\"alignnone size-medium wp-image-31536\" srcset=\"https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_7-300x151.jpg 300w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_7-150x75.jpg 150w, https:\/\/www.templatemonster.com\/help\/wp-content\/uploads\/2013\/12\/js_animated_jquery_prettyphoto_lightbox_plugin_implementing_7.jpg 1024w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/a>.     \r\n      \r\n<\/ol>\r\n\r\n<p>For more  information on how to use the plugin, please refer to the official manual at <a target=\"_blank\" href=\"http:\/\/www.no-margin-for-errors.com\/projects\/prettyphoto-jquery-lightbox-clone\/documentation\" rel=\"nofollow\">http:\/\/www.no-margin-for-errors.com\/projects\/prettyphoto-jquery-lightbox-clone\/documentation<\/a>.<\/p>\r\n\r\n<p>Feel free to check the detailed video tutorial below:<\/p>\r\n\r\n<a href=\"http:\/\/www.youtube.com\/watch?v=Ymwp3lGHdgs?width=1280&amp;height=720\" rel=\"prettyPhoto\">JS Animated. How to implement jQuery &#8220;prettyPhoto&#8221; lightbox plugin<\/a>","protected":false},"excerpt":{"rendered":"<p>This  tutorial is going to show you how to implement the jQuery prettyPhoto lightbox  plugin into your JS Animated template.<\/p>\n","protected":false},"author":30,"featured_media":31541,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[1016,253,270],"tags":[1574,813,827,768,1418],"_links":{"self":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts\/31528"}],"collection":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/users\/30"}],"replies":[{"embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/comments?post=31528"}],"version-history":[{"count":0,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/posts\/31528\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/media\/31541"}],"wp:attachment":[{"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/media?parent=31528"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/categories?post=31528"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.templatemonster.com\/help\/wp-json\/wp\/v2\/tags?post=31528"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}