Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I created a customized nav using the Sharepoint aspmenu with simple rendering which binds to an xml datasource to render the menu contents.

I am then using a the jquery UI accordion to style it.

The problem is that sometimes if the page is loading slowly it shows the fully expended (simple rendered view) before the page has chance to load and apply the jquery/css styles against it.

I don't want to write code to lazy load it but was thinking maybe I could just not show the menu until I know for sure that all the css and javascript has been loaded and the style applied. I just can't think of the best way to tackle this.

Any ideas?

share|improve this question
add comment

1 Answer

up vote 3 down vote accepted

If you are already working on it with jQuery then set it to hidden by default then change to show after you have applied the accordion.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.