qiuyl
23 Dec 2006, 10:00 PM
One <div></div> can be used repeated in one page or crossed pages. For example, a <DIV> for tree structure can be used in left (which is Jack's west panel) and the same for an image dialog's left panel. What is the efficient way to make an reusable DIV in the same page, or even cross pages, which is similar to .NET's user control?
<div id='main_content'>
<div id="tree_left">tree structre</div>
</div
<div id='dialog'>
<div id="tree_left_dialog">tree structre</div>
</div>
When I load the dialog, I can use:
getEl(tree_left_dialog).update(getEl(tree_left).dom.innerHTML)
However, the tree structure's funcations could be lost.
I have no idea how one tree structure can be used in crossed pages.
What is the best strategy for that? thanks a lot!
Jack and all YUI-Ext fans, Merry Christmas!
<div id='main_content'>
<div id="tree_left">tree structre</div>
</div
<div id='dialog'>
<div id="tree_left_dialog">tree structre</div>
</div>
When I load the dialog, I can use:
getEl(tree_left_dialog).update(getEl(tree_left).dom.innerHTML)
However, the tree structure's funcations could be lost.
I have no idea how one tree structure can be used in crossed pages.
What is the best strategy for that? thanks a lot!
Jack and all YUI-Ext fans, Merry Christmas!