jQuery in Firefox

Posted by Community Admin on 05-Aug-2018 22:02

jQuery in Firefox

All Replies

Posted by Community Admin on 25-May-2011 00:00

I'm using Sitefinity 4.1 SP1 and trying to use jQuery on my pages.  It works fine everywhere except Firefox.  In Firefox, jQuery is not loading correctly.  jQuery is not defined, $ is defined, but contains methods other than those in jQuery, and $('div') pulls back undefined, so $ does not contain default jQuery behavior.

Does Sitefinity use $ for any of its javascript libraries that would be overriding the jQuery definition?
Has anyone else experienced any issues using jQuery in Firefox?
Again, everything is functioning normally in other browsers.  This is specific to Firefox.

Thanks.

Posted by Community Admin on 27-May-2011 00:00

Hi Geoff,

Sitefinity is using its own jQuery, the problem may be that we are using the same jQuery to do other things so please refer to this article. If the problem still persists please provide more information on the version of firefox you are using, are you inserting the jQuery code in a template or using the javascript widget.

Feel free to write back.

Greetings,
Stanislav Velikov
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get now >>

Posted by Community Admin on 27-May-2011 00:00

I don't believe I am able to use that.  In Firefox "$" no longer refers to the jQuery library and "jQuery" is undefined, so I am not able to call jQuery.noConflict().

I am not referencing my own jQuery library, so the library that you are using should be the one that is available.

I am trying to use jQuery functionality in a widget, but attempting to use jQuery through the Firebug console results in the same behavior, so I don't believe the widget is related to the problem.

I am using Firefox 4.0.1.

Are there any known issues with Sitefinity 4.1.1405.0 related to jQuery usage or is anyone else able to reproduce this behavior?

Thanks.

Posted by Community Admin on 30-May-2011 00:00

Hi Geoff,

Thank you for the clarifications.
We are loading jQuery from Telerik.Web.UI which is used by our ASP.NET AJAX controls, an in addition to that the jQuery core is loaded you can make the reference $telerik.
Out of the box $(document).ready() is available but since you are making controls you have to make sure that jQuery is used

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



Regards,
Stanislav Velikov
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get now >>

This thread is closed