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
<?php get_header() ?>

<div class="content-header">

</div>

<div id="content">
	<h2>Create a Blog</h2>
	<?php do_action( 'template_notices' ) // (error/success feedback) ?>

	<?php if ( bp_blog_signup_enabled() ) : ?>
		
    <?php
    global $bp;
    $blogs = bp_blogs_get_blogs_for_user($bp->loggedin_user->id);
    if (!$blogs['count'])
    {
        bp_show_blog_signup_form();  
    }
    else
    {
    ?>
      <div id="message" class="info">
        <p><?php _e( 'Limit one Blog per member', 'buddypress' ); ?></p>
      </div>
    <?php  
    }
    ?>

	<?php else: ?>

		<div id="message" class="info">
			<p><?php _e( 'Blog registration is currently disabled', 'buddypress' ); ?></p>
		</div>

	<?php endif; ?>

</div>

<?php get_footer() ?>