thank you for the thoughtful response and the new slideshow recommendation. 
i am considering the transition, but am also hoping to save myself from 
fully rebuilding the site. is an "initialSlideIndex" type variable 
something that could potentially be added to my current gallery, even if is 
not the most beautiful coding solution? or am i stuck in a situation where 
i rebuild, or can't have that feature?

thank you again for the information!



On Friday, October 26, 2012 2:27:52 AM UTC-7, Rolf Langenhuijzen wrote:
>
> I think you should drop the gallery you are using now. It was a good 
> excercise with JS, but the code is not optimal and the gallery is not so 
> flexible.
>
> There are probably a few good slide show gallery "plug ins" available, but 
> one that is very nice and well coded is Ryan Florence's SlideShow.
> Check it at: http://ryanflorence.com/slideshow/
>
> You can simply start with a container of elements (e.g. images or images 
> in divs), hook up the SlideShow and it works.
> Then you can start using the events the class fires (like onShow or 
> onShowComplete) to trigger other stuff outside of the gallery code that is 
> specific to your use case. For example showing some captions or other 
> information in some div or whatever. Or, like in your demo hook up the 
> previous/next buttons to the code.
>
> What you can do for example is store the caption information in a 
> data-attribute in the element that is the image. For example:
> <img src="gallery/la_o_13.jpg" data-size="40x60in (101x152cm)" 
> data-medium="Digital C-Print" data-year="2011" data-caption="Silencio 
> ChiƱulito">
> Now you can write a function (outside of the SlideShow code, perhaps in a 
> separate class) that does all the stuff after sliding using the element 
> data-properties you defined.
> It's much cleaner to decorate the elements instead of pushing everything 
> into JS like your current setup.
>
> If you are comfortable with the settings you can start looking at the 
> effects for sliding, but there are default ones that are probably fine.
>
> SlideShow also has a variable called initialSlideIndex that you can set so 
> that you can skip directly to image X in your collection on startup.
>
> If you have any questions, don't hesitate to ask here.
> Maybe it feels intimidating to start using MooTools or SlideShow for 
> example, but it's not that hard.
>
> Rolf
>
>
> On Wednesday, October 24, 2012 10:27:01 PM UTC+2, jocrla wrote:
>>
>> i am not sure what the gallery is called. i picked up the code online, 
>> and modified it a bit.
>>
>> the JS for the gallery is here:
>> http://www.outhause.com/lao/js/gallery_lao.js
>>
>> my thought was that i could plug a variable for "current image" into the 
>> url string to make the html page land on an image in the middle of the 
>> gallery. i can't get this to work though. sound possible to you? (full 
>> disclosure, i am a hopeless js novice as well as a mootools newbie)
>>
>> thanks for the forge rec. i will check that out as well.
>>
>> thanks!
>>
>>
>>
>> On Wednesday, October 24, 2012 1:16:38 PM UTC-7, Arian Stolwijk wrote:
>>>
>>> Which gallery are you using? I guess you're using some kind of plugin.
>>> Also you're using an outdated MooTools version (1.2.1 instead of 1.4.5).
>>>
>>> Maybe you should look in the forge (http://mootools.net/forge/) for 
>>> some better slideshows.
>>>
>>> On Wed, Oct 24, 2012 at 10:01 PM, jocrla <[email protected]> wrote:
>>>
>>>> Hello,
>>>>
>>>> I setup an image gallery using mootools, and have been unable to figure 
>>>> out how to create a direct link that would send a user to an image in the 
>>>> middle of the gallery, opposed to just the first image. 
>>>>
>>>> an example of the gallery is posted here:
>>>> http://www.outhause.com/lao/gallery_lao.html
>>>>
>>>> Obviously i am a mootools newbie, and i have been scratching my head 
>>>> over this one for some time. If anyone has the answer to this question, it 
>>>> would be very much appreciated.
>>>>
>>>> thanks!
>>>>
>>>
>>>

Reply via email to