WP_Theme::parent() WordPress Method
The WP_Theme::parent() method is used to get the parent theme of the current theme. If the current theme does not have a parent theme, then this method will return null.
WP_Theme::parent() #
Returns reference to the parent theme.
Return
(WP_Theme|false) Parent theme, or false if the active theme is not a child theme.
Source
File: wp-includes/class-wp-theme.php
public function parent() { return isset( $this->parent ) ? $this->parent : false; }
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
Version | Description |
---|---|
3.4.0 | Introduced. |