Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: ms_user_list_site_actions

To save our bandwidth, we show only a snippet of code around each occurence of the hook. View complete file in SVN (without highlighting).

Understanding Source Code

The best way to understand what a hook does is to look at where it occurs in the source code.

Remember, this hook may occur in more than one file. Moreover, the hook's context may change from version to version.

Source View

Line Code
237                                              if ( get_blog_status( $val->userblog_id, 'mature' ) == 1 )
238                                                   $class .= 'site-mature ';
239                                              if ( get_blog_status( $val->userblog_id, 'deleted' ) == 1 )
240                                                   $class .= 'site-deleted ';
241                                              if ( get_blog_status( $val->userblog_id, 'archived' ) == 1 )
242                                                   $class .= 'site-archived ';
243
244                                              $actions['view'] = '<a class="' . $class . '" href="' .  esc_url( get_home_url( $val->userblog_id ) )  . '">' . __( 'View' ) . '</a>';
245
246                                              $actions = apply_filters('ms_user_list_site_actions', $actions, $val->userblog_id);
247
248                                              $i=0;
249                                              $action_count = count( $actions );
250                                              foreach ( $actions as $action => $link ) {
251                                                   ++$i;
252                                                   ( $i == $action_count ) ? $sep = '' : $sep = ' | ';
253                                                   echo "<span class='$action'>$link$sep</span>";
254                                              }
255                                              echo '</small></span><br/>';