vvvmax / unitegallery

Unite Gallery - Responsive jQuery Image and Video Gallery Plugin. Aim to be the best gallery on the web on it's kind. See demo here:
http://unitegallery.net
MIT License
530 stars 158 forks source link

Initializing gallery loaded with ajax #101

Open ridinghoodmedia opened 8 years ago

ridinghoodmedia commented 8 years ago

Hello, I have a set of galleries that are replaced with each other when the corresponding button is clicked using ajax added like this:

$('.gallery-wrap').html( response );

I then right after, I call

$("#main-gallery").unitegallery();

The galleries all have the same wrapper #main-gallery. The strange this is the first time I call .unitegallery() on a new gallery, it loads but does not display at all, even though a lot of the markup is added to the gallery. If I click the same button again (to load that same gallery) it will load fine.

What do I have to do to make this work the first time? Thanks a lot!

vvvmax commented 8 years ago

HI, if it's not documented gallery option, and don't exists in the demo I can't assure that it will work right. But if you want, you can show me your website and I'll see if I could understand what happening and help you (don't promise).

On Sun, Aug 14, 2016 at 2:09 AM, svaults notifications@github.com wrote:

Hello, I have a set of galleries that are replaced with each other when the corresponding button is clicked using ajax added like this:

$('.gallery-wrap').html( response );

I then right after, I call

$("#main-gallery").unitegallery();

The galleries all have the same wrapper #main-gallery. The strange this is the first time I call .unitegallery() on a new gallery, it loads but does not display at all, even though a lot of the markup is added to the gallery. If I click the same button again (to load that same gallery) it will load fine.

What do I have to do to make this work the first time? Thanks a lot!

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/vvvmax/unitegallery/issues/101, or mute the thread https://github.com/notifications/unsubscribe-auth/AC_K_hii4YNVwq-e5cix8LE10vyVqgnoks5qfk6YgaJpZM4Jjx_F .

ridinghoodmedia commented 8 years ago

Thanks for that offer! I think for now it's best to just use it as intended if the functionality is not working by default. I'll keep you posted on any findings if I decide to take it on again. Thank you