I need a slight tweak in for the Slide.FX script. I basically need the
script to behave the way it was normally intended. I'm using the
Horizontal / Toggle function. The default state of the sliding box is
visible after a page load. You see it, you click it, it slides and
disappears. However, I'd need it to do the reverse. I want the page to
load and have the sliding box already invisible. THEN, when you click
toggle, the box slides in and appears. Is there a way to reverse this
behavior by tweaking the following default code?


window.addEvent('domready', function() {
       var status = {
               'true': 'open',
               'false': 'close'
       };

       var myHorizontalSlide = new Fx.Slide('horizontal_slide',
{mode:
'horizontal'});

       $('h_toggle').addEvent('click', function(e){
               e.stop();
               myHorizontalSlide.toggle();
       });

       myHorizontalSlide.addEvent('complete', function() {
               $('horizontal_status').set('html',
status[myHorizontalSlide.open]);
       });


// With a little research here and there, I put together my own code,
but I don't know HOW and *WHERE* to place it in the default script and
whether or not I have to tie it into my HTML. Here:

var collapsible = new Fx.Slide(‘horizontal_slide’).hide();;

collapsible.toggle();

})


I tried getting the default FX.Slide script working, which failed,
telling me that I'm using the shell wrong. My attempt:

http://mootools.net/shell/ZBNmD/1/

Please help!  I have a jquery script up and running (without animated
slide) and don't want to switch to the dark side! )


-- 
Subscription settings: 
http://groups.google.com/group/mootools-users/subscribe?hl=en

Reply via email to