diff --git a/api/en/fn.zTree._z.html b/api/en/fn.zTree._z.html index 61da261d8a38ba687b31060dc65a9999e6909308..e2ae61d66fb93fc73298304882b84c8cee343642 100644 --- a/api/en/fn.zTree._z.html +++ b/api/en/fn.zTree._z.html @@ -1,13 +1,15 @@ <div class="apiDetail"> <div> - <h2><span>JSON</span><span class="path">$.fn.zTree.</span>_z</h2> - <h3>Overview<span class="h3_info">[ depends on <span class="highlight_green">jquery.ztree.core</span> js ]</span></h3> - <div class="desc"> - <p></p> - <div class="longdesc"> - <p>All of the methods in zTree v3.x are available through the '$. fn.zTree._z' calls, open it for you to develop your own zTree plug-ins.</p> - <p class="highlight_red">If you have no special requirements, please don't use this object, and don't modify the methods in this object.</p> - </div> - </div> + <h2><span>JSON</span><span class="path">$.fn.zTree.</span>_z</h2> + <h3>Overview<span class="h3_info">[ depends on <span class="highlight_green">jquery.ztree.core</span> js ]</span></h3> + <div class="desc"> + <p></p> + <div class="longdesc"> + <p>All of the internal methods in zTree v3.x are available through '$. fn.zTree._z', + use this if you want to develop your own zTree plug-ins.</p> + <p class="highlight_red">Unless you are writing a plugin, + you should not use this object.</p> + </div> + </div> </div> </div> \ No newline at end of file diff --git a/api/en/fn.zTree.destroy.html b/api/en/fn.zTree.destroy.html index 3a3169993f48622ab12d3abccff963ebb87a471d..c53cb8009a0e2020aaa897018844f080b855fdad 100644 --- a/api/en/fn.zTree.destroy.html +++ b/api/en/fn.zTree.destroy.html @@ -5,24 +5,25 @@ <div class="desc"> <p></p> <div class="longdesc"> - <p>From zTree v3.4, zTree support the method for destruction.</p> - <p>1. This method can destroy the zTree with specify treeId, and can destroy all of the zTrees.</p> - <p class="highlight_red">2. If you want to destory some one zTree, you can use the 'zTreeObj.destroy()' method.</p> - <p class="highlight_red">3. If you want to use the tree which has been destroyed, you must use the 'init()' method at first.</p> + <p>From zTree v3.4, zTree provides a method for destruction.</p> + <p>1. This method can destroy a zTree by treeId, or destroy all zTree instances.</p> + <p class="highlight_red">2. If you want to destroy a zTree, you can use the 'zTreeObj.destroy()' method.</p> + <p class="highlight_red">3. If you want to re-use the tree which has been destroyed, + you must first re-initialise it with the 'init()' method.</p> </div> </div> <h3>Function Parameter Descriptions</h3> <div class="desc"> <h4><b>treeId</b><span>String</span></h4> <p>zTree unique identifier</p> - <p class="highlight_red">If this parameter is omitted, then will destroy all of the zTrees.</p> + <p class="highlight_red">If this parameter is omitted, all zTree instances will be destroyed.</p> <h4 class="topLine"><b>Return </b><span>none</span></h4> <p>no return value</p> </div> <h3>Examples of function</h3> - <h4>1. destroy the zTree which its id is 'treeDemo'</h4> + <h4>1. Destroy the zTree with id === 'treeDemo'</h4> <pre xmlns=""><code>$.fn.zTree.destroy("treeDemo");</code></pre> - <h4>2. destroy all of the zTrees</h4> + <h4>2. Destroy all zTree instances</h4> <pre xmlns=""><code>$.fn.zTree.destroy();</code></pre> </div> </div> \ No newline at end of file diff --git a/api/en/fn.zTree.getZTreeObj.html b/api/en/fn.zTree.getZTreeObj.html index 2bc0447628b113630d6f6279b33d546255c79047..49dadaa95595dd6d0c20b74123b80b245b79b32a 100644 --- a/api/en/fn.zTree.getZTreeObj.html +++ b/api/en/fn.zTree.getZTreeObj.html @@ -5,9 +5,11 @@ <div class="desc"> <p></p> <div class="longdesc"> - <p>zTree v3.x specifically provide the method which can use the tree's Id to get zTree object.</p> + <p>zTree v3.x provides this method to get zTree object from the tree's Id.</p> <p class="highlight_red">Please initialize zTree first, then you can use this method.</p> - <p>Users don't need to set the global variable to hold the zTree object, and all of the callback will return 'treeId' parameters, the user can always use this method to get the zTree object.</p> + <p>Users don't need to use a global variable to reference the zTree object, + as all of the callback methods will pass 'treeId' parameters, + and you can always call this method to get the zTree object.</p> </div> </div> <h3>Function Parameter Descriptions</h3> @@ -16,10 +18,10 @@ <p>zTree unique identifier</p> <h4 class="topLine"><b>Return </b><span>JSON</span></h4> <p>zTree object</p> - <p>This object can provide the methods of operate the zTree</p> + <p>This is a reference to the zTree object.</p> </div> <h3>Examples of function</h3> - <h4>1. Get the zTree object which id is 'tree'</h4> + <h4>1. Get the zTree object with id='tree'</h4> <pre xmlns=""><code>var treeObj = $.fn.zTree.getZTreeObj("tree");</code></pre> </div> </div> \ No newline at end of file diff --git a/api/en/fn.zTree.init.html b/api/en/fn.zTree.init.html index cf97d2bc0d46035929e7ce4c59a19d4485eb7de3..b8c5e2a6cba425647d734b7bf8948caae11cd012 100644 --- a/api/en/fn.zTree.init.html +++ b/api/en/fn.zTree.init.html @@ -5,13 +5,18 @@ <div class="desc"> <p></p> <div class="longdesc"> - <p>The method which used to create zTree.</p> - <p>1. The web page need to use W3C markup. For example: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"></p> - <p>2. Need to load jquery-1.4.2.js or other higher versions.</p> - <p>3. Need to load jquery-ztree.core-3.0.js. If you need to use the edit mode or checkbox / radio mode, you need to load jquery-ztree.exedit-3.0.js and jquery-ztree.excheck-3.0.js.</p> - <p>4. Need to load zTreeStyle.css and image files</p> - <p>5. If you need to use custom icons, please refer to the appropriate Demo.</p> - <p>6. Note: You need to set zTree container's class name to "ztree". If you need to change, don't forget to modify the css file. If you need other special styles, can modify the css file to their own needs.</p> + <p>This method is used to create a zTree.</p> + <p>1. The web page must use the W3C DTD. For example: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"></p> + <p>2. Needs jquery-1.4.2.js or better.</p> + <p>3. Needs jquery-ztree.core-3.0.js or better. + If you are using edit mode or checkbox / radio mode, + make sure you load jquery-ztree.exedit-3.0.js and jquery-ztree.excheck-3.0.js.</p> + <p>4. Needs zTreeStyle.css and image files</p> + <p>5. If you plan to use custom icons, please refer to the Demo, + or see the help on iconSkin.</p> + <p>6. Note: You need to set zTree container's class name to "ztree". + If you need to change it, don't forget to modify the css file. + If you need other special styles, you can modify the css file.</p> </div> </div> <h3>Function Parameter Descriptions</h3> @@ -22,9 +27,10 @@ <p>zTree's configuration data, please refer to "setting details" in the API Document.</p> <h4 class="topLine"><b>zNodes</b><span>Array(JSON) / JSON</span></h4> <p>zTree's node data, please refer to "treeNode data details" in the API Document.</p> - <p class="highlight_red">1. zTree v3.x support to add single node, that is, if only to add one node, you can use JSON without using Array.</p> - <p class="highlight_red">2. If you need asynchronous load root nodes, can be set to null or [ ]</p> - <p class="highlight_red">3. If you use simple data mode, please refer to "setting.data.simpleData" in the API Document.</p> + <p class="highlight_red">1. zTree v3.x support to add single node, that is, if only to add one node, + you can use JSON without using Array.</p> + <p class="highlight_red">2. If you are planning on using asynchronous loading of root nodes, set it to null or [ ]</p> + <p class="highlight_red">3. If you are using simple data mode, please refer to "setting.data.simpleData" in the API Document.</p> <h4 class="topLine"><b>Return </b><span>JSON</span></h4> <p>zTree object</p> <p>This object can provide the methods of operate the zTree</p> diff --git a/api/en/setting.async.autoParam.html b/api/en/setting.async.autoParam.html index 85cd46919c116b63604bdbfa715aabbd5646684a..e187b16e12d7e77766e0d58dad2ca4f6d1ab0f3d 100644 --- a/api/en/setting.async.autoParam.html +++ b/api/en/setting.async.autoParam.html @@ -5,14 +5,17 @@ <div class="desc"> <p></p> <div class="longdesc"> - <p>Required automatically submit the parameters about the properties of the parent node, when the asynchronous load. It is valid when <span class="highlight_red">[setting.async.enable = true]</span></p> + <p>During asynchronous loading, a request is sent to the server, which contains the identify of the parent node, + so it can retrieve the children. + This attribute is an array of strings, which is the identity parameter (or parameters). + It applies when <span class="highlight_red">[setting.async.enable = true]</span></p> <p>Default:[ ]</p> </div> </div> <h3>Array(String) Format</h3> <div class="desc"> - <p>1. Just save the attribute name of node to the array. For example: ["id", "name"]</p> - <p>2. You can change the parameter name. For example: server only accepts "zId" -- ["id=zId"]</p> + <p>1. Put the attribute name(s) of node to the array. For example: ["id", "name"]</p> + <p>2. You can rename the parameter name as sent to the server. For example: server only accepts "zId" -- ["id=zId"]</p> </div> <h3>Examples of setting</h3> <h4>1. set auto commit 'id' attribute</h4> @@ -23,9 +26,9 @@ autoParam: ["id"] } }; -If have the parent node: {id:1, name:"test"}, When asynchronously load this parent node's child nodes, will be submitted parameters: id=1 +If we have a parent node: {id:1, name:"test"}, When we are asynchronously loading this parent node's children, it will be submitted to the server with parameters: id=1 ......</code></pre> - <h4>2. set auto commit 'id' attribute, but parameter name is 'zId'</h4> + <h4>2. set auto commit 'id' attribute, but the parameter name expected by the server is 'zId'</h4> <pre xmlns=""><code>var setting = { async: { enable: true, @@ -33,7 +36,7 @@ If have the parent node: {id:1, name:"test"}, When asynchronously load this pare autoParam: ["id=zId"] } }; -If have the parent node: {id:1, name:"test"}, When asynchronously load this parent node's child nodes, will be submitted parameters: zId=1 +If we have a parent node: {id:1, name:"test"}, When we are asynchronously loading this parent node's children, it will be submitted to the server with parameters: zId=1 ......</code></pre> </div> </div> \ No newline at end of file diff --git a/api/en/setting.async.contentType.html b/api/en/setting.async.contentType.html index cc9bfcd35c9472422498d2ebcdba8fa06d49f537..c9e150995b3e05d7e5e6c3c7024c8f2b55ac974b 100644 --- a/api/en/setting.async.contentType.html +++ b/api/en/setting.async.contentType.html @@ -5,7 +5,8 @@ <div class="desc"> <p></p> <div class="longdesc"> - <p>When Ajax sending data to the server, use this content-type. It is valid when <span class="highlight_red">[setting.async.enable = true]</span></p> + <p>When Ajax sends data to the server, it uses this content-type. + It is used when <span class="highlight_red">[setting.async.enable = true]</span></p> <p>Default:"application/x-www-form-urlencoded"</p> </div> </div> diff --git a/api/en/setting.async.dataFilter.html b/api/en/setting.async.dataFilter.html index 34733e4d3cf766913959b32ee1dae582f786d430..4347a0822d73e7fe69d80ab20d7742018cfb72f5 100644 --- a/api/en/setting.async.dataFilter.html +++ b/api/en/setting.async.dataFilter.html @@ -5,26 +5,26 @@ <div class="desc"> <p></p> <div class="longdesc"> - <p>Function used to pre-process for the return data of Ajax. It is valid when <span class="highlight_red">[setting.async.enable = true]</span></p> + <p>Callback function to pre-process Ajax return data. It is valid when <span class="highlight_red">[setting.async.enable = true]</span></p> <p>Default: null</p> </div> </div> <h3>Function Parameter Descriptions</h3> <div class="desc"> <h4><b>treeId</b><span>String</span></h4> - <p>zTree unique identifier: <b class="highlight_red">treeId</b>, easy for users to control.</p> + <p>zTree unique identifier: <b class="highlight_red">treeId</b></p> <h4 class="topLine"><b>parentNode</b><span>JSON</span></h4> <p>Parent node's JSON data object</p> <p class="highlight_red">When asynchronously loading the root, the parentNode = null</p> <h4 class="topLine"><b>responseData</b><span>Array(JSON) / JSON / String</span></h4> - <p>Ajax got Array (JSON) / JSON / String data objects</p> - <p class="highlight_red">From v3.4, support the string with XML format.</p> + <p>Array (JSON) / JSON / String data objects</p> + <p class="highlight_red">From v3.4, support XML strings.</p> <h4 class="topLine"><b>Return </b><span>Array(JSON) / JSON</span></h4> <p>The return value should be the JSON data structure which is supported by the zTree.</p> <p class="highlight_red">v3.x supports to load single node JSON data object.</p> </div> <h3>Examples of setting & function</h3> - <h4>1. Modify the node name attribute which is ajax got.</h4> + <h4>1. Modify the node name attributes returned by an Ajax request.</h4> <pre xmlns=""><code>function ajaxDataFilter(treeId, parentNode, responseData) { if (responseData) { for(var i =0; i < responseData.length; i++) { diff --git a/api/en/setting.async.dataType.html b/api/en/setting.async.dataType.html index e6672e9b4f70610a5f56f9c739260a077f794851..1aee441b5791008270af33e2ffa80eb7ced2a30f 100644 --- a/api/en/setting.async.dataType.html +++ b/api/en/setting.async.dataType.html @@ -11,11 +11,11 @@ </div> <h3>String Format</h3> <div class="desc"> - <p> dataType = "text", It can meet most of the needs.</p> - <p class="highlight_red">The 'dataType' in zTree and jQuery's ajax is same.</p> + <p> dataType = "text", There is probably no need to change this.</p> + <p class="highlight_red">The 'dataType' in zTree and jQuery's ajax requests is same.</p> </div> <h3>Examples of setting</h3> - <h4>1. Set the dataType which ajax got is text.</h4> + <h4>1. Set the dataType which ajax retrieves to "text".</h4> <pre xmlns=""><code>var setting = { async: { enable: true, diff --git a/api/en/setting.async.enable.html b/api/en/setting.async.enable.html index 806ba6c65ae4e140df8d6509178f014a8df4efb1..c28447649812412ce983dc45ec87e2d60958c75f 100644 --- a/api/en/setting.async.enable.html +++ b/api/en/setting.async.enable.html @@ -5,7 +5,7 @@ <div class="desc"> <p></p> <div class="longdesc"> - <p>Set zTree asynchronous loading mode is turned on or off.</p> + <p>Set zTree asynchronous loading mode on/off.</p> <p>Default: false</p> </div> </div> @@ -13,8 +13,8 @@ <div class="desc"> <p> true - turn on asynchronous loading mode</p> <p> false - turn off asynchronous loading mode</p> - <p class="highlight_red">If set it is true, you must set attributes in setting.async</p> - <p class="highlight_red">If you don't pass 'treeNodes' parameter when initialize zTree, the root nodes will get by ajax.</p> + <p class="highlight_red">If set it is true, you must set other attributes in setting.async</p> + <p class="highlight_red">If you don't pass the 'treeNodes' parameter when you initialize zTree, the root nodes will be retrieved using ajax.</p> </div> <h3>Examples of setting</h3> <h4>1. Turn on asynchronous loading mode</h4>