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.

  1. enables partial page rendering
  2. eanbles client side script access web services
  3. 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

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - .htaccess mod_rewrite for dynamic url which has domain names -

Website Login Issue developed in magento -