View difference between Paste ID: 0Scgvu8N and
SHOW: | | - or go back to the newest paste.
1-
1+
<?php get_header(); ?>
2
3
<style type="text/css">
4
.td-lastpost a img {float:none; vertical-align:-7px; position:relative; left:3px;}
5
</style>
6
7
<?php 
8
global $bp, $forum_template;
9
10
if ( bp_has_forum_topics( 'type=active&user_id' . $bp->loggedin_user->id ) ) : ?>
11
12
	<h3 class="widgettitle">Show: &nbsp;<a href="http://buddypress.org/support/topics/">By Latest Post</a> &nbsp;|&nbsp; <a href="http://buddypress.org/support/topics/grouped/">By Group</a>&nbsp;|&nbsp; My Topics</h3>
13
14
	<div class="pagination">
15
16
		<div id="post-count" class="pag-count">
17
			<?php bp_forum_pagination_count() ?>
18
		</div>
19
20
		<div class="pagination-links" id="topic-pag">
21
			<?php bp_forum_pagination() ?>
22
		</div>
23
24
	</div>
25
26
	<?php do_action( 'bp_before_directory_forums_list' ) ?>
27
28
	<table class="forum zebra">
29
		<thead>
30
			<tr>
31
				<th id="th-title" style="width: 60%"><?php _e( 'Topic Title', 'buddypress' ) ?></th>
32
33
				<?php if ( !bp_is_group_forum() ) : ?>
34
					<th id="th-group"><?php _e( 'Posted In Group', 'buddypress' ) ?></th>
35
				<?php endif; ?>
36
37
				<th id="th-lastpost"><?php _e( 'Last Post', 'buddypress' ) ?></th>
38
39
				<?php do_action( 'bp_directory_forums_extra_cell_head' ) ?>
40
41
			</tr>
42
		</thead>
43
44
		<tbody>
45
46
			<?php while ( bp_forum_topics() ) : bp_the_forum_topic(); ?>
47
48
			<tr class="<?php bp_the_topic_css_class() ?>">
49
				<td class="td-title">
50
					<a href="<?php echo bp_core_get_user_domain(bp_get_the_topic_poster_id()); ?>"><?php echo bp_the_topic_poster_avatar( 'type=thumb&width=20&height=20' ) ?></a>
51
52
					<a class="topic-title" href="<?php bp_the_topic_permalink() ?>" title="<?php bp_the_topic_title() ?> - <?php _e( 'Permalink', 'buddypress' ) ?>"><?php bp_the_topic_title() ?></a>
53
54
					(<?php bp_the_topic_total_posts() ?>)
55
56
					<div class="topic-meta">
57
						Started by <?php bp_the_topic_poster_name(); ?>
58
						<!--in <a href="<?php bp_the_topic_object_permalink() ?>" title="<?php bp_the_topic_object_name() ?>"><?php bp_the_topic_object_name() ?></a>-->
59
					</div>
60
				</td>
61
62
				<?php if ( !bp_is_group_forum() ) : ?>
63
					<td class="td-group">
64
						<a href="<?php bp_the_topic_object_permalink() ?>"><?php bp_the_topic_object_avatar( 'type=thumb&width=20&height=20' ) ?></a>
65
						<div class="object-name"><a href="<?php bp_the_topic_object_permalink() ?>" title="<?php bp_the_topic_object_name() ?>"><?php bp_the_topic_object_name() ?></a></div>
66
					</td>
67
				<?php endif; ?>
68
69
				<td class="td-lastpost">
70
					<a href="<?php echo $bp->root_domain . '/' . BP_GROUPS_SLUG . '/' . $forum_template->topic->object_slug . '/forum/topic/' . $forum_template->topic->topic_slug . '/#post-'. $forum_template->topic->topic_last_post_id; ?>"><?php bp_the_topic_time_since_last_post() ?> ago</a><br />by <a href="<?php echo bp_core_get_user_domain($forum_template->topic->topic_last_poster); ?>"><?php echo bp_the_topic_last_poster_avatar( 'type=thumb&width=20&height=20' ) ?></a> <a href="<?php echo bp_core_get_user_domain($forum_template->topic->topic_last_poster); ?>"><?php bp_the_topic_last_poster_name(); ?></a>
71
				</td>
72
73
				<?php do_action( 'bp_directory_forums_extra_cell' ) ?>
74
			</tr>
75
76
			<?php do_action( 'bp_directory_forums_extra_row' ) ?>
77
78
			<?php endwhile; ?>
79
80
		</tbody>
81
	</table>
82
83
	<?php do_action( 'bp_after_directory_forums_list' ) ?>
84
85
<?php else: ?>
86
87
	<div id="message" class="info">
88
		<p><?php _e( 'Sorry, there were no forum topics found.', 'buddypress' ) ?></p>
89
	</div>
90
91
<?php endif;?>
92
93
<?php get_footer(); ?>