bbp_current_user_can_access_anonymous_user_form()
Performs a series of checks to ensure the current user should see the anonymous user form fields.
Description Description
Return Return
(bool)
Source Source
File: includes/users/template.php
function bbp_current_user_can_access_anonymous_user_form() { // Users need to earn access $retval = false; // User is not logged in, and anonymous posting is allowed if ( bbp_is_anonymous() ) { $retval = true; // User is editing a topic, and topic is authored by anonymous user } elseif ( bbp_is_topic_edit() && bbp_is_topic_anonymous() ) { $retval = true; // User is editing a reply, and reply is authored by anonymous user } elseif ( bbp_is_reply_edit() && bbp_is_reply_anonymous() ) { $retval = true; } // Filter & return return (bool) apply_filters( 'bbp_current_user_can_access_anonymous_user_form', (bool) $retval ); }
Changelog Changelog
Version | Description |
---|---|
2.5.0 | Introduced. |