bbp_get_wp_login_action( string $args = '' )
Return the login form action url
Description
Parameters
- $args
-
(Optional) Pass a URL to redirect to
Default value: ''
Source
File: bp-forums/common/template.php
function bbp_get_wp_login_action( $args = '' ) { // Parse arguments against default values $r = bbp_parse_args( $args, array( 'action' => '', 'context' => '', 'url' => 'wp-login.php' ), 'login_action' ); // Add action as query arg if ( !empty( $r['action'] ) ) { $login_url = add_query_arg( array( 'action' => $r['action'] ), $r['url'] ); // No query arg } else { $login_url = $r['url']; } $login_url = site_url( $login_url, $r['context'] ); return apply_filters( 'bbp_get_wp_login_action', $login_url, $r, $args ); }
Changelog
Version | Description |
---|---|
bbPress (r5691) | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.