首页 WordPress函数大全 post_exists()

post_exists()

2020-05-02 / 4148阅 / 悠然

如何你看完本文还不知道如何使用该函数,可以联系我定制视频教程,50元/个函数,学不会全额退款

post_exists( string $title, string $content = '', string $date = '', string $type = '' )

确定帖子是否存在基于>

Contents

  • Description
    • Parameters
    • Return
    • Source
    • Changelog
  • Related
    • Uses
  • User Contributed Notes

描述

参数

$title

(string)
(Required)
Post title.

$content

(string)
(Optional)
post content.

Default value: ''

$date

(string)
(Optional)
post date.

Default value: ''

$type

(string)
(Optional)
post type.

Default value: ''

返回

(int) Post ID if post exists, 0 otherwise.

大家谈论
    我的见解