Thanks for both replies - much appreciated!
> > Hi
> > I am using cflayout accordion with only one item which I want 
> > collapsed on page load.
> > I've eventually put this code in:
> > <body onload="ColdFusion.Layout.collapseAccordion('accordionLayout', 
> 
> > 'panel01')">
> > 
> > This works in FF and Chrome but NOT in IE8, which 1) does NOT open 
> > collapsed and 2) gives a javascript error 
> > Message: Exception thrown and not caught
> > Line: 90
> > Char: 1
> > Code: 0
> > URI: http://127.0.0.1:8500/CFIDE/scripts/ajax/package/cfajax.js
> > 
> > So my questions are
> > 1. Is using the onLoad function the best way to have the accordion 
> > closed on page load
> > 2. How do I get it to work in IE? And with no errors?
> > Hope someone can help - this is driving me nuts
> > Ta
> > Seamus 
> 
> I ran into this exact problem yesterday. I found that the only way to 
> make it work right was to use the CF ajaxonload function like so:
> 
> <cfset ajaxonload="ColdFusion.Layout.
> collapseAccordion('accordionLayout','panel01')">
> 
> For some reason IE runs any onloads you define through javascript 
> before it gets the accordion loaded, as I found out when I added an 
> alert to my function to collapse an accordion. Annoying, yes? Anyway 
> the ajaxonload function works the way you'd expect it to. 


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334077
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to