Menu Adam R Brown

WP hooks navigation: Home/browseActions indexFilters index

Source View: post_date_column_time

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

This hook occurs 3 times in this file.

Line Code
1349                          if ( $time_diff > 0 && $time_diff < 24*60*60 )
1350                               $h_time = sprintf( __('%s ago'), human_time_diff( $time ) );
1351                          else
1352                               $h_time = mysql2date(__('Y/m/d'), $m_time);
1353                     }
1354                }
1355
1356                echo '<td ' . $attributes . '>';
1357                if ( 'excerpt' == $mode )
1358                     echo apply_filters('post_date_column_time', $t_time, $post, $column_name, $mode);
1359                else
1360                     echo '<abbr title="' . $t_time . '">' . apply_filters('post_date_column_time', $h_time, $post, $column_name, $mode) . '</abbr>';
1361                echo '<br />';
1362                if ( 'publish' == $post->post_status ) {
1363                     _e('Published');
1364                } elseif ( 'future' == $post->post_status ) {
1365                     if ( isset($missed) )
1366                          echo '<strong class="attention">' . __('Missed schedule') . '</strong>';
1367                     else
1368                          _e('Scheduled');
1369                } else {
 
Line Code
1550                     if ( ( 'future' == $page->post_status) )
1551                          $h_time = sprintf( __('%s from now'), human_time_diff( $time ) );
1552                     else
1553                          $h_time = sprintf( __('%s ago'), human_time_diff( $time ) );
1554                } else {
1555                     $h_time = mysql2date(__('Y/m/d'), $m_time);
1556                }
1557           }
1558           echo '<td ' . $attributes . '>';
1559           echo '<abbr title="' . $t_time . '">' . apply_filters('post_date_column_time', $h_time, $page, $column_name, '') . '</abbr>';
1560           echo '<br />';
1561           if ( 'publish' == $page->post_status || 'future' == $page->post_status )
1562                _e('Published');
1563           else
1564                _e('Last Modified');
1565           echo '</td>';
1566           break;
1567      case 'title':
1568           $attributes = 'class="post-title page-title column-title"' . $style;