Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php get_header(); ?>
- <div id="content">
- <div class="padder">
- <?php do_action( 'bp_before_archive' ) ?>
- <div class="page" id="blog-archives">
- <h3 class="pagetitle"><?php printf( __( '%1$s.', 'buddypress' ), wp_title( false, false ) ); ?></h3>
- <?php if ( have_posts() ) : ?>
- <?php while (have_posts()) : the_post(); ?>
- <?php global $wpdb; $attachment_id = $wpdb->get_var("SELECT ID FROM $wpdb->posts WHERE post_parent = '$post->ID'
- AND post_status = 'inherit' AND post_type='attachment' ORDER BY post_date DESC LIMIT 1"); ?>
- <?php do_action( 'bp_before_blog_post' ) ?>
- <div class="post" id="post-<?php the_ID(); ?>">
- <div class="author-box">
- <?php echo get_avatar( get_the_author_meta( 'user_email' ), '50' ); ?>
- <p><?php printf( __( 'by %s', 'buddypress' ), bp_core_get_userlink( $post->post_author ) ) ?></p>
- </div><!-- .author-box -->
- <div class="post-content">
- <div class="postthumb">
- <?php // display image thumbnail for each post from within the index.php loop
- echo get_attachment_icon($attachment_id); ?>
- </div><!-- .postthumb -->
- <h2 class="posttitle"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php _e( 'Permanent Link to', 'buddypress' ) ?> <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
- <p class="date"><em> <?php printf( __( 'Found by %s,', 'buddypress' ), bp_core_get_userlink( $post->post_author ) ) ?> <?php _e( 'filed in', 'buddypress' ) ?> <?php the_category(', ') ?></em> </p>
- <div class="entry">
- <?php the_excerpt( __( 'Read the rest of this entry →', 'buddypress' ) ); ?>
- </div><!-- .entry -->
- <p class="postmetadata"><span class="tags"><?php the_tags( __( 'Tags: ', 'buddypress' ), ', ', '<br />'); ?></span> <?php if ( is_user_logged_in() ) : ?>
- <div style="clear:both;"></div>
- <div id="custom-post-meta">
- <div class="tweet"> <script type="text/javascript">tweetmeme_style = "compact";</script><script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js"></script></div>
- <div class="fbshare"><a name="fb_share" type="button_count" href="http://www.facebook.com/sharer.php">Share</a><script src="http://static.ak.fbcdn.net/connect.php/js/FB.Share" type="text/javascript"></script></div>
- <div class="loveit">
- <?php if ( !bp_get_activity_is_favorite() ) : ?>
- <a class="fav" href="<?php bp_activity_favorite_link() ?>" class="fav" title="<?php _e( 'ADD TO FAVOURITES', 'buddypress' ) ?>"><?php _e( 'Add to favourites', 'buddypress' ) ?></a>
- <?php else : ?>
- <a class="fav" href="<?php bp_activity_unfavorite_link() ?>" class="unfav" title="<?php _e( 'REMOVE FAVOURITE', 'buddypress' ) ?>"><?php _e( 'Un-Favourite', 'buddypress' ) ?></a>
- <?php endif; ?>
- <?php endif; ?></div>
- <div class="rating">
- <?php if(function_exists('the_ratings')) { the_ratings(); } ?>
- </div><!-- ratings -->
- </div><!-- custom-post-meta -->
- </div><!-- post content-->
- </div><!-- post-->
- <?php do_action( 'bp_after_blog_post' ) ?>
- <?php endwhile; ?>
- <?php else : ?>
- <h2 class="center"><?php _e( 'Not Found', 'buddypress' ) ?></h2>
- <?php locate_template( array( 'searchform.php' ), true ) ?>
- <?php endif; ?>
- </div><!---page archives -->
- <?php do_action( 'bp_after_archive' ) ?>
- </div><!-- .padder -->
- </div><!-- #content -->
- <div class="navigation">
- <div class="alignleft"><?php next_posts_link( __( 'Next >>', 'buddypress' ) ) ?></div>
- <div class="alignright"><?php previous_posts_link( __( '<< Back ', 'buddypress' ) ) ?></div>
- </div>
- <?php locate_template( array( 'sidebar.php' ), true ) ?>
- <?php get_footer() ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement