Create loadgallery.js