updated pluging.js for fancybox functionality