|
Title: Can not get tree to work with json Post by: terjeber on March 13, 2013, 12:49:35 AM In my head I have
<script src="/js/jquery-1.8.2.js"></script> <script src="/js/modernizr-2.6.2.js"></script> <script src="/js/jquery-easyui-1.3.2/jquery.easyui.min.js"></script> In my body I have one ul looking like this: Code: <ul id="tt1" class="easyui-tree"> etc... this works fine. Below that I have another ul as so: Code: <ul id="tt2" class="easyui-tree" data-options="url: '../api/getTreeStuff'"></ul> This doesn't work at all. The api/getTreeStuff is never called. I have also tried doing the same on a page load using jQuery, no dice. I can not get this to work at all. I have also tried to simply load the pages that ship with 1.3.2 under demo, and none of the ones using json to load stuff into a tree work. They do not work if I just open the page from disk nor do they work when I put them into a webpage. Please note, if I add the following to my page, the api/getTreeStuff is called no problem. Why is easyui not calling the javascript? Code: <script type="text/javascript" src="../api/getTreeStuff"></script> I have tried with all kinds of URLs, from ../api/xxxxx through /api/xxxxxxx to http://thebloodyserver/api/xxxxxxx What am I doing wrong? Any ideas? Title: Re: Can not get tree to work with json Post by: stworthy on March 13, 2013, 02:27:06 AM Please refer to this example http://www.jeasyui.com/tutorial/tree/tree2.php.
Title: Re: Can not get tree to work with json Post by: terjeber on March 14, 2013, 04:50:04 AM Please refer to this example http://www.jeasyui.com/tutorial/tree/tree2.php. Doesn't work. The server side code is never called. |