Ticket #3373: 3373.diff
| File 3373.diff, 996 bytes (added by , 6 years ago) |
|---|
-
includes/core/sub-actions.php
function bbp_post_request() { 400 400 } 401 401 402 402 /** 403 403 * The main action used for handling theme-side GET requests 404 404 * 405 405 * @since 2.3.0 bbPress (r4550) 406 406 */ 407 407 function bbp_get_request() { 408 408 409 409 // Bail if not a POST action 410 410 if ( ! bbp_is_get_request() ) { 411 411 return; 412 412 } 413 413 414 414 // Bail if no action 415 if ( empty( $_GET['action'] ) ) {415 if ( empty( $_GET['action'] ) || ! is_string( $_GET['action'] ) ) { 416 416 return; 417 417 } 418 418 419 419 // Sanitize the GET action 420 420 $action = sanitize_key( $_GET['action'] ); 421 421 422 422 // Bail if action was totally invalid 423 423 if ( empty( $action ) ) { 424 424 return; 425 425 } 426 426 427 427 // This dynamic action is probably the one you want to use. It narrows down 428 428 // the scope of the 'action' without needing to check it in your function. 429 429 do_action( 'bbp_get_request_' . $action ); 430 430
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)