What I have:
A basic plugin that's calling a stylesheet contained in the plugin folder:
function my_login_enqueues() {
// First attempt:
//wp_enqueue_style( 'custom-login', 'style-login.css' );
// Second attempt:
$plugin_stylesheet = plugins_url( 'style-login.css', __FILE__ );
wp_enqueue_style( 'custom-login', $plugin_stylesheet );
}
add_action( 'login_enqueue_scripts', 'my_login_enqueues' );
My problem:
I'm receiving the following heading error at wp-login.php:
Warning: Cannot modify header information - headers already sent by (output started at [...]) in [...]/wp-content/plugins/members-only/members-only.php on line 398
Note: The Members Only deals with wp-login.php.
My question:
How can I apply a style-sheet to wp-login.php using a plugin?
Note: I'm knowingly not using functions.php on a per theme basis.