1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / Developing with Sitefinity / Path to jQuery

Path to jQuery

4 posts, 0 answered
  1. Thomas
    Thomas avatar
    223 posts
    Registered:
    19 Jan 2011
    04 Nov 2011
    Link to this post
    Hi,

    I'd like to reference the jQuery namespace in Sitefinity (I need to in order to work around a ResourceLinks script order bug). For now, I'm doing "Telerik.Sitefinity.Resources.Scripts.jquery-1.6.2.min.js". This is not convenient, because the jQuery version is referenced, and it keeps changing with each Sitefinity version, forcing me to update my code each time I update Sitefinity.

    Can I dynamically retrieve the version of the jQuery shipped with Sitefinity? Or is there a reliable jQuery path that never changes, or something?

    Thanks.
  2. Victor Velev
    Victor Velev avatar
    1345 posts
    Registered:
    06 Jul 2015
    07 Nov 2011
    Link to this post
    Hello Thomas,

    You can reference to the built - in Jquery in Sitefinity ( for example in a masterpage ):

    <%@ Register Assembly="Telerik.Sitefinity" Namespace="Telerik.Sitefinity.Web.UI" TagPrefix="sf" %>
        
    // your logic here
        
    <sf:ResourceLinks id="resourcesLinks" runat="server">
    <sf:ResourceFileJavaScriptLibrary="JQuery"/>
    </sf:ResourceLinks>


    Regards,
    Victor Velev
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Thomas
    Thomas avatar
    223 posts
    Registered:
    19 Jan 2011
    08 Nov 2011
    Link to this post
    Hi Victor,

    Yes, I know. As I said, the reason I don't do this is due to a bug in the ResourceLinks control (to sum things up, jQuery is loaded too late if I do what you propose). This is detailed here. I went for the CompositeScript approach that Radoslav suggested there.

    Can you propose another solution? Also, do you know if there is a PITS report for the ResourceLinks problem?

    Thanks.
  4. Victor Velev
    Victor Velev avatar
    1345 posts
    Registered:
    06 Jul 2015
    10 Nov 2011
    Link to this post
    Hello Thomas,

    Currently there is no other way around this as the problem is coming from the RadScriptManager which is explained by my colleague Radoslav. We have forwarded this request to the teams managing the RadControls so they can diagnose and fix the problem.

    All the best,
    Victor Velev
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
4 posts, 0 answered