Advertisement
Ronnie_Fantastic

content.php

Oct 29th, 2012
50
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.28 KB | None | 0 0
  1. <?php
  2.  
  3. /**
  4. *
  5. * content*.php
  6. *
  7. * The post format template. You can change the structure of your posts or add/remove post elements here.
  8. *
  9. * 'id' - post id
  10. * 'class' - post class
  11. * 'thumbnail' - post icon
  12. * 'title' - post title
  13. * 'before' - post header metadata
  14. * 'content' - post content
  15. * 'after' - post footer metadata
  16. *
  17. * To create a new custom post format template you must create a file "content-YourTemplateName.php"
  18. * Then copy the contents of the existing content.php into your file and edit it the way you want.
  19. *
  20. * Change an existing get_template_part() function as follows:
  21. * get_template_part('content', 'YourTemplateName');
  22. *
  23. */
  24.  
  25. global $post;
  26. theme_post_wrapper(
  27. array(
  28. 'id' => theme_get_post_id(),
  29. 'class' => theme_get_post_class(),
  30. 'thumbnail' => theme_get_post_thumbnail(),
  31. 'title' => '<a href="' . get_permalink( $post->ID ) . '" rel="bookmark" title="' . strip_tags(get_the_title()) . '">' . get_the_title() . '</a>',
  32. 'heading' => theme_get_option('theme_'.(is_single()?'single':'posts').'_article_title_tag'),
  33. 'before' => theme_get_metadata_icons( 'edit', 'header' ),
  34. 'content' => theme_get_excerpt(),
  35. 'after' => theme_get_metadata_icons( 'category,tag,comments', 'footer' )
  36. )
  37. );
  38. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement