1. 首页
  2. 数据库
  3. 其它
  4. wordpress获取文章类型函数:get_post_type()

wordpress获取文章类型函数:get_post_type()

上传者: 2021-02-01 13:53:31上传 PDF文件 25.83KB 热度 19次
【说明】 检索当前文章或给定文章的文章类型。【用法】 【参数】 $post (混合)(可选)文章对象或文章ID。 默认值: false【返回的值】 (布尔型| 字符) 返回文章类型,出错时返回false。【示例】 【注释】 用法:$posts 日志循环的全局变量【修改记录】 自2.1.0版本后【源文件】 get_post_type() 位于wp-includes/post.php中 /** * Retrieve the post type of the current post or of a given post. * * @since 2.1.0 * * @uses $
下载地址
用户评论