Changeset 8202 for trunk/bp-messages/bp-messages-template.php
- Timestamp:
- 03/29/2014 01:00:36 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-messages/bp-messages-template.php
r8070 r8202 307 307 } 308 308 309 function bp_message_thread_view_link() { 310 echo bp_get_message_thread_view_link(); 311 } 312 function bp_get_message_thread_view_link() { 313 global $messages_template, $bp; 314 return apply_filters( 'bp_get_message_thread_view_link', trailingslashit( bp_loggedin_user_domain() . $bp->messages->slug . '/view/' . $messages_template->thread->thread_id ) ); 309 function bp_message_thread_view_link( $thread_id = 0 ) { 310 echo bp_get_message_thread_view_link( $thread_id ); 311 } 312 function bp_get_message_thread_view_link( $thread_id = 0 ) { 313 global $messages_template; 314 315 if ( empty( $messages_template ) && (int) $thread_id > 0 ) { 316 $thread_id = (int) $thread_id; 317 } else { 318 $thread_id = $messages_template->thread->thread_id; 319 } 320 321 return apply_filters( 'bp_get_message_thread_view_link', trailingslashit( bp_loggedin_user_domain() . buddypress()->messages->slug . '/view/' . $thread_id ) ); 315 322 } 316 323
Note: See TracChangeset
for help on using the changeset viewer.