function widget($args, $instance) { global $bp; extract($args); echo $before_widget; echo $before_title . $widget_name . $after_title; ?> <?php if (bp_has_links('type=popular&per_page=' . $instance['max_links'] . '&max=' . $instance['max_links'])) { ?> <div class="item-options" id="links-list-options"> <span class="ajax-loader" id="ajax-loader-links"></span> <a href="<?php echo site_url() . '/' . bp_links_root_slug(); ?> " id="newest-links"><?php _e("Newest", 'buddypress'); ?> </a> | <?php if (bp_links_is_voting_enabled()) { ?> <a href="<?php echo site_url() . '/' . bp_links_root_slug(); ?> " id="most-votes"><?php _e("Votes", 'buddypress-links'); ?> </a> | <a href="<?php echo site_url() . '/' . bp_links_root_slug(); ?> " id="high-votes"><?php _e("Rating", 'buddypress-links'); ?> </a> | <a href="<?php echo site_url() . '/' . bp_links_root_slug(); ?> " id="popular-links" class="selected"><?php _e("Popular", 'buddypress'); ?> </a> <?php } else { ?> <a href="<?php echo site_url() . '/' . bp_links_root_slug(); ?> " id="active-links"><?php _e("Active", 'buddypress'); ?> </a> <?php } ?> </div> <ul id="links-list" class="item-list"> <?php while (bp_links()) { bp_the_link(); ?> <li> <div class="item-avatar"> <a href="<?php bp_link_permalink(); ?> "><?php bp_link_avatar(array('width' => bp_core_avatar_thumb_width(), 'height' => bp_core_avatar_thumb_height())); ?> </a> </div> <div class="item"> <div class="item-title"><a href="<?php bp_link_permalink(); ?> " title="<?php bp_link_name(); ?> "><?php bp_link_name(); ?> </a></div> <?php if (bp_links_is_voting_enabled()) { ?> <div class="item-meta"><span class="activity"><?php printf(__('%+d rating', 'buddypress-links'), bp_get_link_vote_total()); ?> </span></div> <?php } ?> </div> </li> <?php } ?> </ul> <?php wp_nonce_field('bp_links_widget_links_list', '_wpnonce-links'); ?> <input type="hidden" name="links_widget_max" id="links_widget_max" value="<?php echo attribute_escape($instance['max_links']); ?> " /> <?php } else { ?> <div class="widget-error"> <?php _e('There are no links to display.', 'buddypress-links'); ?> </div> <?php } ?> <?php echo $after_widget; ?> <?php }
get_header('buddypress'); // spit out old containers ?> <div id="content"> <div class="padder"><?php } else { // spit out legacy container ?> <div id="buddypress"><?php } ?> <div id="content" class="link-home"> <div class="padder"> <?php if (bp_has_links()) { while (bp_links()) { bp_the_link(); ?> <?php do_action('bp_before_link_home_content'); ?> <div id="item-header"> <?php bp_links_locate_template(array('single/link-header.php'), true); ?> </div> <div id="item-nav">
?> </pubDate> <generator>http://buddypress.org/?v=<?php echo BP_VERSION; ?> </generator> <language><?php echo get_option('rss_language'); ?> </language> <?php do_action('bp_directory_links_feed_head'); ?> <?php if (bp_has_links('type=newest&max=50')) { ?> <?php while (bp_links()) { bp_the_link(); ?> <item> <guid><?php bp_link_feed_item_guid(); ?> </guid> <title><?php bp_link_feed_item_title(); ?> </title> <link><?php
<label class="screen-reader-text" for="s"><?php _e('Search Links', 'buddypress-links'); ?> :</label> <input type="text" id="s" name="s" value="<?php _admin_search_query(); ?> " /> <?php submit_button(__('Search Links', 'buddypress-links'), 'button', false, false, array('id' => 'search-submit')); ?> </p> </form> <?php if (bp_has_links('type=newest&per_page=10')) { ?> <form id="bp-link-admin-list" method="post" action=""> <div class="tablenav"> <div class="tablenav-pages"> <?php bp_links_pagination_count(); ?> <?php bp_links_pagination_links(); ?> </div> <div class="alignleft"> <input class="button-secondary delete" type="submit" name="links_admin_delete" value="<?php _e('Delete', 'buddypress-links'); ?>
<?php do_action('bp_before_links_loop'); ?> <?php if (bp_has_links(bp_ajax_querystring('links'))) { ?> <div id="pag-top" class="pagination no-ajax"> <?php do_action('bp_before_links_loop_pagination'); ?> <div class="pag-count" id="link-dir-count"> <?php bp_links_pagination_count(); ?> </div> <div class="pagination-links" id="link-dir-pag"> <?php bp_links_pagination_links(); ?> </div> <?php do_action('bp_after_links_loop_pagination'); ?>
<label class="screen-reader-text" for="s"><?php _e('Search Links', 'buddypress-links'); ?> :</label> <input type="text" id="s" name="s" value="<?php _admin_search_query(); ?> " /> <?php submit_button(__('Search Links', 'buddypress-links'), 'button', false, false, array('id' => 'search-submit')); ?> </p> </form> <?php if (bp_has_links('type=active&per_page=10')) { ?> <form id="bp-link-admin-list" method="post" action=""> <div class="tablenav"> <div class="tablenav-pages"> <?php bp_links_pagination_count(); ?> <?php bp_links_pagination_links(); ?> </div> <div class="alignleft"> <input class="button-secondary delete" type="submit" name="links_admin_delete" value="<?php _e('Delete', 'buddypress-links'); ?>