JavaScript DHTML/Javascript Objects/TextNode — различия между версиями

Материал из Web эксперт
Перейти к: навигация, поиск
м (1 версия)
 
(нет различий)

Версия 13:00, 26 мая 2010

"TextNode" Example

   <source lang="html4strict">
   

<html> <head> <script> function replaceText(){

   var myTextNode = document.createTextNode("Text was replaced");
   var newTN = replaceMe.firstChild.replaceNode(myTextNode); 

} </script> </head>

This is some text that will be replaced

<button onclick="replaceText();">Replace text</button> </body> </html>


     </source>