Minislideshow instead of static image
pavel.pola
Joined: 2007-05-19
Posts: 30 |
Posted: Mon, 2009-12-28 23:52 |
Hi all, first of all thank you very much for your effort!!! Your Gallery is my favorite! I'd like to make a "portfolio" album of my best work or exhibits. I'd like to make it using Gallery2 and MinislideShow from http://www.flashyourweb.com/. My idea is: 1. I have hidden portfolio album with all my best photos from one exhibition When users on my site enter My Portfolio they will choose which exhibition they like and instead of showing single image, minislideshow will start (inside a photo container, so every other functions like navigation, comments, ratings etc. are on the page). Is there some simple way how to do it? I was thinking about "hardcoded hack" into photo.tpl but maybe there is some more clever solution. Thanks in advance! Pavel |
|
Posts: 8339
Two ideas:
gsContent would be gallery's containing div we want to replace - carbon uses it.
untested
-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2
Posts: 30
Thanks for help but where to place the above code? Album.tpl is not the best place because I'd like to have a "album" with all my exhibitions and when somebody click one exhibition, the slideshow will start instead of single photo.
Pavel
_________________________________
Please visit my personal gallery: http://www.pavelpola.cz (mostly B&W pictures, Prague, nature, people)
Posts: 8339
album.tpl is fine, notice the code is wrapped in an "if" statement and $theme.item.id == 418 || $theme.item.id == 620 || $theme.item.id == 990 would be the list of only the albums you want to show as a slideshow.
but it would be best to place this near the end of your page, so near the bottom of theme.tpl would be better before the end of the body.
if you are going to have just albums that share one common parent you could just use the parentId instead:
{if $theme.parent.id == 990}
-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2
Posts: 30
Thank you very much for your help! My work is finished and I'm very happy with it: http://www.pavelpola.cz/foto/portfolio/
I've used these Gallery features:
- replica plugin for creating copies of portfolio photos into portfolio albums (portfolio albums are standard gallery albums - just click on any photo in flash presentation and you will get standard photo browser)
- template modification: theme.tpl - I've placed this portion of code into <head> section (recommended for SWFObject 2.2)
- I had to add
id="gsContentAlbum"
in album.tpl because I wanted to use that div which had only class name:<div class="gsContentAlbum" id="gsContentAlbum">
- I have also changed album.tpl - I've hidden navigation links when displaying flash presentation
It would be fine if new gallery will support immediate flash presentation of selected albums. It's not so difficult to manage it but it would be fine to have some "switch" in gallery to avoid hardcoded ids exceptions).
Thank you again for your help.
Pavel
_________________________________
Please visit my personal gallery: http://www.pavelpola.cz (mostly B&W pictures, Prague, nature, people)
Posts: 8339
Glad you got it figured out
I prefer swfobject 1.5 as its more flexible and we already include it in the flashvideo module /modules/flashvideo/lib/swfobject.js same with the mp3audio module.
-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2
Posts: 30
Please one more help - when browsing with IE 8, no flash is displayed (normal album is shown). Does somebody know where is the problem?
Thanks
Pavel
_________________________________
Please visit my personal gallery: http://www.pavelpola.cz (mostly B&W pictures, Prague, nature, people)
Posts: 8339
Your javascript replacement is happening before the page has loaded - even before the gsContentAlbum div exists.
Part of the reason I prefer swfobject 1.5 as you can place it at the bottom of the page after the target div.
But all you need to do is use a load handler - I'll cover all browsers:
-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2
Posts: 30
Thank you, you suggested replacement was not working so I have installed swfobject 1.5 and now it is working fine in both browsers. Thank you for your help.
Pavel
_________________________________
Please visit my personal gallery: http://www.pavelpola.cz (mostly B&W pictures, Prague, nature, people)
Posts: 4
HELLO
Great job with this modification. I've test it on my site. I have two ideas to make it better and I hope You help me with it. I run gallery 2,3 and I paste code from abowe in to my album.tpl . Works fine. But... First, I would like to keep my left side menu witch slideshow, but somehow it owerwrite all gscontent ( so.write("gsContent"); ) Can You show me how to cover only thumbnail section and keep menu ? And second thing, Is it posible to hide slideshow and show regular content( i mean thumbnails ) when the user click some button ? The idea is to first show the slideshow , but left the way to watch thumbnails and come back to slideshow on the same album.tpl , or go to big picture on photo.tpl from both.
I'm soory for my syntax and ortography. I better read then write in english ;]
thanks in advance
Posts: 8339
which theme are you using?
You don't need to use gsContent you can give your <div> any id you want.
You could load the page with both the thumbs and the mini into two divs with unique IDs and hide one:
untested
-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2
Posts: 1642
Bookmarking this for later consideration.
--
dakanji.com
Posts: 4
Hi
Thanks for help. This is exactly what I wanted. Of corse I messed up something... But from start... I use carbon theme. I done what You told me. It fix some problems, but in the case of toggle button no metter where I paste this javascript code it ruin whole template. I think that I done just some simple mistake. Please take a look.
And one more thing. This loadHandler... It shows for fiew seconds some code text in time when the slideshow loads. Maby I'm little paranoic but it's annoying...
Thanks again for Your help.
Posts: 8339
surround your javascript with literal tags:
-s
FlashYourWeb and Your Gallery with The E2 XML Media Player for Gallery2
Posts: 4
Ewerything works fine. Thanks for Your time.
I post all again to other interested.