Docs: Clarify that get_page_template() doesn't work on block themes.
When working on a block theme, `locate_block_template()` should be used instead of `get_page_template()`. This changeset updates the docblock of this function accordingly. Props audrasjb, costdev, robinwpdeveloper. Fixes #56394. See #55646. Built from https://develop.svn.wordpress.org/trunk@54179 git-svn-id: http://core.svn.wordpress.org/trunk@53738 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -437,6 +437,8 @@ function get_privacy_policy_template() {
|
||||
/**
|
||||
* Retrieve path of page template in current or parent template.
|
||||
*
|
||||
* Note: For block themes, use locate_block_template function instead.
|
||||
*
|
||||
* The hierarchy for this template looks like:
|
||||
*
|
||||
* 1. {Page Template}.php
|
||||
|
||||
Reference in New Issue
Block a user