diff options
| author | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2005-10-24 14:21:13 +0000 |
|---|---|---|
| committer | donncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36> | 2005-10-24 14:21:13 +0000 |
| commit | 797aff459d87aa09fe0c0c9a7aaf288752b5bd15 (patch) | |
| tree | 9903b14c48e73bf9d77dd0d6a32e81a0deda3bea /wp-inst/wp-includes/template-functions-post.php | |
| parent | 8a9ee3b40641ff572b10c53e9aae1a148e1e8a38 (diff) | |
Massive WP Merge
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@407 7be80a69-a1ef-0310-a953-fb0f7c49ff36
Diffstat (limited to 'wp-inst/wp-includes/template-functions-post.php')
| -rw-r--r-- | wp-inst/wp-includes/template-functions-post.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/wp-inst/wp-includes/template-functions-post.php b/wp-inst/wp-includes/template-functions-post.php index 63db111..1f76b03 100644 --- a/wp-inst/wp-includes/template-functions-post.php +++ b/wp-inst/wp-includes/template-functions-post.php @@ -438,4 +438,22 @@ function _page_level_out($parent, $page_tree, $args, $depth = 0, $echo = true) { return $output; } +function prepend_object($content) { + global $post; + + $p = '<p class="subpostobject">'; + + if ( '' != $post->guid ) { + if ( substr($post->post_type, 0, 6) == 'image/' ) + $p .= '<a href="' . $post->guid . '" title="Click for full-size image" ><img class="subpostimage" src="' . $post->guid . '" alt="' . $post->post_title . '" /></a>'; + else + $p .= __('Attachment') . ' (' . $post->post_type . ')'; + } else { + $p .= __('Missing attachment'); + } + + $p .= '</p>'; + + return "$p\n$content"; +} ?> |
