FireBot

functions.php

Jun 17th, 2011
227
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.65 KB | None | 0 0
  1. <?php
  2. if ( function_exists('register_sidebar') )
  3. register_sidebar();
  4. ?>
  5. <?php
  6. function list_pings($comment, $args, $depth) {
  7. $GLOBALS['comment'] = $comment;
  8. ?>
  9. <li id="comment-<?php comment_ID(); ?>"><?php comment_author_link(); ?>
  10. <?php } ?>
  11. <?php
  12. add_filter('get_comments_number', 'comment_count', 0);
  13. function comment_count( $count ) {
  14. if ( ! is_admin() ) {
  15. global $id;
  16. $comments_by_type = &separate_comments(get_comments('status=approve&post_id=' . $id));
  17. return count($comments_by_type['comment']);
  18. } else {
  19. return $count;
  20. }
  21. }
  22. ?>
  23. <?php
  24. function ddnetwork_comment($comment, $args, $depth) {
  25. $GLOBALS['comment'] = $comment;
  26. ?>
  27. <li <?php comment_class(); ?> id="li-comment-<?php comment_ID() ?>">
  28. <div class="comment-container" id="comment-<?php comment_ID(); ?>">
  29.  
  30. <div class="comment-left-box">
  31. <div class="name-container">
  32. <?php printf(__('<cite class="fn">%s</cite>'), get_comment_author_link()) ?>
  33. </div><!--/name-container-->
  34.  
  35. <div class="author-avatar">
  36. <?php echo get_avatar($comment, $size = '80', 'http://www.static.dvorakdesigns.com/blog-files/images/default-avatar.gif' ); ?><br />
  37. <a href="<?php comment_author_url(); ?>" rel="external nofollow" target="_blank">Website</a>
  38. </div><!--/author-avatar-->
  39. </div><!--/comment-left-box-->
  40.  
  41. <div class="float-left"><img src="<?php bloginfo('template_url'); ?>/images/single-comment-arrow.png" width="17" height="72" alt="" /></div><!--comment-arrow-->
  42.  
  43. <div class="comment-right-box">
  44. <div class="comment-body">
  45. <?php comment_text() ?> <?php comment_reply_link(array_merge( $args, array('depth' => $depth, 'max_depth' => $args['max_depth']))) ?> <?php edit_comment_link(__('(Edit)'),' ','') ?>
  46. </div><!--comment-body-->
  47.  
  48. <div class="comment-meta commentmetadata float-right">
  49. <a href="<?php echo htmlspecialchars( get_comment_link( $comment->comment_ID ) ) ?>" title="Get Comment Permalink"><?php printf(__('%1$s at %2$s'), get_comment_date(), get_comment_time()) ?></a>
  50. </div><!--/comment-meta-->
  51.  
  52. <?php if ($comment->comment_approved == '0') : ?>
  53. <em><?php comment_author(); ?></em>
  54. <?php endif; ?>
  55. </div><!--comment-right-box-->
  56. <div class="clear"></div>
  57.  
  58. </div><!--/comment-container-->
  59. <?php
  60. }
  61. ?>
  62. <?php
  63. if ( function_exists('register_sidebar') )
  64. register_sidebar(array(
  65. 'before_widget' => '',
  66. 'after_widget' => '',
  67. 'before_title' => '<div class="box-header">',
  68. 'after_title' => '</div>',
  69. ));
  70. ?>
  71. <?php
  72. function home_page_menu_args( $args ) {
  73. $args['show_home'] = true;
  74. return $args;
  75. }
  76. add_filter( 'wp_page_menu_args', 'home_page_menu_args' );
  77. ?>
Advertisement
Add Comment
Please, Sign In to add comment