/** * Create entry date for post meta * * Override: childtheme_override_postmeta_entrydate <br> * Filter: thematic_postmeta_entrydate */ function thematic_postmeta_entrydate() { $entrydate = '<span class="meta-prep meta-prep-entry-date">' . __('Published:', 'thematic') . ' </span>'; $entrydate .= '<span class="entry-date"><abbr class="published" title="'; $entrydate .= get_the_time(thematic_time_title()) . '">'; $entrydate .= get_the_time(thematic_time_display()); $entrydate .= '</abbr></span>'; return apply_filters('thematic_postmeta_entrydate', $entrydate); }
function thematic_postheader() { global $id, $post, $authordata; // Create $posteditlink $posteditlink .= '<a href="' . get_bloginfo('wpurl') . '/wp-admin/post.php?action=edit&post=' . $id; $posteditlink .= '" title="' . __('Edit post', 'thematic') . '">'; $posteditlink .= __('Edit', 'thematic') . '</a>'; $posteditlink = apply_filters('thematic_postheader_posteditlink', $posteditlink); if (is_single() || is_page()) { $posttitle = '<h1 class="entry-title">' . get_the_title() . "</h1>\n"; } elseif (is_404()) { $posttitle = '<h1 class="entry-title">' . __('Not Found', 'thematic') . "</h1>\n"; } else { $posttitle = '<h2 class="entry-title"><a href="'; $posttitle .= get_permalink(); $posttitle .= '" title="'; $posttitle .= __('Permalink to ', 'thematic') . the_title_attribute('echo=0'); $posttitle .= '" rel="bookmark">'; $posttitle .= get_the_title(); $posttitle .= "</a></h2>\n"; } $posttitle = apply_filters('thematic_postheader_posttitle', $posttitle); $postmeta = '<div class="entry-meta">'; $postmeta .= '<span class="meta-prep meta-prep-author">' . __('By ', 'thematic') . '</span>'; $postmeta .= '<span class="author vcard">' . '<a class="url fn n" href="'; $postmeta .= get_author_link(false, $authordata->ID, $authordata->user_nicename); $postmeta .= '" title="' . __('View all posts by ', 'thematic') . get_the_author() . '">'; $postmeta .= get_the_author(); $postmeta .= '</a></span><span class="meta-sep meta-sep-entry-date"> | </span>'; $postmeta .= '<span class="meta-prep meta-prep-entry-date">' . __('Published: ', 'thematic') . '</span>'; $postmeta .= '<span class="entry-date"><abbr class="published" title="'; $postmeta .= get_the_time(thematic_time_title()) . '">'; $postmeta .= get_the_time(thematic_time_display()); $postmeta .= '</abbr></span>'; // Display edit link if (current_user_can('edit_posts')) { $postmeta .= ' <span class="meta-sep meta-sep-edit">|</span> ' . '<span class="edit">' . $posteditlink . '</span>'; } $postmeta .= "</div><!-- .entry-meta -->\n"; $postmeta = apply_filters('thematic_postheader_postmeta', $postmeta); if ($post->post_type == 'page' || is_404()) { $postheader = $posttitle; } else { $postheader = $posttitle . $postmeta; } echo apply_filters('thematic_postheader', $postheader); // Filter to override default post header }