当前位置:Gxlcms > PHP教程 > wordpress侧边栏如何调用的文章列表,看了很久一直不能理解

wordpress侧边栏如何调用的文章列表,看了很久一直不能理解

时间:2021-07-01 10:21:17 帮助过:7人阅读

wordpress侧边栏怎么调用的文章列表,看了很久一直不能理解
WordPress 3.7.1简体中文版,wordpress侧边栏怎么调用的文章列表

我下的一个主题中的sidebar.php




















dynamic_sidebar( 'sidebartop' ) 这个函数调用的最新文章列表?

sidebartop注册是在functions.php中,然后后台才有显示,如下:

register_sidebar(array(
'name' => 'SidebarTop',
'description' => 'Top sidebar',
'id' => 'sidebartop',
'before_widget' => "\n\t\t\t" . '
  • ',
    'after_widget' => "\n\t\t\t
  • \n",
    'before_title' => "\n\t\t\t\t". '

    ',
    'after_title' => "

    \n" .''
    ));


    分享到:

    人气教程排行