Image Light Box For Blog And WordPress Blog Users

Hi! Everyone, hope you all are fine.
Today in this post I will tell you how you can use Light Box in blog. Light Box is an image viewer and all of you must have show the Image viewer on my blog, if you didn’t show click on the below image to see demo.

my light box setup
Image credit: IceBone

When I was on I wanted this feature on my blog but didn’t knew how I can use it but when I shifted to WordPress I finally got it on my blog and if you are also on WordPress you can use Slimbox plugin. And if you are user and want this on your blog here how can

  1. Go to
  2. Login to your account
  3. Now go to Design –> Edit HTML
  4. Blogger Dashboard -- Design

  5. Their search for <head> opening tag
  6. Copy-past the below code just after the <head> opening tag
  7. <!-- Light Box Code Starts SJbn.Co -->
    <link href='' media='screen' rel='stylesheet' type='text/css'/>
    <script src='' type='text/javascript'/>
    <script src='' type='text/javascript'/>
    <script src='' type='text/javascript'/>
    <!--Light Box Code Ends SJbn.Co -->
  8. Click on SAVE TEMPLATE button
  9. Design -- Edit HTML

  10. Now whenever you make a post with images and you want to use this effect on that image copy you need to do the following
  11. Go to
  12. Login to your account
  13. Now go to NEW POST
  14. Compete your post (write, insert, whatever you want to do in that post)
  15. After you competed (also inserted the image) click on Edit HTML tab
  16. Add this code in every a tag before every img tag
  17. rel="lightbox[ALBUM-NAME]" title="IMAGE-CAPTION"

    For example see below
    <a rel="lightbox[ALBUM-NAME]" title="IMAGE-CAPTION" href="" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" height="288" src="" width="320" /></a>

    Blog Post -- Edit HTML

  18. Now change the ALBUM-NAME and IMAGE-CAPTION with your album name and image caption
  19. And publish the post

Click here to see Light Box demo on blog

You can use the left and right arrow key to change the image and Esc to close Light Box. If you want to make more than one set (album) of images in same page change the album name in the other set. The difference between in both the set (album) is you can’t change the image without closing the image viewer (Light Box)

Thanks to Lokesh Dhakar for making this codes.

If you have any question or problems do let me know.

2 thoughts on “Image Light Box For Blog And WordPress Blog Users”

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.