Maintainer Details in Site Health Info
Adds a "Site maintainer" section to Tools > Site Health > Info with your agency's contact details, support plan and notes, so they travel with every copied debug report.
Opens WPIDE on
Code
// Shown in Site Health > Info.
$wpide_maintainer = array(
'Company' => 'Your Agency Ltd',
'Support email' => '[email protected]',
'Phone' => '+1 555 0100',
'Support plan' => 'Care plan, monthly updates',
'Notes' => 'Please contact us before installing new plugins.',
);
add_filter( 'debug_information', function ( $info ) use ( $wpide_maintainer ) {
$fields = array();
foreach ( $wpide_maintainer as $label => $value ) {
$fields[ sanitize_key( $label ) ] = array(
'label' => $label,
'value' => $value,
'private' => false,
);
}
$info['wpide_maintainer'] = array(
'label' => 'Site maintainer',
'description' => 'Who looks after this website.',
'fields' => $fields,
);
return $info;
} );
Notes
Edit the $wpide_maintainer values; nothing is shown on the front end.
How to add this snippet
- Install WPIDE on your WordPress site (it is free) and open Code Snippets.
- Use snippet above adds it from the library in one click. Or copy the code into a new snippet with the same code type.
- It is added inactive: review the code and settings, then switch it on.