This page is In Progress

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.

parentElement

Summary

Retrieves the parent node of this DOM node, if the parent is an element node; null if the parent is not an element or if there is no parent. Read-only.

Property of dom/Elementdom/Element

Syntax

Note: This property is read-only.

var result = element.parentElement;

Notes

Remarks

The topmost object returns null as its parent.

Syntax

Attributions