Indexing Notice
Product: Admin Framework Pro
The Indexing Notice module helps you avoid costly SEO mistakes by showing a visible admin bar alert if your WordPress site is set to discourage search engines from indexing. This quick reminder ensures you never accidentally leave indexing disabled on a live site.
How to use
To enable the Indexing Notice Module:
- Click on the “Utilities” category
- Search or scroll to locate the Indexing Notice Module
- Click on the switch to enable
What’s next?
The module will automatically monitor your site’s indexing settings. No further configuration is needed.
1. Understanding the Notice
When enabled, this module will display a red notice in the admin bar if:
- The site is set to discourage search engines from indexing
- The current user has administrator privileges
- The admin bar is visible
2. How It Works
- Automatic Detection: The module checks your WordPress settings to see if “Discourage search engines from indexing this site” is enabled
- Admin Bar Notice: If indexing is discouraged, a red notice appears in the admin bar
- Quick Access: Click the notice to go directly to the Reading Settings page
3. Why It’s Important
Search engine indexing is crucial for:
- SEO: Ensures your site can be found in search results
- Visibility: Helps potential visitors discover your content
- Traffic: Affects your site’s organic search traffic
4. How to Fix
If you see the notice and want to allow search engine indexing:
- Click the notice in the admin bar (or go to Settings > Reading)
- Under “Search Engine Visibility”
- Uncheck “Discourage search engines from indexing this site”
- Click “Save Changes”
5. When to Keep Indexing Disabled
You might want to keep indexing disabled when:
- Your site is in development
- It’s a staging or testing environment
- It’s a private or internal site
6. Developer Notes
The module uses these WordPress hooks:
admin_bar_menuto add the noticeadmin_headandwp_headto enqueue stylesblog_publicoption to check indexing status
7. Customization
You can customize the notice using these filters:
// Change the notice text
add_filter('WPMazic/indexing_notice/text', function($text) {
return 'Warning: This site is not being indexed by search engines!';
});
// Change the notice URL
add_filter('WPMazic/indexing_notice/url', function($url) {
return admin_url('options-general.php?page=my-custom-settings');
});
// Add custom CSS
add_action('wp_head', 'custom_indexing_notice_styles', 100);
add_action('admin_head', 'custom_indexing_notice_styles', 100);
function custom_indexing_notice_styles() {
if (!current_user_can('manage_options')) return;
?>
<style>
#wpadminbar #wp-admin-bar-wpext-indexing-notice > .ab-item {
background-color: #d63638 !important;
color: #fff !important;
}
</style>
<?php
}8. Troubleshooting
If the notice appears when it shouldn’t:
- Check your Reading Settings
- Verify your
wp_optionstable’sblog_publicvalue - Clear any caching plugins
- Check for conflicting plugins modifying search engine visibility
This module is ideal for:
- Developers managing multiple WordPress sites
- Site administrators who want to be aware of indexing status
- Agencies managing client websites
- Anyone who needs to ensure their site is properly indexed