Make WordPress Core

Ticket #32508: testloginhooks.php

File testloginhooks.php, 622 bytes (added by jwarren, 10 years ago)

Very quick and dirty plugin to test previously mentioned patch

Line 
1<?php
2/**
3 * @package Test_Login_Hooks
4 * @version 1.6
5 */
6/*
7Plugin Name: Test Login Hooks
8Description: Test login hooks
9Author: Jodi Warren
10Version: 0.1
11Author URI: http://www.jodiwarren.com/
12*/
13
14function loginFailed( $username ) {
15        die('<h1>Login failed, ' . $username . '</h1>');
16}
17add_action('wp_login_failed', 'loginFailed');
18
19function emptyUsername() {
20        die('<h1>Empty Username</h1>');
21}
22add_action('wp_login_failed_empty_username', 'emptyUsername');
23
24function emptyPassword( $username ) {
25        die('<h1>Where\'s your password ' . $username . '?</h1>');
26}
27add_action('wp_login_failed_empty_password', 'emptyPassword');