Wordpressのget_template_part()
の使い方について質問です。
下記のディレクトリ階層において、
【output.php】で、【target.php】を呼びたい。
と思っているのですが、
出力先ディレクトリ | 呼出元ディレクトリ |
---|---|
wp-content | wp-content |
plugins | themes |
buddypress | twentyseventeen-child |
custom_user | template-parts |
【output.php】 | 【target.php】 |
この場合、【output.php】で★
の部分にはどう書けばよろしいでしょうか?
get_template_part( '★' )
ひとまずwp-contentまで溯って、さらにそこから掘っていく(?)のような書き方になると思うのですが、いろいろ試してもできませんでした。
ご存知の方がいらっしゃいましたら教えて下さいませ。
回答2件
あなたの回答
tips
プレビュー