Load a login.css File From Your Theme
Loads login.css from the active (child) theme folder on the login page, so you can style it with a regular stylesheet.
Opens WPIDE on
Code
add_action( 'login_enqueue_scripts', function () {
$path = get_stylesheet_directory() . '/login.css';
if ( file_exists( $path ) ) {
wp_enqueue_style( 'wpide-theme-login', get_stylesheet_directory_uri() . '/login.css', array( 'login' ), (string) filemtime( $path ) );
}
} );
Notes
The file version updates automatically when you edit it, so browsers do not keep an old copy.
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.