I need to add lightbox to a theme instead of using the plugin. I added it and everything works fine but for some reason close.png and loading.gif images keeps referring to site.com/images/close.png . My lightbox.js is in themes/mytheme/libs and images are in themes/mytheme/images . I have changed lightbox.js as following .
this.fileLoadingImage = '../images/loading.gif';
this.fileCloseImage = '../images/close.png';
If you are needing to include the full path in your lightbox.js file one way to do it is to follow this example -> Path to WordPress Template Directory inside jQuery?
You would set the value of a variable to the WordPress template directory in your header.php prior to the inclusion of lightbox.js and then use that variable to produce an absolute path;