Doesn't Work When Image Is Updated #479
Replies: 3 comments 3 replies
-
You can call the |
Beta Was this translation helpful? Give feedback.
-
Has anyone got a working example of this with XMLHttpRequest? I have tried everything I can think of. |
Beta Was this translation helpful? Give feedback.
-
I've made a bit of progress: function loadImages() var xmlhttp = false; xmlhttp.onreadystatechange=function() alert('viewer'+gallery.id); //setTimeout(function(){ gallery.update(); }, 1000); //gallery.show(); I found I had to make the server request synchronous or add a javascript delay (not great). However the remaining problem I have is destroying the previous gallery object. Adding a destroy in the new Viewer, as per one of the examples, means the gallery works but destroys itself as soon as it is closed, rather than when the data is updated. Any help please? |
Beta Was this translation helpful? Give feedback.
-
Hey , So I implemented this on a div who content is dynamically updated every 5 seconds , When The Page First Loads , I can view the image , but after the image gets updated ,(Using AJAX) , the viewer doesn't appear , even though the I click the image . but on clicking a image inside same div , which is NOT updated every 5 seconds , I can view other images too .. in Modal View .
Any Idea What Should I Do ?
Beta Was this translation helpful? Give feedback.
All reactions