piotrpress/wordpress-notice 问题修复 & 功能扩展

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

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

piotrpress/wordpress-notice

最新稳定版本:v1.1.0

Composer 安装命令:

composer require piotrpress/wordpress-notice

包简介

This library simplifies the displaying of Notices in the WordPress dashboard.

README 文档

README

This library simplifies the displaying of Notices in the WordPress dashboard.

Installation

$ composer require piotrpress/wordpress-notice

Example

require __DIR__ . '/vendor/autoload.php';

namespace PiotrPress\WordPress;

// Example #1
echo new Notice( 'This is an example notice message', Notice::ERROR );

// Example #2
Hooks::add( new Notice( 'This is an example notice message', Notice::ERROR ) );

Arguments

  • string $message - The notice message.
  • string $type - The notice type. Possible values are Notice::INFO, Notice::SUCCESS, Notice::WARNING, Notice::ERROR. Default is null.
  • bool $dismissible - Whether the notice is dismissible. Possible values are true, false. Default is false.
  • bool $alt - The alternative notice display style (with filled-in background). Possible values are true, false. Default is false.

Requirements

PHP >= 7.4 version.

License

GPL3.0

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: GPL-3.0
  • 更新时间: 2024-08-27