public
Created

My attempt to get imath's BP Bookmarklet 2 working in my theme (a child theme of bp_default).

  • Download Gist
my_bookmarklet-dir.php
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
<?php /* Template Name: hub bookmarklet */
/**
* Main and only template of the plugin
*
* @package BP Bookmarklet
*
*/
if( bp_bookmarklet_is_bp_default() )
get_header( 'buddypress' );
?>
 
<div id="buddypress" class="hub">
<h1 class="bookmarklet_title"><?php bkmklet_the_page_title();?></h1>
<?php do_action( 'template_notices' ); ?>
<?php if ( !is_user_logged_in() ) : ?>
<?php wp_login_form();?>
<?php else:?>
<?php do_action( 'bp_before_directory_bookmarklet' ); ?>
<?php bp_get_template_part( 'activity/post-form' );?>
<div id="link-result"></div>
<?php do_action( 'bp_after_directory_bookmarklet' ); ?>
<?php endif;?>
</div>
 
<?php
if( bp_bookmarklet_is_bp_default() )
get_footer( 'buddypress' );
?>

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.