| | 200 | * Returns the Lost Password URL. |
| | 201 | * |
| | 202 | * Returns the URL that allows the user to retriev the lost password |
| | 203 | * |
| | 204 | * @since 2.8 |
| | 205 | * @uses site_url() To generate the lost password URL |
| | 206 | * @uses apply_filters() calls 'lostpassword_url' hook on final login url |
| | 207 | * |
| | 208 | * @param string $redirect Path to redirect to on login. |
| | 209 | */ |
| | 210 | function wp_lostpassword_url($redirect = '') { |
| | 211 | $lostpassword_url = site_url('wp-login.php?action=lostpassword', 'login') |
| | 212 | |
| | 213 | if ( !empty($redirect) ) { |
| | 214 | $lostpassword_url = add_query_arg('redirect_to', urlencode($redirect), $lostpassword_url); |
| | 215 | } |
| | 216 | |
| | 217 | return apply_filters('lostpassword', $lostpassword_url, $redirect); |
| | 218 | } |
| | 219 | |
| | 220 | /** |