| 类别: |
Javascript, function
|
| 标签: |
js, fInsertNode, node, fPutNodeInNewNode, put
|
| 摘要: |
..
|
| 正文: |
- function fPutNodeInOther(OldNode, NewNode)
- {// shawl.qiu script
- fInsertNode(OldNode, NewNode, true);
- OldNode.parentNode.removeChild(OldNode);
- NewNode.appendChild(OldNode);
-
- function fInsertNode(OldNode, NewNode, bBefore)
- {// shawl.qiu script
- var ParentNode = OldNode.parentNode;
- if(!ParentNode)return false;
- if(bBefore)
- {
- ParentNode.insertBefore(NewNode,OldNode);
- return false;
- } // end if
- ParentNode.replaceChild(NewNode, OldNode);
- ParentNode.insertBefore(OldNode, NewNode);
- } // end function fInsertNode
-
- } // end function fPutNodeInOther
|
| 文章相关信息: |
|
| 主题: |
js 把旧节点放进新节点函数 fPutNodeInNewNode
|
| 发表者: |
shawl.qiu
|
| 电子邮件: |
shawl.qiu@gmail.com
|
| QQ: |
908202921
|
| MSN: |
btbtd@msn.com
|
| Homepage: |
http://www.btbtd.org/
|
| Blog: |
http://blog.csdn.net/btbtd/
|
| 发表日期: |
2007-5-19 16:12:15
|
| 更新日期: |
2007-5-19 16:12:15
|
| 来源引用: |
shawl.qiu CSharp DotNet 个人资料管理系统
|
| 引用本页: |
http://gi.2288.org/mod/code/display/Default.aspx?aid=427
|