duckdev/wp-review-notice 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

duckdev/wp-review-notice

最新稳定版本:v1.0.3

Composer 安装命令:

composer require duckdev/wp-review-notice

包简介

Simple library class to gently ask for a wp.org plugin review after a few days of plugin usage.

README 文档

README

WP Review Notice

Simple library class to gently ask for a wp.org plugin review after a few days of plugin usage.

Installation

WP Review Notice can be installed using composer:

$ composer require duckdev/wp-review-notice

Usage 📖

Initialize

Initialize one notice per plugin.

// Setup notice.
$notice = \DuckDev\Reviews\Notice::get(
	'my-plugin', // Plugin slug on wp.org (eg: hello-dolly).
	'My Plugin', // Plugin name (eg: Hello Dolly).
	array(
		'days'          => 7, // default: 7 days.
		'message'       => 'My custom message asking for review', // If you want to use different review notice message.
		'action_labels' => array(
			'review'  => 'Please review me', // Change review link label.
			'later'   => 'I will review later', // Change review extension link.
			'dismiss' => 'Nope', // No review label :(.
		),
	)
);

// Render notice.
$notice->render();

Options

You can customize the notice behaviour using options. All these options are optional.

Option Type Description
days int No. of days after the review is shown.
screens array WordPress admin page screen IDs to show notice. If you leave this empty the notice will be added to add admin pages. Strongly recommended to use this option to limit the review notices only within your plugin's admin pages, especially if you are showing notice using admin_notices action.
cap string WordPres user capability to show notice to. Notice will be visible only to user with this capability. Also only users with this capability can dismiss/extend notice.
classes array Additional class names for notice.
domain string Text domain string for internationalization.
message string Notice main message (to override default message).
action_labels array To use different labels for action links. Available items are: review, later, dismiss. Remember to escape.
prefix string To override plugin option and other key prefixes. By default it's plugin slug with dashes replaces with underscores.

Credits

Author - Joel James

统计信息

  • 总下载量: 19
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 3
  • 点击次数: 3
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 3
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2021-07-27

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固