elcontraption / wp-help-tab
A WordPress custom help tab creator class.
Installs: 234
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/elcontraption/wp-help-tab
Requires
- php: >=5.4.0
This package is not auto-updated.
Last update: 2016-05-28 09:20:44 UTC
README
Easily create contextual help tabs in WordPress.
Installation
Install in your theme via composer:
composer require elcontraption/wp-help-tab
Usage
Create a new Help tab (page and title arguments are required):
use \ElContraption\WpHelpTab\HelpTab;
/**
* Create a new help tab on menu edit screens:
*/
new HelpTab(array(
'page' => 'nav-menus',
'title' => 'Custom Help Tab',
'content' => 'My custom help tab content.'
));
Use the optional callback argument to load a help tab template:
/**
* Create a new help tab on page edit screens:
*/
new HelpTab(array(
'page' => 'post',
'title' => 'Custom Page Editing Instructions',
'callback' => function() {
get_template_part('path/to/help/template');
}
));