简体   繁体   中英

How to include my javascript file after Telerik includes their javascript

I would like to override Tekerik's javascript function. To do that I want to include a file that contains modified javascript after Telerik's js include.

I include my js files using ClientScriptManager.RegisterClientScriptBlock method. My files are included before Telerik's preventing me from overriding their function.

<script type="text/javascript" src="myScriptFile.js"></script>
<script src="/atlas/Telerik.Web.UI.WebResource.axd?....></script>

How can I include my javascript file after Telerik's?

One option that I found is to use RegisterStartupScript method that

 "emits the script just before the closing tag of the Page object's <form runat= server> element."

which is after Telerik includes their files. This doesn't include a js file but at this point I can call a function that overrides Telerik's function.

假设您要全局执行此操作,是否考虑过编辑Telerik源文件而不是覆盖它?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM