javascript - What does a ScriptManager script reference do? -
on previous project working on, noticed javascript files included inside script manager so:
<asp:scriptreference path="~/scripts/jquery-1.7.1.min.js" /> <asp:scriptreference path="~/scripts/site.js" />
i've tried searching difference between script reference , regular <script src="/>
in asp page can't seem find information. there advantage using script reference?
thanks
when using scriptmanager single composite script can created reduce number of browser requests asp.net.
you can refer scriptreference class
also about
section of scriptmanager tells more details it:
scriptmanager asp.net control manages asp.net ajax script libraries. scriptmanager performs following functions.
- enables partial page rendering
- eanbles client side script access web services
- enables use of authenication , profile services client
only 1 scriptmanager can allowed per page. scenarios second scriptmanager reference required, such within usercontrol, scriptmanagerproxy control should used.
Comments
Post a Comment