-
Notifications
You must be signed in to change notification settings - Fork 20
/
okfn-front.php
70 lines (54 loc) · 1.93 KB
/
okfn-front.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
<?php
/*
Template Name: OKFN Front Page
*/
?>
<?php get_header(); ?>
<div class="row">
<div id="content" class="okfn-front span12">
<div class="padder">
<?php do_action( 'bp_before_blog_page' ); ?>
<div class="page" id="blog-page" role="main">
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<h1 class="pagetitle"><?php the_title(); ?></h1>
<div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<div class="entry">
<?php the_content( __( '<p class="serif">Read the rest of this page →</p>', 'buddypress' ) ); ?>
<?php wp_link_pages( array( 'before' => '<div class="page-link"><p>' . __( 'Pages: ', 'buddypress' ), 'after' => '</p></div>', 'next_or_number' => 'number' ) ); ?>
<?php edit_post_link( __( 'Edit this page.', 'buddypress' ), '<p class="edit-link">', '</p>'); ?>
</div>
</div>
<?php comments_template(); ?>
<?php endwhile; endif; ?>
<h3>From our Blog</h3>
<?php $okfn_front_post_number="4" ?>
<div class="magazine posts<?php echo $okfn_front_post_number ?>">
<?php
if (switch_to_blog(37,true)) {
// Query remaining posts
$post_filter_etc = array('posts_per_page' => $okfn_front_post_number);
// Print the remaining posts
query_posts( $post_filter_etc );
while (have_posts()) {
the_post();
echo_magazine_post($post, false);
}
restore_current_blog();
}
?>
<script>
jQuery(window).load(function() {
jQuery(".magazine .post.preview .text").dotdotdot({});
jQuery(".magazine .post.preview .text h2").dotdotdot({});
});
</script>
</div><!-- .magazine -->
</div><!-- .page -->
<?php do_action( 'bp_after_blog_page' ); ?>
</div><!-- .padder -->
</div><!-- #content -->
<div id="sidebar" class="span4" role="complementary">
<?php get_sidebar(); ?>
</div>
</div>
<?php get_footer(); ?>