3

enter code hereHi

I am new to juice UI and jQuery in general, but wanted to used juice in my app. Now I downloaded the package via Nuget and install log was fine. And all scripts is located in the scripts folder and contents folder, in short all looks good.

Now problem is, when I add my control, tried both acordion and button I get "'jQuery' is undefined" and control is not working. Using IE script debugger I can see that it is when amplify is used: SCRIPT5009: 'jQuery' is undefined amplify.js, line 471 character 2 Refresh the page to see messages that may have occurred before the F12 tools were opened. SCRIPT5009: 'jQuery' is undefined juice.js, line 1 character 2

My code for testing is pretty clean:

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>

    <form id="form1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
<div>


        <button id="_DefaultButton" runat="server">A Button Element</button>
        <juice:button ID="Button1" TargetControlID="_DefaultButton" runat="server" />

</div>
  </form>
</body>
</html>

Anybody any ideas?

2 Answers2

3

I had similar issues, which was resolved by putting the script references into the scriptManager

<asp:ScriptManager runat="server">
  <Scripts>
    <asp:ScriptReference Path="~/Scripts/jquery-1.8.3.js"/>
    <asp:ScriptReference Path="~/Scripts/jquery-ui-1.9.2.js"/>
  </Scripts>
</asp:ScriptManager>

Set the paths to whatever script dependancies you are missing.

Patrick Allwood
  • 1,822
  • 17
  • 21
1

It was a mistake in references to jQuery code, hard coded in JuiceUI dll, looking for jQuery 1.8.0 instead of 1.8.2 . Now it should work if you upgrade to 1.0.1

David
  • 72,686
  • 18
  • 132
  • 173
user1720236
  • 61
  • 1
  • 1