BuddyPress - Version 1.9.1

Version Description

See: http://codex.buddypress.org/releases/version-1-9-1/

Download this release

Release Info

Developer johnjamesjacoby
Plugin Icon 128x128 BuddyPress
Version 1.9.1
Comparing to
See all releases

Code changes from version 1.9 to 1.9.1

bp-languages/buddypress.pot CHANGED
@@ -4,7 +4,7 @@ msgid ""
4
  msgstr ""
5
  "Project-Id-Version: BuddyPress \n"
6
  "Report-Msgid-Bugs-To: http://wppolyglots.wordpress.com\n"
7
- "POT-Creation-Date: 2013-12-17 00:35:15+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -5647,30 +5647,37 @@ msgid "Send Reply"
5647
  msgstr ""
5648
 
5649
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/feedback-no-notifications.php:7
 
5650
  msgid "You have no unread notifications."
5651
  msgstr ""
5652
 
5653
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/feedback-no-notifications.php:11
 
5654
  msgid "This member has no unread notifications."
5655
  msgstr ""
5656
 
5657
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/feedback-no-notifications.php:19
 
5658
  msgid "You have no notifications."
5659
  msgstr ""
5660
 
5661
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/feedback-no-notifications.php:23
 
5662
  msgid "This member has no notifications."
5663
  msgstr ""
5664
 
5665
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/notifications-loop.php:5
 
5666
  msgid "Notification"
5667
  msgstr ""
5668
 
5669
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/notifications-loop.php:6
 
5670
  msgid "Date Received"
5671
  msgstr ""
5672
 
5673
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/notifications-loop.php:7
 
5674
  msgid "Actions"
5675
  msgstr ""
5676
 
4
  msgstr ""
5
  "Project-Id-Version: BuddyPress \n"
6
  "Report-Msgid-Bugs-To: http://wppolyglots.wordpress.com\n"
7
+ "POT-Creation-Date: 2013-12-17 18:35:37+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
5647
  msgstr ""
5648
 
5649
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/feedback-no-notifications.php:7
5650
+ #: bp-themes/bp-default/members/single/notifications/feedback-no-notifications.php:7
5651
  msgid "You have no unread notifications."
5652
  msgstr ""
5653
 
5654
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/feedback-no-notifications.php:11
5655
+ #: bp-themes/bp-default/members/single/notifications/feedback-no-notifications.php:11
5656
  msgid "This member has no unread notifications."
5657
  msgstr ""
5658
 
5659
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/feedback-no-notifications.php:19
5660
+ #: bp-themes/bp-default/members/single/notifications/feedback-no-notifications.php:19
5661
  msgid "You have no notifications."
5662
  msgstr ""
5663
 
5664
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/feedback-no-notifications.php:23
5665
+ #: bp-themes/bp-default/members/single/notifications/feedback-no-notifications.php:23
5666
  msgid "This member has no notifications."
5667
  msgstr ""
5668
 
5669
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/notifications-loop.php:5
5670
+ #: bp-themes/bp-default/members/single/notifications/notifications-loop.php:5
5671
  msgid "Notification"
5672
  msgstr ""
5673
 
5674
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/notifications-loop.php:6
5675
+ #: bp-themes/bp-default/members/single/notifications/notifications-loop.php:6
5676
  msgid "Date Received"
5677
  msgstr ""
5678
 
5679
  #: bp-templates/bp-legacy/buddypress/members/single/notifications/notifications-loop.php:7
5680
+ #: bp-themes/bp-default/members/single/notifications/notifications-loop.php:7
5681
  msgid "Actions"
5682
  msgstr ""
5683
 
bp-loader.php CHANGED
@@ -16,7 +16,7 @@
16
  * Description: Social networking in a box. Build a social network for your company, school, sports team or niche community all based on the power and flexibility of WordPress.
17
  * Author: The BuddyPress Community
18
  * Author URI: http://buddypress.org/community/members/
19
- * Version: 1.9
20
  * Text Domain: buddypress
21
  * Domain Path: /bp-languages/
22
  * License: GPLv2 or later (license.txt)
