This question is locked. New answers and comments are not allowed.
Robert Smit
Top achievements
Rank 1
Robert Smit
asked on 27 Nov 2011, 05:01 PM
I'm trying to use the upload control by loading my own jQuery library. So have set:
However when I do so, I can't use the client events, they are not being fired. The rest of the control does work.
What might be the issue here?
@Html.Telerik().ScriptRegistrar().jQuery(false)
However when I do so, I can't use the client events, they are not being fired. The rest of the control does work.
What might be the issue here?
6 Answers, 1 is accepted
0
Samuel
Top achievements
Rank 1
answered on 29 Dec 2011, 04:57 PM
Did you manage to resolve this? I can confirm this is this case. Lost several hours trying to debug.
0
CD
Top achievements
Rank 1
answered on 14 Feb 2012, 06:42 PM
Has this been resolved? I'm having the same issue
0
Hello,
Tsvetomir Tsonev
the Telerik team
Please make sure that you're including jQuery in the page head tag. This is to make sure that it will be loaded by the time the upload is initialized.
Any error messages should be visible in the console.
I hope this helps.
Tsvetomir Tsonev
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
CD
Top achievements
Rank 1
answered on 16 Feb 2012, 01:41 PM
In step 4 of this tutorial it specifically states to put the Telerik Script Registrar at the end of the page:
http://www.telerik.com/help/aspnet-mvc/getting-started-using-telerik-extensions-for-asp.net-mvc-in-your-project.html
By doing so jQuery is automatically included. But the Telerik version of jQuery overwrites new version that is placed in the Head tag of my layout page:
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.0/jquery.min.js" type="text/javascript"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js" type="text/javascript"></script>
If I include my own jQuery tags in the Head tag AND the Telerik Script Registrar then the telerik jQuery causes the jQuery UI Autocomplete plugin to stop working.
If I turn the Telerik jQuery off by specifying @(Html.Telerik().ScriptRegistrar().jQuery(false)) then the javascript actions for the uploader control no longer work. The only way I can get both to work at the same time is to place the Script Registrar in the specific View where I am using the uploader control. This becomes a hassle having to keep track of where I place the script and if I need an Autocomplete or other jQuery UI plugin AND a Telerik control on the same page then only one works, not both!
http://www.telerik.com/help/aspnet-mvc/getting-started-using-telerik-extensions-for-asp.net-mvc-in-your-project.html
By doing so jQuery is automatically included. But the Telerik version of jQuery overwrites new version that is placed in the Head tag of my layout page:
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.0/jquery.min.js" type="text/javascript"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.16/jquery-ui.min.js" type="text/javascript"></script>
If I include my own jQuery tags in the Head tag AND the Telerik Script Registrar then the telerik jQuery causes the jQuery UI Autocomplete plugin to stop working.
If I turn the Telerik jQuery off by specifying @(Html.Telerik().ScriptRegistrar().jQuery(false)) then the javascript actions for the uploader control no longer work. The only way I can get both to work at the same time is to place the Script Registrar in the specific View where I am using the uploader control. This becomes a hassle having to keep track of where I place the script and if I need an Autocomplete or other jQuery UI plugin AND a Telerik control on the same page then only one works, not both!
0
Hello,
The 1.7.0 version of jQuery is not supported. Please use jQuery 1.7.1 and versions 2011.3.1306 / 2012.1.214 of the MVC Extensions.
Tsvetomir Tsonev
the Telerik team
The 1.7.0 version of jQuery is not supported. Please use jQuery 1.7.1 and versions 2011.3.1306 / 2012.1.214 of the MVC Extensions.
Also, the ScriptRegistrar should remain at the end of the page, even with jQuery(false). Please check.
Greetings,Tsvetomir Tsonev
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
0
CD
Top achievements
Rank 1
answered on 17 Feb 2012, 01:46 PM
Thanks, that seems to have fixed it. My jQuery autocomplete still works as well as the uploader control and the javascript events on the control. Thanks!!