Skip to content

Commit 07c3eb1

Browse files
authored
Blueprint to write an admin notice (#8)
A tiny blueprint to write a file, place it into the mu-plugins folder and say hello. _props for the example to @ironnysh_
1 parent 750101a commit 07c3eb1

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed
+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"$schema": "https://playground.wordpress.net/blueprint-schema.json",
3+
"meta": {
4+
"title": "Display Admin Notice ",
5+
"description": "Blueprint to add a tiny mu-plugin and display an admin notice",
6+
"author": "bph",
7+
"categories": ["Admin", "notices"]
8+
},
9+
"landingPage": "/wp-admin/plugins.php",
10+
"steps":[
11+
{
12+
"step": "login",
13+
"username": "admin",
14+
"password": "password"
15+
},
16+
{
17+
"step": "writeFile",
18+
"path": "/wordpress/wp-content/mu-plugins/bgnightly-notice.php",
19+
"data": "<?php add_action('admin_notices', function() { echo '<div class=\"notice notice-info is-dismissible\"><p>Hello from Playground.</p></div>'; });"
20+
}
21+
]
22+
}

0 commit comments

Comments
 (0)