相关疑难解决方法(0)

如何通过Wordpress中的父页面标题获取页面的所有子页面?

示例:

About
--- technical
--- medical
--- historical
--- geographical
--- political
Run Code Online (Sandbox Code Playgroud)

如何创建这样的功能?

function get_child_pages_by_parent_title($title)
{
    // the code goes here
}
Run Code Online (Sandbox Code Playgroud)

并像这样调用它将返回一个充满对象的数组.

$children = get_child_pages_by_parent_title('About');
Run Code Online (Sandbox Code Playgroud)

wordpress

2
推荐指数
3
解决办法
2万
查看次数

标签 统计

wordpress ×1