dimsemenov / PhotoSwipe

JavaScript image gallery for mobile and desktop, modular, framework independent
http://photoswipe.com
MIT License
24.28k stars 3.31k forks source link

Open single image in PhotoSwipe? #984

Open csborgman opened 9 years ago

csborgman commented 9 years ago

PhotoSwipe does not support single images? Is this possible?

Works great for galleries but single images in posts (for example) do not open in PS.

Workaround?

dimsemenov commented 9 years ago

There aren't any known issues with a single image.

Please provide a reduced test case (isolated example) that reproduces the problem.

You may create it based on CodePens in PhotoSwipe documentation: raw gallery, gallery with thumbnails, custom HTML content in slides. If you're not comfortable with CodePen, you may export code via Share -> Export .zip, and upload test case to your server.

csborgman commented 9 years ago

I'm using a WP plugin based on your script: https://wordpress.org/plugins/photo-swipe/ so I guess that's where the problem is. I'm not anywhere experienced enough to be digging around in the plugin's php and js so if you have an idea where the problem might be I'll hire someone to fix it because the plugin author is MIA.

These are really the only 2 files in the plugin, other than photoswipe scripts: https://bitbucket.org/snippets/csborgman/5EraG

Please advise, Thanks!

csborgman commented 9 years ago

OK, so in WP if I manually add data-size=" " then a single image opens in PS: http://master2.lightboxlive.com/single-image/

Please suggest a clue to fix this so I can explain to the person I hire.

Thanks again!

ghost commented 7 years ago

@csborgman please close. consider moving to stackoverflow if issue persists