Easy Tutorial
❮ Jsref Slice Array Jsref Lastindexof Array ❯

HTML DOM renameNode() Method

Document Object

Example

Rename a p element:


Definition and Usage

The renameNode() method renames an existing element node or attribute node.


Browser Support

Currently, no major browsers support the renameNode() method.


Syntax

Parameters

Parameter Type Description
node Node Object Required. The node object to be renamed.
namespaceURI String Required. Set to null if you do not want to specify a namespace URI for the node.
nodename String Required. The new node name.

Return Value

Type Description
Node Object The renamed node

Technical Details

| DOM Version | Core Level 3 Document Object | | --- | --- |


Document Object

❮ Jsref Slice Array Jsref Lastindexof Array ❯