Commit 7d12243f authored by afzafri's avatar afzafri
Browse files

re-bind the init gallery function everytime after opening new comic

parent 903eb524
......@@ -3,15 +3,17 @@ $(document).ready(function(){
// Load all the archive formats
loadArchiveFormats(['rar', 'zip', 'tar']);
// init the gallery plugin, when there is a first click on a image
$(document).one('click','#comicImg',function(){
event.preventDefault();
// initialize gallery
$('#output').lightGallery();
$(this).click();
});
$("#fileup").change(function(){
// init the gallery plugin, when there is a first click on a image
// re-bind this function when opening new comic
$(document).one('click','#comicImg',function(){
event.preventDefault();
// initialize gallery
$('#output').lightGallery();
$(this).click();
});
// show loading
$('.se-pre-con').fadeIn('slow');
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment