Changeset 5417
- Timestamp:
- 11/29/2011 11:06:58 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-groups/bp-groups-activity.php
r5302 r5417 130 130 $text = sprintf( __( '%d accepted group membership requests', 'buddypress' ), (int)$total_items, $group->name ); 131 131 $filter = 'bp_groups_multiple_membership_request_accepted_notification'; 132 $notification_link = bp_loggedin_user_domain() . bp_get_groups_slug() . '/?n=1';132 $notification_link = trailingslashit( bp_loggedin_user_domain() . bp_get_groups_slug() ) . '?n=1'; 133 133 134 134 if ( 'string' == $format ) { … … 166 166 $text = sprintf( __( '%d rejected group membership requests', 'buddypress' ), (int)$total_items, $group->name ); 167 167 $filter = 'bp_groups_multiple_membership_request_rejected_notification'; 168 $notification_link = bp_loggedin_user_domain() . bp_get_groups_slug() . '/?n=1';168 $notification_link = trailingslashit( bp_loggedin_user_domain() . bp_get_groups_slug() ) . '?n=1'; 169 169 170 170 if ( 'string' == $format ) { … … 202 202 $text = sprintf( __( 'You were promoted to an admin in %d groups', 'buddypress' ), (int)$total_items ); 203 203 $filter = 'bp_groups_multiple_member_promoted_to_admin_notification'; 204 $notification_link = bp_loggedin_user_domain() . bp_get_groups_slug() . '?n=1';204 $notification_link = trailingslashit( bp_loggedin_user_domain() . bp_get_groups_slug() ) . '?n=1'; 205 205 206 206 if ( 'string' == $format ) { … … 238 238 $text = sprintf( __( 'You were promoted to a mod in %d groups', 'buddypress' ), (int)$total_items ); 239 239 $filter = 'bp_groups_multiple_member_promoted_to_mod_notification'; 240 $notification_link = bp_loggedin_user_domain() . bp_get_groups_slug() . '?n=1';240 $notification_link = trailingslashit( bp_loggedin_user_domain() . bp_get_groups_slug() ) . '?n=1'; 241 241 242 242 if ( 'string' == $format ) { -
trunk/bp-groups/bp-groups-classes.php
r5384 r5417 1280 1280 // Construct the admin edit tab for the new group extension 1281 1281 if ( !empty( $this->enable_edit_item ) && !empty( $bp->is_item_admin ) ) { 1282 add_action( 'groups_admin_tabs', create_function( '$current, $group_slug', '$selected = ""; if ( "' . esc_attr( $this->admin_slug ) . '" == $current ) $selected = " class=\"current\""; echo "<li{$selected}><a href=\"' . bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/{$group_slug}/admin/' . esc_attr( $this->admin_slug) . '\">' . esc_attr( $this->admin_name ) . '</a></li>";' ), 10, 2 );1282 add_action( 'groups_admin_tabs', create_function( '$current, $group_slug', '$selected = ""; if ( "' . esc_attr( $this->admin_slug ) . '" == $current ) $selected = " class=\"current\""; echo "<li{$selected}><a href=\"' . trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/{$group_slug}/admin/' . esc_attr( $this->admin_slug ) ) . '\">' . esc_attr( $this->admin_name ) . '</a></li>";' ), 10, 2 ); 1283 1283 1284 1284 // Catch the edit screen and forward it to the plugin template -
trunk/bp-groups/bp-groups-notifications.php
r5296 r5417 19 19 $to = $ud->user_email; 20 20 21 $group_link = site_url( bp_get_groups_root_slug(). '/' . $group->slug);21 $group_link = bp_get_group_permalink( $group ); 22 22 $settings_slug = function_exists( 'bp_get_settings_slug' ) ? bp_get_settings_slug() : 'settings'; 23 23 $settings_link = bp_core_get_user_domain( $user_id ) . $settings_slug . '/notifications/'; … … 223 223 $settings_link = bp_core_get_user_domain( $invited_user_id ) . bp_get_settings_slug() . '/notifications/'; 224 224 $invited_link = bp_core_get_user_domain( $invited_user_id ); 225 $invites_link = $invited_link . bp_get_groups_slug() . '/invites';225 $invites_link = trailingslashit( $invited_link . bp_get_groups_slug() . '/invites' ); 226 226 227 227 // Set up and send the message -
trunk/bp-groups/bp-groups-screens.php
r5329 r5417 61 61 } 62 62 63 bp_core_redirect( bp_loggedin_user_domain() . bp_get_groups_slug() . '/' . bp_current_action() );63 bp_core_redirect( trailingslashit( bp_loggedin_user_domain() . bp_get_groups_slug() . '/' . bp_current_action() ) ); 64 64 65 65 } else if ( bp_is_action_variable( 'reject' ) && is_numeric( $group_id ) ) { … … 73 73 bp_core_add_message( __('Group invite rejected', 'buddypress') ); 74 74 75 bp_core_redirect( bp_loggedin_user_domain() . bp_get_groups_slug() . '/' . bp_current_action() );75 bp_core_redirect( trailingslashit( bp_loggedin_user_domain() . bp_get_groups_slug() . '/' . bp_current_action() ) ); 76 76 } 77 77 … … 791 791 do_action( 'groups_group_deleted', $bp->groups->current_group->id ); 792 792 793 bp_core_redirect( bp_loggedin_user_domain() . bp_get_groups_slug() . '/');794 } 795 796 bp_core_redirect( bp_loggedin_user_domain() . bp_get_groups_slug() );793 bp_core_redirect( trailingslashit( bp_loggedin_user_domain() . bp_get_groups_slug() ) ); 794 } 795 796 bp_core_redirect( trailingslashit( bp_loggedin_user_domain() . bp_get_groups_slug() ) ); 797 797 } 798 798 -
trunk/bp-groups/bp-groups-template.php
r5379 r5417 456 456 $group =& $groups_template->group; 457 457 458 return apply_filters( 'bp_get_group_admin_permalink', bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug . '/admin');458 return apply_filters( 'bp_get_group_admin_permalink', trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug . '/admin' ) ); 459 459 } 460 460 … … 1268 1268 ?> 1269 1269 <?php if ( $bp->is_item_admin || $bp->is_item_mod ) { ?> 1270 <li<?php if ( 'edit-details' == $current_tab || empty( $current_tab ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug ?>/admin/edit-details"><?php _e( 'Details', 'buddypress' ); ?></a></li>1270 <li<?php if ( 'edit-details' == $current_tab || empty( $current_tab ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug . '/admin/edit-details' ) ?>"><?php _e( 'Details', 'buddypress' ); ?></a></li> 1271 1271 <?php } ?> 1272 1272 … … 1275 1275 return false; 1276 1276 ?> 1277 <li<?php if ( 'group-settings' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug ?>/admin/group-settings"><?php _e( 'Settings', 'buddypress' ); ?></a></li>1277 <li<?php if ( 'group-settings' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug . '/admin/group-settings' ) ?>"><?php _e( 'Settings', 'buddypress' ); ?></a></li> 1278 1278 1279 1279 <?php if ( !(int)bp_get_option( 'bp-disable-avatar-uploads' ) ) : ?> 1280 <li<?php if ( 'group-avatar' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug ?>/admin/group-avatar"><?php _e( 'Avatar', 'buddypress' ); ?></a></li>1280 <li<?php if ( 'group-avatar' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug . '/admin/group-avatar' ) ?>"><?php _e( 'Avatar', 'buddypress' ); ?></a></li> 1281 1281 <?php endif; ?> 1282 1282 1283 <li<?php if ( 'manage-members' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug ?>/admin/manage-members"><?php _e( 'Members', 'buddypress' ); ?></a></li>1283 <li<?php if ( 'manage-members' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug . '/admin/manage-members' ) ?>"><?php _e( 'Members', 'buddypress' ); ?></a></li> 1284 1284 1285 1285 <?php if ( $groups_template->group->status == 'private' ) : ?> 1286 <li<?php if ( 'membership-requests' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug ?>/admin/membership-requests"><?php _e( 'Requests', 'buddypress' ); ?></a></li>1286 <li<?php if ( 'membership-requests' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug . '/admin/membership-requests' ) ?>"><?php _e( 'Requests', 'buddypress' ); ?></a></li> 1287 1287 <?php endif; ?> 1288 1288 1289 1289 <?php do_action( 'groups_admin_tabs', $current_tab, $group->slug ) ?> 1290 1290 1291 <li<?php if ( 'delete-group' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug ?>/admin/delete-group"><?php _e( 'Delete', 'buddypress' ); ?></a></li>1291 <li<?php if ( 'delete-group' == $current_tab ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/' . $group->slug . '/admin/delete-group' ) ?>"><?php _e( 'Delete', 'buddypress' ); ?></a></li> 1292 1292 <?php 1293 1293 } … … 1407 1407 $group =& $groups_template->group; 1408 1408 1409 return apply_filters( 'bp_get_group_accept_invite_link', wp_nonce_url( $bp->loggedin_user->domain . bp_get_groups_slug() . '/invites/accept/' . $group->id, 'groups_accept_invite' ) );1409 return apply_filters( 'bp_get_group_accept_invite_link', wp_nonce_url( trailingslashit( $bp->loggedin_user->domain . bp_get_groups_slug() . '/invites/accept/' . $group->id ), 'groups_accept_invite' ) ); 1410 1410 } 1411 1411 … … 1419 1419 $group =& $groups_template->group; 1420 1420 1421 return apply_filters( 'bp_get_group_reject_invite_link', wp_nonce_url( $bp->loggedin_user->domain . bp_get_groups_slug() . '/invites/reject/' . $group->id, 'groups_reject_invite' ) );1421 return apply_filters( 'bp_get_group_reject_invite_link', wp_nonce_url( trailingslashit( $bp->loggedin_user->domain . bp_get_groups_slug() . '/invites/reject/' . $group->id ), 'groups_reject_invite' ) ); 1422 1422 } 1423 1423 … … 2019 2019 $bp->action_variables[1] = array_shift( array_keys( $bp->groups->group_creation_steps ) ); 2020 2020 2021 return apply_filters( 'bp_get_group_creation_form_action', bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/create/step/' . bp_action_variable( 1) );2021 return apply_filters( 'bp_get_group_creation_form_action', trailingslashit( bp_get_root_domain() . '/' . bp_get_groups_root_slug() . '/create/step/' . bp_action_variable( 1 ) ) ); 2022 2022 } 2023 2023 … … 2271 2271 global $create_group_step, $completed_to_step; 2272 2272 ?> 2273 <li<?php if ( !bp_action_variable( 0 ) || bp_is_action_variable( 'recently-active', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . bp_get_groups_slug() ?>/my-groups/recently-active"><?php _e( 'Recently Active', 'buddypress' ) ?></a></li>2274 <li<?php if ( bp_is_action_variable( 'recently-joined', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . bp_get_groups_slug() ?>/my-groups/recently-joined"><?php _e( 'Recently Joined', 'buddypress' ) ?></a></li>2275 <li<?php if ( bp_is_action_variable( 'most-popular', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . bp_get_groups_slug() ?>/my-groups/most-popular"><?php _e( 'Most Popular', 'buddypress' ) ?></a></li>2276 <li<?php if ( bp_is_action_variable( 'admin-of', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . bp_get_groups_slug() ?>/my-groups/admin-of"><?php _e( 'Administrator Of', 'buddypress' ) ?></a></li>2277 <li<?php if ( bp_is_action_variable( 'mod-of', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . bp_get_groups_slug() ?>/my-groups/mod-of"><?php _e( 'Moderator Of', 'buddypress' ) ?></a></li>2278 <li<?php if ( bp_is_action_variable( 'alphabetically' ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo $bp->displayed_user->domain . bp_get_groups_slug() ?>/my-groups/alphabetically"><?php _e( 'Alphabetically', 'buddypress' ) ?></a></li>2273 <li<?php if ( !bp_action_variable( 0 ) || bp_is_action_variable( 'recently-active', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( $bp->displayed_user->domain . bp_get_groups_slug() . '/my-groups/recently-active' ) ?>"><?php _e( 'Recently Active', 'buddypress' ) ?></a></li> 2274 <li<?php if ( bp_is_action_variable( 'recently-joined', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( $bp->displayed_user->domain . bp_get_groups_slug() . '/my-groups/recently-joined' ) ?>"><?php _e( 'Recently Joined', 'buddypress' ) ?></a></li> 2275 <li<?php if ( bp_is_action_variable( 'most-popular', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( $bp->displayed_user->domain . bp_get_groups_slug() . '/my-groups/most-popular' ) ?>"><?php _e( 'Most Popular', 'buddypress' ) ?></a></li> 2276 <li<?php if ( bp_is_action_variable( 'admin-of', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( $bp->displayed_user->domain . bp_get_groups_slug() . '/my-groups/admin-of' ) ?>"><?php _e( 'Administrator Of', 'buddypress' ) ?></a></li> 2277 <li<?php if ( bp_is_action_variable( 'mod-of', 0 ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( $bp->displayed_user->domain . bp_get_groups_slug() . '/my-groups/mod-of' ) ?>"><?php _e( 'Moderator Of', 'buddypress' ) ?></a></li> 2278 <li<?php if ( bp_is_action_variable( 'alphabetically' ) ) : ?> class="current"<?php endif; ?>><a href="<?php echo trailingslashit( $bp->displayed_user->domain . bp_get_groups_slug() . '/my-groups/alphabetically' ) ?>"><?php _e( 'Alphabetically', 'buddypress' ) ?></a></li> 2279 2279 <?php 2280 2280 do_action( 'groups_header_tabs' ); -
trunk/bp-members/bp-members-signup.php
r5345 r5417 24 24 if ( is_user_logged_in() ) { 25 25 if ( bp_is_component_front_page( 'register' ) ) 26 $redirect_to = bp_get_root_domain() . '/' . bp_get_members_root_slug();26 $redirect_to = trailingslashit( bp_get_root_domain() . '/' . bp_get_members_root_slug() ); 27 27 else 28 28 $redirect_to = bp_get_root_domain(); -
trunk/bp-members/bp-members-template.php
r5379 r5417 759 759 $link = str_replace( $bp->loggedin_user->domain, $bp->displayed_user->domain, $user_nav_item['link'] ); 760 760 else 761 $link = $bp->displayed_user->domain . $user_nav_item['link'];761 $link = trailingslashit( $bp->displayed_user->domain . $user_nav_item['link'] ); 762 762 763 763 echo apply_filters_ref_array( 'bp_get_displayed_user_nav_' . $user_nav_item['css_id'], array( '<li id="' . $user_nav_item['css_id'] . '-personal-li" ' . $selected . '><a id="user-' . $user_nav_item['css_id'] . '" href="' . $link . '">' . $user_nav_item['name'] . '</a></li>', &$user_nav_item ) ); -
trunk/bp-messages/bp-messages-actions.php
r5329 r5417 18 18 19 19 if ( !$thread_id || !messages_is_valid_thread( $thread_id ) || ( !messages_check_thread_access( $thread_id ) && !bp_current_user_can( 'bp_moderate' ) ) ) 20 bp_core_redirect( bp_displayed_user_domain() . bp_get_messages_slug() );20 bp_core_redirect( trailingslashit( bp_displayed_user_domain() . bp_get_messages_slug() ) ); 21 21 22 22 // Check if a new reply has been submitted … … 53 53 'position' => 40, 54 54 'user_has_access' => bp_is_my_profile(), 55 'link' => bp_displayed_user_domain() . bp_get_messages_slug() . '/view/' . (int) $thread_id55 'link' => trailingslashit( bp_displayed_user_domain() . bp_get_messages_slug() . '/view/' . (int) $thread_id ) 56 56 ) ); 57 57 … … 69 69 70 70 if ( !$thread_id || !is_numeric( $thread_id ) || !messages_check_thread_access( $thread_id ) ) { 71 bp_core_redirect( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() );71 bp_core_redirect( trailingslashit( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() ) ); 72 72 } else { 73 73 if ( !check_admin_referer( 'messages_delete_thread' ) ) … … 80 80 bp_core_add_message( __('Message deleted.', 'buddypress') ); 81 81 } 82 bp_core_redirect( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() );82 bp_core_redirect( trailingslashit( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() ) ); 83 83 } 84 84 } … … 94 94 95 95 if ( !$thread_ids || !messages_check_thread_access( $thread_ids ) ) { 96 bp_core_redirect( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() );96 bp_core_redirect( trailingslashit( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() ) ); 97 97 } else { 98 98 if ( !check_admin_referer( 'messages_delete_thread' ) ) … … 104 104 bp_core_add_message( __('Messages deleted.', 'buddypress') ); 105 105 106 bp_core_redirect( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() );106 bp_core_redirect( trailingslashit( bp_displayed_user_domain() . bp_get_messages_slug() . '/' . bp_current_action() ) ); 107 107 } 108 108 } -
trunk/bp-messages/bp-messages-functions.php
r5329 r5417 234 234 235 235 if ( 'new_message' == $action ) { 236 $link = bp_loggedin_user_domain() . bp_get_messages_slug() . '/inbox';236 $link = trailingslashit( bp_loggedin_user_domain() . bp_get_messages_slug() . '/inbox' ); 237 237 $title = __( 'Inbox', 'buddypress' ); 238 238 -
trunk/bp-messages/bp-messages-screens.php
r5329 r5417 115 115 } 116 116 } 117 bp_core_redirect( bp_loggedin_user_domain() . bp_get_messages_slug() . '/notices');117 bp_core_redirect( trailingslashit( bp_loggedin_user_domain() . bp_get_messages_slug() . '/notices' ) ); 118 118 } 119 119 -
trunk/bp-messages/bp-messages-template.php
r5329 r5417 255 255 function bp_get_message_thread_delete_link() { 256 256 global $messages_template, $bp; 257 return apply_filters( 'bp_get_message_thread_delete_link', wp_nonce_url( $bp->loggedin_user->domain . $bp->messages->slug . '/' . $bp->current_action . '/delete/' . $messages_template->thread->thread_id, 'messages_delete_thread' ) );257 return apply_filters( 'bp_get_message_thread_delete_link', wp_nonce_url( trailingslashit( $bp->loggedin_user->domain . $bp->messages->slug . '/' . $bp->current_action . '/delete/' . $messages_template->thread->thread_id ), 'messages_delete_thread' ) ); 258 258 } 259 259 … … 480 480 481 481 if ( 1 == (int)$messages_template->thread->is_active ) { 482 $link = wp_nonce_url( $bp->loggedin_user->domain . $bp->messages->slug . '/notices/deactivate/' . $messages_template->thread->id, 'messages_deactivate_notice' );482 $link = wp_nonce_url( trailingslashit( $bp->loggedin_user->domain . $bp->messages->slug . '/notices/deactivate/' . $messages_template->thread->id ), 'messages_deactivate_notice' ); 483 483 } else { 484 $link = wp_nonce_url( $bp->loggedin_user->domain . $bp->messages->slug . '/notices/activate/' . $messages_template->thread->id, 'messages_activate_notice' );484 $link = wp_nonce_url( trailingslashit( $bp->loggedin_user->domain . $bp->messages->slug . '/notices/activate/' . $messages_template->thread->id ), 'messages_activate_notice' ); 485 485 } 486 486 return apply_filters( 'bp_get_message_activate_deactivate_link', $link );
Note: See TracChangeset
for help on using the changeset viewer.