The activate_header WordPress PHP action fires before the Site Activation page is loaded.
Usage
add_action('activate_header', 'your_custom_function'); function your_custom_function() { // your custom code here }
Parameters
- No parameters
More information
See WordPress Developer Resources: activate_header
Examples
Add a welcome message to the activation page
add_action('activate_header', 'add_welcome_message'); function add_welcome_message() { echo '<p><strong>Welcome to our website!</strong></p>'; }
Insert a custom stylesheet
add_action('activate_header', 'insert_custom_stylesheet'); function insert_custom_stylesheet() { echo '<link rel="stylesheet" href="path/to/your/stylesheet.css">'; }
Add a custom JavaScript file
add_action('activate_header', 'insert_custom_js'); function insert_custom_js() { echo '<script src="path/to/your/script.js"></script>'; }
Display a custom logo on the activation page
add_action('activate_header', 'display_custom_logo'); function display_custom_logo() { echo '<img src="path/to/your/logo.png" alt="Your Custom Logo">'; }
Add a custom meta tag for SEO purposes
add_action('activate_header', 'add_custom_meta_tag'); function add_custom_meta_tag() { echo '<meta name="description" content="A custom description for the activation page">'; }