Skip to:
Content

bbPress.org


Ignore:
Timestamp:
05/22/2012 09:58:26 AM (13 years ago)
Author:
johnjamesjacoby
Message:

Redirects:

  • Always use wp_safe_redirect() in bbPress.
  • Nothing should/will redirect off-site.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/plugin/bbp-includes/bbp-topic-functions.php

    r3911 r3919  
    10181018 *                    topic ids and source topic's forum id
    10191019 * @uses bbp_get_topic_permalink() To get the topic permalink
    1020  * @uses wp_redirect() To redirect to the topic link
     1020 * @uses wp_safe_redirect() To redirect to the topic link
    10211021 */
    10221022function bbp_merge_topic_handler() {
     
    12091209
    12101210        // Redirect back to new topic
    1211         wp_redirect( bbp_get_topic_permalink( $destination_topic->ID ) );
     1211        wp_safe_redirect( bbp_get_topic_permalink( $destination_topic->ID ) );
    12121212
    12131213        // For good measure
     
    12961296 *                    source topic ids and source topic's forum id
    12971297 * @uses bbp_get_topic_permalink() To get the topic permalink
    1298  * @uses wp_redirect() To redirect to the topic link
     1298 * @uses wp_safe_redirect() To redirect to the topic link
    12991299 */
    13001300function bbp_split_topic_handler() {
     
    15321532
    15331533        // Redirect back to the topic
    1534         wp_redirect( bbp_get_topic_permalink( $destination_topic->ID ) );
     1534        wp_safe_redirect( bbp_get_topic_permalink( $destination_topic->ID ) );
    15351535
    15361536        // For good measure
     
    15981598 * @uses do_action() Calls actions based on the actions with associated args
    15991599 * @uses is_wp_error() To check if the value retrieved is a {@link WP_Error}
    1600  * @uses wp_redirect() To redirect to the url
     1600 * @uses wp_safe_redirect() To redirect to the url
    16011601 */
    16021602function bbp_edit_topic_tag_handler() {
     
    18311831 * @uses bbp_get_topic_permalink() To get the topic link
    18321832 * @uses add_query_arg() To add args to the url
    1833  * @uses wp_redirect() To redirect to the topic
     1833 * @uses wp_safe_redirect() To redirect to the topic
    18341834 * @uses bbPress::errors:add() To log the error messages
    18351835 */
     
    19661966        }
    19671967
    1968         wp_redirect( $redirect );
     1968        wp_safe_redirect( $redirect );
    19691969
    19701970        // For good measure
Note: See TracChangeset for help on using the changeset viewer.