Click here to Skip to main content
15,868,016 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am working on web application in which the master page contains a dynamic jquery accordion and tree view inside accoordion ,li and ul for accordion and treeview coming from database using C# code. a click on tree view link produces postback and at that time li and ul of treeview shows as bullet llist then css applied after child page load

can i load css before child page,as i know master page loads after child page is there any way to load them together
Posted
Updated 12-Sep-14 0:33am
v2
Comments
ZurdoDev 12-Sep-14 7:40am    
How are you loading them? The browser has no concept that there is a master page. All it sees is one page with CSS and JavaScript so my guess is you are loading something via JavaScript after the fact?
Sreekanth Mothukuru 13-Sep-14 7:46am    
Somehow you need to avoid postback to the server on each clicks. To avoid postback, you need to place your accordion and tree view within Ajax UpdatePanel. Also, place all styles require in master page within the head section.
Kornfeld Eliyahu Peter 14-Sep-14 4:37am    
You had successfully messed all the server/client side concepts of web development...
I suggest you make a full stop and read all your written materials again...

1 solution

Please load the CSS in the page_PreInit Event before the master page loads.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900