domready problem in internet explorer, its taking too much time

Hi all,

I have some JavaScript which i have developed using mootools1.2.

I have attached the code.

I have used the domready event to assign the different events to the elements.

Problem is the it creating problem in Internet Explorer.

Not creating problem with my code nor and error occurring.

But its take too much time to complete the loading of the page.

If i remove the code from page then its works fast in IE.

I have change the domready to onload but no effects.

So I am here to get some guideline regarding using the domready or onload or to optimize my code.

Hope i am pretty clear to you all.

Thanks
Addy
window.addEvent('domready',function(){
	var mySlide = new Fx.Slide('top-panel',{mode: 'horizontal'});
	$('image_li').addEvent('click', function(e){

		$('menuopenar').setStyle('display','none');
		$('menuopenar').setStyle('visibility','hidden');
		mySlide.slideIn();
		e.stop();		
	});
	
	
	var parent = $('top-panel').getParent('div');
	parent.setStyle('float','left');
	mySlide.slideOut();
	$('image_li').addClass('menuclose');

	$('close_link').addEvent('click',function(e){
		e.stop();
		mySlide.slideOut();
		$('menuopenar').setStyle('display','block');
		var d= function(){$('menuopenar').fade(1);}.delay(500);
	});
});

Open in new window

LVL 12
Avinash ZalaWeb ExpertAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

StealthyDevCommented:
I hope domready / onload is not a problem in IE.. I hope some other FX you have used is the problem.

Try reducing some scripts like Fx.Slide and see the performance.

Try to move the onload to a button click and find the time taken?

Regards.
0
Avinash ZalaWeb ExpertAuthor Commented:
yes when i remove the FX slide code then it works fine..

Thanks
Addy
0
StealthyDevCommented:
Ok, now try FX slide in a button click and check the performance. Iff it is slow again, the cause would be the div element's objects. Try to reduce the amount of objects and test again.

Regards.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Avinash ZalaWeb ExpertAuthor Commented:
Thx for your help,

Your comments is not actually a solution, but it leads me to my solution.

Thanks Again
Addy
0
Avinash ZalaWeb ExpertAuthor Commented:
hi,
You comments leads me to my solution
Thanks
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Components

From novice to tech pro — start learning today.