EasyUI Forum
November 06, 2025, 02:07:39 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
  Home Help Search Login Register  
  Show Posts
Pages: [1]
1  General Category / EasyUI for jQuery / Re: Trying again: json doesn't work on: March 18, 2013, 04:27:41 AM
Oh well, so GWT it is then.
2  General Category / EasyUI for jQuery / Trying again: json doesn't work on: March 15, 2013, 01:46:32 AM
Trying again, to avoid the "look at the example" answers since "the example" doesn't work.

On my web page I have the following two constructs, a simple script tag to call some backend that returns json

Code:
<script type="text/javascript" src="../api/getTreeStuff"></script>

and and easyui-tree that basically should do the same

Code:
<ul id="tt2" class="easyui-tree" url="../api/getTreeStuff"></ul>

The Javascript line calls my server, no problem. The easyui-tree never calls back to the server. On the same page I have put an inline easyui-tree, and that gets rendered fine, so easyui is installed and working. Well, not actually working, but definitely installed. I have tried every conceivable variation on the url, and I have also used the data-options way of specifying the url, nothing can make the easyui-tree code call into my json server.

Any help would be appreciated. Any "see the example" comments is not helpful, since the code is directly from the example, and the code doesn't work.
3  General Category / EasyUI for jQuery / Re: Can not get tree to work with json on: March 14, 2013, 04:50:04 AM

Doesn't work. The server side code is never called.
4  General Category / EasyUI for jQuery / Can not get tree to work with json 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">
<li data-options="state:'closed'"><span>One</span>
    <ul>
            <li data-options="state:'closed'"><span>One-One</span>
                <ul>
                        <li><span>One-one-one</span></li>

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?
Pages: [1]
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!