@@ -297,7 +297,7 @@ class BuddyPress {
297
 
298
  /** Versions **********************************************************/
299
 
300
- $this->version = '1.9-7682';
301
  $this->db_version = 7553;
302
 
303
  /** Loading ***********************************************************/
16
  * Description: Social networking in a box. Build a social network for your company, school, sports team or niche community all based on the power and flexibility of WordPress.
17
  * Author: The BuddyPress Community
18
  * Author URI: http://buddypress.org/community/members/
19
+ * Version: 1.9.1
20
  * Text Domain: buddypress
21
  * Domain Path: /bp-languages/
22
  * License: GPLv2 or later (license.txt)
297
 
298
  /** Versions **********************************************************/
299
 
300
+ $this->version = '1.9.1-7716';
301
  $this->db_version = 7553;
302
 
303
  /** Loading ***********************************************************/
bp-notifications/bp-notifications-classes.php CHANGED
@@ -553,7 +553,7 @@ class BP_Notifications_Notification {
553
  'user_id' => false,
554
  'item_id' => false,
555
  'secondary_item_id' => false,
556
- 'component_name' => false,
557
  'component_action' => false,
558
  'is_new' => true,
559
  'search_terms' => '',
@@ -612,6 +612,10 @@ class BP_Notifications_Notification {
612
  public static function get_total_count( $args ) {
613
  global $wpdb;
614
 
 
 
 
 
615
  $bp = buddypress();
616
  $select_sql = "SELECT COUNT(*)";
617
  $from_sql = "FROM {$bp->notifications->table_name}";
553
  'user_id' => false,
554
  'item_id' => false,
555
  'secondary_item_id' => false,
556
+ 'component_name' => bp_notifications_get_registered_components(),
557
  'component_action' => false,
558
  'is_new' => true,
559
  'search_terms' => '',
612
  public static function get_total_count( $args ) {
613
  global $wpdb;
614
 
615
+ $args = wp_parse_args( $args, array(
616
+ 'component_name' => bp_notifications_get_registered_components(),
617
+ ) );
618
+
619
  $bp = buddypress();
620
  $select_sql = "SELECT COUNT(*)";
621
  $from_sql = "FROM {$bp->notifications->table_name}";
bp-notifications/bp-notifications-functions.php CHANGED
@@ -123,8 +123,7 @@ function bp_notifications_get_notifications_for_user( $user_id, $format = 'simpl
123
  // Setup local variables
124
  $bp = buddypress();
125
  $notifications = BP_Notifications_Notification::get( array(
126
- 'user_id' => $user_id,
127
- 'component_name' => array_keys( $bp->active_components ),
128
  ) );
129
  $grouped_notifications = array(); // Notification groups
130
  $renderable = array(); // Renderable notifications
@@ -508,3 +507,34 @@ function bp_notifications_get_unread_notification_count( $user_id = 0 ) {
508
 
509
  return apply_filters( 'bp_notifications_get_total_notification_count', $count );
510
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
123
  // Setup local variables
124
  $bp = buddypress();
125
  $notifications = BP_Notifications_Notification::get( array(
126
+ 'user_id' => $user_id
 
127
  ) );
128
  $grouped_notifications = array(); // Notification groups
129
  $renderable = array(); // Renderable notifications
507
 
508
  return apply_filters( 'bp_notifications_get_total_notification_count', $count );
509
  }
510
+
511
+
512
+ /**
513
+ * Return an array of component names that are currently active and have
514
+ * registered Notifications callbacks.
515
+ *
516
+ * @since BuddyPress (1.9.1)
517
+ *
518
+ * @see http://buddypress.trac.wordpress.org/ticket/5300
519
+ */
520
+ function bp_notifications_get_registered_components() {
521
+
522
+ // Load BuddyPress
523
+ $bp = buddypress();
524
+
525
+ // Setup return value
526
+ $component_names = array();
527
+
528
+ // Get the active components
529
+ $active_components = array_keys( $bp->active_components );
530
+
531
+ // Loop through components, look for callbacks, add to return value
532
+ foreach ( $active_components as $component ) {
533
+ if ( !empty( $bp->$component->notification_callback ) ) {
534
+ $component_names[] = $component;
535
+ }
536
+ }
537
+
538
+ // Return active components with registered notifications callbacks
539
+ return apply_filters( 'bp_notifications_get_registered_components', $component_names, $active_components );
540
+ }
bp-themes/bp-default/members/single/home.php CHANGED
@@ -60,6 +60,9 @@ get_header( 'buddypress' ); ?>
60
  elseif ( bp_is_user_settings() ) :
61
  locate_template( array( 'members/single/settings.php' ), true );
62
 
 
 
 
63
  // If nothing sticks, load a generic template
64
  else :
65
  locate_template( array( 'members/single/plugins.php' ), true );
60
  elseif ( bp_is_user_settings() ) :
61
  locate_template( array( 'members/single/settings.php' ), true );
62
 
63
+ elseif ( bp_is_user_notifications() ) :
64
+ locate_template( array( 'members/single/notifications.php' ), true );
65
+
66
  // If nothing sticks, load a generic template
67
  else :
68
  locate_template( array( 'members/single/plugins.php' ), true );
bp-themes/bp-default/members/single/notifications.php ADDED
@@ -0,0 +1,39 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * BuddyPress - Users Notifications
5
+ *
6
+ * @package BuddyPress
7
+ * @subpackage bp-legacy
8
+ */
9
+
10
+ ?>
11
+
12
+ <div class="item-list-tabs no-ajax" id="subnav" role="navigation">
13
+ <ul>
14
+ <?php bp_get_options_nav(); ?>
15
+
16
+ <li id="members-order-select" class="last filter">
17
+ <?php bp_notifications_sort_order_form(); ?>
18
+ </li>
19
+ </ul>
20
+ </div>
21
+
22
+ <?php
23
+ switch ( bp_current_action() ) :
24
+
25
+ // Unread
26
+ case 'unread' :
27
+ bp_get_template_part( 'members/single/notifications/unread' );
28
+ break;
29
+
30
+ // Read
31
+ case 'read' :
32
+ bp_get_template_part( 'members/single/notifications/read' );
33
+ break;
34
+
35
+ // Any other
36
+ default :
37
+ bp_get_template_part( 'members/single/plugins' );
38
+ break;
39
+ endswitch;
bp-themes/bp-default/members/single/notifications/feedback-no-notifications.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div id="message" class="info">
2
+
3
+ <?php if ( bp_is_current_action( 'unread' ) ) : ?>
4
+
5
+ <?php if ( bp_is_my_profile() ) : ?>
6
+
7
+ <p><?php _e( 'You have no unread notifications.', 'buddypress' ); ?></p>
8
+
9
+ <?php else : ?>
10
+
11
+ <p><?php _e( 'This member has no unread notifications.', 'buddypress' ); ?></p>
12
+
13
+ <?php endif; ?>
14
+
15
+ <?php else : ?>
16
+
17
+ <?php if ( bp_is_my_profile() ) : ?>
18
+
19
+ <p><?php _e( 'You have no notifications.', 'buddypress' ); ?></p>
20
+
21
+ <?php else : ?>
22
+
23
+ <p><?php _e( 'This member has no notifications.', 'buddypress' ); ?></p>
24
+
25
+ <?php endif; ?>
26
+
27
+ <?php endif; ?>
28
+
29
+ </div>
bp-themes/bp-default/members/single/notifications/notifications-loop.php ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <table class="notifications">
2
+ <thead>
3
+ <tr>
4
+ <th class="icon"></th>
5
+ <th class="title"><?php _e( 'Notification', 'buddypress' ); ?></th>
6
+ <th class="date"><?php _e( 'Date Received', 'buddypress' ); ?></th>
7
+ <th class="actions"><?php _e( 'Actions', 'buddypress' ); ?></th>
8
+ </tr>
9
+ </thead>
10
+
11
+ <tbody>
12
+
13
+ <?php while ( bp_the_notifications() ) : bp_the_notification(); ?>
14
+
15
+ <tr>
16
+ <td></td>
17
+ <td><?php bp_the_notification_description(); ?></td>
18
+ <td><?php bp_the_notification_time_since(); ?></td>
19
+ <td><?php bp_the_notification_action_links(); ?></td>
20
+ </tr>
21
+
22
+ <?php endwhile; ?>
23
+
24
+ </tbody>
25
+ </table>
bp-themes/bp-default/members/single/notifications/read.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php if ( bp_has_notifications() ) : ?>
2
+
3
+ <div id="pag-top" class="pagination no-ajax">
4
+ <div class="pag-count" id="notifications-count-top">
5
+ <?php bp_notifications_pagination_count(); ?>
6
+ </div>
7
+
8
+ <div class="pagination-links" id="notifications-pag-top">
9
+ <?php bp_notifications_pagination_links(); ?>
10
+ </div>
11
+ </div>
12
+
13
+ <?php bp_get_template_part( 'members/single/notifications/notifications-loop' ); ?>
14
+
15
+ <div id="pag-bottom" class="pagination no-ajax">
16
+ <div class="pag-count" id="notifications-count-bottom">
17
+ <?php bp_notifications_pagination_count(); ?>
18
+ </div>
19
+
20
+ <div class="pagination-links" id="notifications-pag-bottom">
21
+ <?php bp_notifications_pagination_links(); ?>
22
+ </div>
23
+ </div>
24
+
25
+ <?php else : ?>
26
+
27
+ <?php bp_get_template_part( 'members/single/notifications/feedback-no-notifications' ); ?>
28
+
29
+ <?php endif;
bp-themes/bp-default/members/single/notifications/unread.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php if ( bp_has_notifications() ) : ?>
2
+
3
+ <div id="pag-top" class="pagination no-ajax">
4
+ <div class="pag-count" id="notifications-count-top">
5
+ <?php bp_notifications_pagination_count(); ?>
6
+ </div>
7
+
8
+ <div class="pagination-links" id="notifications-pag-top">
9
+ <?php bp_notifications_pagination_links(); ?>
10
+ </div>
11
+ </div>
12
+
13
+ <?php bp_get_template_part( 'members/single/notifications/notifications-loop' ); ?>
14
+
15
+ <div id="pag-bottom" class="pagination no-ajax">
16
+ <div class="pag-count" id="notifications-count-bottom">
17
+ <?php bp_notifications_pagination_count(); ?>
18
+ </div>
19
+
20
+ <div class="pagination-links" id="notifications-pag-bottom">
21
+ <?php bp_notifications_pagination_links(); ?>
22
+ </div>
23
+ </div>
24
+
25
+ <?php else : ?>
26
+
27
+ <?php bp_get_template_part( 'members/single/notifications/feedback-no-notifications' ); ?>
28
+
29
+ <?php endif;
bp-themes/bp-default/rtl.css CHANGED
@@ -2,7 +2,7 @@
2
  * Theme Name: BuddyPress Default
3
  * Theme URI: http://buddypress.org/extend/themes/
4
  * Description: Clean and stylish, BuddyPress Default lets you build a social network straight out of the box. Make it yours with a custom menu, header image, and background. Along with five widgetized areas (one in the sidebar, four in the footer), BP-Default supports featured images (as custom header images on posts and pages) and is furnished with an optional one-column page template that removes the sidebar, and a stylesheet for the admin Visual Editor.
5
- * Version: 1.9
6
  * Author: the BuddyPress team
7
  * Author URI: http://buddypress.org
8
  * License: GNU General Public License
2
  * Theme Name: BuddyPress Default
3
  * Theme URI: http://buddypress.org/extend/themes/
4
  * Description: Clean and stylish, BuddyPress Default lets you build a social network straight out of the box. Make it yours with a custom menu, header image, and background. Along with five widgetized areas (one in the sidebar, four in the footer), BP-Default supports featured images (as custom header images on posts and pages) and is furnished with an optional one-column page template that removes the sidebar, and a stylesheet for the admin Visual Editor.
5
+ * Version: 1.9.1
6
  * Author: the BuddyPress team
7
  * Author URI: http://buddypress.org
8
  * License: GNU General Public License
bp-themes/bp-default/style.css CHANGED
@@ -2,7 +2,7 @@
2
  * Theme Name: BuddyPress Default
3
  * Theme URI: http://buddypress.org/extend/themes/
4
  * Description: [NOTE: except for security issues, BuddyPress Default is no longer being actively maintained by the BuddyPress team.] Clean and stylish, BuddyPress Default lets you build a social network straight out of the box. Make it yours with a custom menu, header image, and background. Along with five widgetized areas (one in the sidebar, four in the footer), BP-Default supports featured images (as custom header images on posts and pages) and is furnished with an optional one-column page template that removes the sidebar, and a stylesheet for the admin Visual Editor.
5
- * Version: 1.9
6
  * Author: the BuddyPress team
7
  * Author URI: http://buddypress.org
8
  * License: GNU General Public License
2
  * Theme Name: BuddyPress Default
3
  * Theme URI: http://buddypress.org/extend/themes/
4
  * Description: [NOTE: except for security issues, BuddyPress Default is no longer being actively maintained by the BuddyPress team.] Clean and stylish, BuddyPress Default lets you build a social network straight out of the box. Make it yours with a custom menu, header image, and background. Along with five widgetized areas (one in the sidebar, four in the footer), BP-Default supports featured images (as custom header images on posts and pages) and is furnished with an optional one-column page template that removes the sidebar, and a stylesheet for the admin Visual Editor.
5
+ * Version: 1.9.1
6
  * Author: the BuddyPress team
7
  * Author URI: http://buddypress.org
8
  * License: GNU General Public License
readme.txt CHANGED
@@ -1,8 +1,8 @@
1
  === BuddyPress ===
2
  Contributors: johnjamesjacoby, DJPaul, boonebgorges, r-a-y
3
  Tags: social networking, activity, profiles, messaging, friends, groups, forums, notifications, settings, twitter, facebook, social, community, networks, networking, cms
4
- Requires at least: 3.6
5
- Tested up to: 3.8
6
  Stable tag: 1.9
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -77,6 +77,9 @@ BuddyPress is available in more than 20 languages. For more information, check o
77
 
78
  == Upgrade Notice ==
79
 
 
 
 
80
  = 1.9 =
81
  See: http://codex.buddypress.org/releases/version-1-9/
82
 
1
  === BuddyPress ===
2
  Contributors: johnjamesjacoby, DJPaul, boonebgorges, r-a-y
3
  Tags: social networking, activity, profiles, messaging, friends, groups, forums, notifications, settings, twitter, facebook, social, community, networks, networking, cms
4
+ Requires at least: 3.5
5
+ Tested up to: 3.6
6
  Stable tag: 1.9
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
77
 
78
  == Upgrade Notice ==
79
 
80
+ = 1.9.1 =
81
+ See: http://codex.buddypress.org/releases/version-1-9-1/
82
+
83
  = 1.9 =
84
  See: http://codex.buddypress.org/releases/version-1-9/
85