PHPackages                             x-wp/admin-notice-manager - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Admin Panels](/categories/admin)
4. /
5. x-wp/admin-notice-manager

ActiveLibrary[Admin Panels](/categories/admin)

x-wp/admin-notice-manager
=========================

Simplifies the process of working with admin notices in WordPress.

v1.0.2(1y ago)0324[1 issues](https://github.com/x-wp/admin-notice-manager/issues)2GPL-2.0-onlyPHPPHP &gt;=8.0

Since Nov 1Pushed 1y ago1 watchersCompare

[ Source](https://github.com/x-wp/admin-notice-manager)[ Packagist](https://packagist.org/packages/x-wp/admin-notice-manager)[ Docs](https://extended.wp.rs/docs/packages/admin-notice-manager)[ RSS](/packages/x-wp-admin-notice-manager/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (9)Versions (4)Used By (2)

Admin Notice Manager 🔔
======================

[](#admin-notice-manager-)

### Simplifies the process of creating, displaying and saving notices in WordPress admin.

[](#simplifies-the-process-of-creating-displaying-and-saving-notices-in-wordpress-admin)

[![Packagist Version](https://camo.githubusercontent.com/848813f532e918691628aa897527ef5f17c79279663500120922ff8a48356abc/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f782d77702f61646d696e2d6e6f746963652d6d616e61676572)](https://packagist.org/packages/x-wp/admin-notice-manager)[![Packagist PHP Version](https://camo.githubusercontent.com/a1bb21f991c5dfda5f2cd2b0ead514ad8f5d286c7ca15db41f2db8f833baebb8/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646570656e64656e63792d762f782d77702f61646d696e2d6e6f746963652d6d616e616765722f7068703f6c6f676f3d706870266c6f676f436f6c6f723d7768697465266c6f676f53697a653d6175746f)](https://camo.githubusercontent.com/a1bb21f991c5dfda5f2cd2b0ead514ad8f5d286c7ca15db41f2db8f833baebb8/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646570656e64656e63792d762f782d77702f61646d696e2d6e6f746963652d6d616e616765722f7068703f6c6f676f3d706870266c6f676f436f6c6f723d7768697465266c6f676f53697a653d6175746f)[![Static Badge](https://camo.githubusercontent.com/7501428f2217b91781cd054472985d52da9927aaa871b933ee28200ff8b8e093/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f57502d253345253344362e342d3338353865393f7374796c653d666c6174266c6f676f3d776f72647072657373266c6f676f53697a653d6175746f)](https://camo.githubusercontent.com/7501428f2217b91781cd054472985d52da9927aaa871b933ee28200ff8b8e093/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f57502d253345253344362e342d3338353865393f7374796c653d666c6174266c6f676f3d776f72647072657373266c6f676f53697a653d6175746f)

Displaying notices in WordPress admin is a common task for plugin and theme developers. This package provides an easy to use API for notice management.

How to use
----------

[](#how-to-use)

### Installation

[](#installation)

You can install the package via composer:

```
composer require x-wp/admin-notice-manager
```

Tip

We recommend using the `automattic/jetpack-autoloader` with this package to prevent autoloading issues.

### Configuration and initialization

[](#configuration-and-initialization)

Package will automatically initialize itself on `admin_init` hook. Manager comes with batteries included - you will use the Notice class to create and display notices.

### Examples

[](#examples)

#### Creating a notice

[](#creating-a-notice)

If you are certain that no invoice has the same id as the one you are creating, you can use the `xwp_create_notice` function to create a notice.

```
