我工作的一个ASP .NET项目。在我的aspx页面我有一个gridview里面有3列(元素,目标,父)。在客户端,我想用在GridView的数据来建立一个树状结构,然后建立与数字一棵树。我找到的信息以及如何构建的数字,但我想就如何使结构一些建议模块。是否有任何现成的JavaScript的算法来做到这一点? THX提前
I am working on an asp .net project. In my aspx page i have a gridview which has 3 columns("element","Target","Parent"). On the client side i want to build a tree structure using the data in the gridview and then build a tree with figures. I found information and modules about how to build the figure but i want some advice on how to make the structure. Are there any ready javascript algorithms to do this?. Thx in advance
使用一个CSS树,如下面的:
Use a CSS tree, such as the following:
CSS树 CSS3家谱 CSS Tree CSS3 Family Tree使用了:检查
伪类样式复选框为presentational元素效仿的状态,如:
Use the :checked
pseudo class to style checkboxes as presentational elements to emulate state, such as:
.folder input[type='checkbox']:checked { display: block; }
.folder input[type='checkbox'] { display: inline; }
和点播隐藏/显示,和嵌套的<块引用>
元素层次
and hide/show on demand, and nested <blockquote>
elements as hierarchy.
引用
CSS3选择:查伪类 CSS选择器:用户界面元素状态伪类 CSS3 Selectors: :checked pseudo-class CSS Selectors: The UI element states pseudo-classes