Skip to:
Content

BuddyPress.org

Ticket #2965: 2965.001.diff

File 2965.001.diff, 85.4 KB (added by cnorris23, 14 years ago)
  • bp-friends.php

     
    571571
    572572function friends_remove_data( $user_id ) {
    573573        global $bp;
    574        
     574
    575575        BP_Friends_Friendship::delete_all_for_user($user_id);
    576576
    577577        /* Remove usermeta */
  • bp-activity.php

     
    508508 *
    509509 * @package BuddyPress Activity
    510510 * @since 1.3
    511  * 
     511 *
    512512 * @param $content The content of the activity, usually found in $activity->content
    513513 * @return array $usernames Array of the found usernames that match existing users
    514514 */
    515515function bp_activity_find_mentions( $content ) {
    516516        $pattern = '/[@]+([A-Za-z0-9-_\.]+)/';
    517517        preg_match_all( $pattern, $content, $usernames );
    518        
     518
    519519        // Make sure there's only one instance of each username
    520520        if ( !$usernames = array_unique( $usernames[1] ) )
    521521                return false;
    522                
     522
    523523        return $usernames;
    524524}
    525525
     
    530530 *
    531531 * @package BuddyPress Activity
    532532 * @since 1.3
    533  * 
     533 *
    534534 * @param $activity_id The unique id for the activity item
    535535 */
    536536function bp_activity_reduce_mention_count( $activity_id ) {
    537537        $activity = new BP_Activity_Activity( $activity_id );
    538        
    539         if ( $usernames = bp_activity_find_mentions( strip_tags( $activity->content ) ) ) {     
     538
     539        if ( $usernames = bp_activity_find_mentions( strip_tags( $activity->content ) ) ) {
    540540                include_once( ABSPATH . WPINC . '/registration.php' );
    541                
    542                 foreach( (array)$usernames as $username ) { 
     541
     542                foreach( (array)$usernames as $username ) {
    543543                        if ( !$user_id = username_exists( $username ) )
    544544                                continue;
    545        
     545
    546546                        // Decrease the number of new @ mentions for the user
    547547                        $new_mention_count = (int)get_user_meta( $user_id, 'bp_new_mention_count', true );
    548548                        update_user_meta( $user_id, 'bp_new_mention_count', $new_mention_count - 1 );
     
    577577                                return apply_filters( 'bp_activity_multiple_at_mentions_notification', '<a href="' . $at_mention_link . '" title="' . $at_mention_title . '">' . sprintf( __( 'You have %1$d new activity mentions', 'buddypress' ), (int)$total_items ) . '</a>', $at_mention_link, $total_items, $activity_id, $poster_user_id );
    578578                        } else {
    579579                                $user_fullname = bp_core_get_user_displayname( $poster_user_id );
    580                                
     580
    581581                                return apply_filters( 'bp_activity_single_at_mentions_notification', '<a href="' . $at_mention_link . '" title="' . $at_mention_title . '">' . sprintf( __( '%1$s mentioned you in an activity update', 'buddypress' ), $user_fullname ) . '</a>', $at_mention_link, $total_items, $activity_id, $poster_user_id );
    582582                        }
    583583                break;
     
    998998                        $new_width = $new_height * $ratio;
    999999
    10001000                        $image = '<img src="' . esc_attr( $src ) . '" width="' . $new_width . '" height="' . $new_height . '" alt="' . __( 'Thumbnail', 'buddypress' ) . '" class="align-left thumbnail" />';
    1001                        
     1001
    10021002                        if ( !empty( $link ) ) {
    10031003                                $image = '<a href="' . $link . '">' . $image . '</a>';
    10041004                        }
     
    12231223
    12241224/**
    12251225 * updates_register_activity_actions()
    1226  * 
     1226 *
    12271227 * Register the activity stream actions for updates
    1228  * 
     1228 *
    12291229 * @global array $bp
    12301230 */
    12311231function updates_register_activity_actions() {
  • bp-themes/bp-default/groups/single/admin.php

     
    199199
    200200                                                <h5>
    201201                                                        <?php bp_group_member_link() ?>
    202                                                        
     202
    203203                                                        <?php if ( bp_get_group_member_is_banned() ) _e( '(banned)', 'buddypress'); ?>
    204204
    205                                                         <span class="small"> - 
    206                                                        
     205                                                        <span class="small"> -
     206
    207207                                                        <?php if ( bp_get_group_member_is_banned() ) : ?>
    208                                                                
     208
    209209                                                                <a href="<?php bp_group_member_unban_link() ?>" class="confirm member-unban" title="<?php _e( 'Unban this member', 'buddypress' ) ?>"><?php _e( 'Remove Ban', 'buddypress' ); ?></a>
    210210
    211211                                                        <?php else : ?>
  • bp-themes/bp-default/functions.php

     
    488488 *
    489489 * @deprecated 1.3
    490490 * @deprecated No longer required.
    491  * @param string $template Absolute path to the page template 
     491 * @param string $template Absolute path to the page template
    492492 * @return string
    493493 * @since 1.2
    494494 */
  • bp-themes/bp-default/_inc/css/default.css

     
    1919        margin: 0 auto;
    2020        padding-top: 0 !important; /* Remove the top padding space for the admin bar in this theme */
    2121}
    22        
     22
    2323body.activity-permalink {
    2424        min-width: 960px;
    2525        max-width: 960px;
    2626}
    2727
    28 h1, 
    29 h2, 
    30 h3, 
    31 h4, 
    32 h5, 
     28h1,
     29h2,
     30h3,
     31h4,
     32h5,
    3333h6 {
    3434        margin: 5px 0 15px 0;
    3535}
    3636
    37 h1 { 
    38         font-size: 28px; 
    39         margin-bottom: 25px; 
     37h1 {
     38        font-size: 28px;
     39        margin-bottom: 25px;
    4040}
    4141
    42 h2 { 
    43         font-size: 24px; 
    44         margin-bottom: 20px; 
     42h2 {
     43        font-size: 24px;
     44        margin-bottom: 20px;
    4545}
    4646
    47 h3 { 
    48         font-size: 20px; 
     47h3 {
     48        font-size: 20px;
    4949}
    5050
    51 h4 { 
    52         font-size: 16px; 
    53         margin-bottom: 15px; 
     51h4 {
     52        font-size: 16px;
     53        margin-bottom: 15px;
    5454}
    5555
    56 h5 { 
    57         font-size: 14px; 
    58         margin-bottom: 0; 
     56h5 {
     57        font-size: 14px;
     58        margin-bottom: 0;
    5959}
    6060
    61 h6 { 
    62         font-size: 12px; 
    63         margin-bottom: 0; 
     61h6 {
     62        font-size: 12px;
     63        margin-bottom: 0;
    6464}
    6565
    66 a { 
    67         color: #1fb3dd; 
     66a {
     67        color: #1fb3dd;
    6868}
    6969
    70 a:hover, 
    71 a:active { 
    72         color: #888; 
     70a:hover,
     71a:active {
     72        color: #888;
    7373}
    7474
    75 a:focus { 
    76         outline: 1px dotted #ccc; 
     75a:focus {
     76        outline: 1px dotted #ccc;
    7777}
    7878
    79 .padder { 
    80         padding: 19px; 
     79.padder {
     80        padding: 19px;
    8181}
    8282
    83 .clear { 
    84         clear: left; 
     83.clear {
     84        clear: left;
    8585}
    8686
    87 p {     
    88         margin-bottom: 15px; 
     87p {
     88        margin-bottom: 15px;
    8989}
    9090
    91 p:last-child { 
    92         margin-bottom: 0; 
     91p:last-child {
     92        margin-bottom: 0;
    9393}
    9494
    9595hr {
     
    127127        height: 0;
    128128        line-height: 1;
    129129        vertical-align: baseline;
    130         position: relative;     
     130        position: relative;
    131131}
    132132
    133133
     
    153153        height: 100px;
    154154        padding-top: 25px;
    155155}
    156        
     156
    157157#header #search-bar {
    158158        position: absolute;
    159159        top: 25px;
     
    192192        width: 44%;
    193193        margin: 0 0 -5px 0;
    194194}
    195                
     195
    196196#header h1 a {
    197197        color: #fff;
    198198        font-size: 26px;
     
    212212        bottom: 0;
    213213        max-width: 65%;
    214214}
    215        
     215
    216216ul#nav li {
    217217        float: left;
    218218        margin: 0 5px 0 0;
    219219}
    220                
     220
    221221ul#nav li a {
    222222        display: block;
    223223        color: #fff;
     
    229229        -moz-border-radius-topright: 3px;
    230230        -webkit-border-top-right-radius: 3px;
    231231}
    232                        
    233 ul#nav li.selected a, 
     232
     233ul#nav li.selected a,
    234234ul#nav li.current_page_item a {
    235235        background: #f5f5f5;
    236236        color: #555;
    237237}
    238                        
    239 ul#nav a:focus { 
    240         outline: none; 
     238
     239ul#nav a:focus {
     240        outline: none;
    241241}
    242242
    243243/* > Container
     
    253253        overflow: hidden;
    254254        margin-bottom: 20px;
    255255}
    256        
     256
    257257body.activity-permalink div#container {
    258258        background: none;
    259259        border: none;
     
    273273        -webkit-border-top-right-radius: 3px;
    274274        background: url( ../images/sidebar_back.gif ) top left repeat-x;
    275275}
    276        
     276
    277277div#sidebar div#sidebar-me img.avatar {
    278278        float: left;
    279279        margin: 0 10px 15px 0;
     
    289289        clear: left;
    290290        margin: 15px -16px;
    291291}
    292                
     292
    293293div#sidebar ul#bp-nav li {
    294294        padding: 10px 15px;
    295295}
     
    306306div#sidebar .widget_search {
    307307        margin-top: 20px;
    308308}
    309                
     309
    310310#footer-widget-area .widget_search input[type=text],
    311311div#sidebar .widget_search input[type=text] {
    312312        width: 110px;
    313313        padding: 2px;
    314314}
    315315
    316 #footer-widget-area ul#recentcomments li, 
     316#footer-widget-area ul#recentcomments li,
    317317#footer-widget-area .widget_recent_entries ul li,
    318 div#sidebar ul#recentcomments li, 
     318div#sidebar ul#recentcomments li,
    319319div#sidebar .widget_recent_entries ul li {
    320320        margin-bottom: 15px;
    321321}
     
    326326        height: 20px;
    327327        margin-right: 10px;
    328328}
    329                
     329
    330330#footer-widget-area div.item-avatar img,
    331331div#sidebar div.item-avatar img {
    332332        width: 40px;
     
    335335}
    336336
    337337#footer-widget-area .avatar-block,
    338 div#sidebar .avatar-block { 
    339         overflow: hidden; 
     338div#sidebar .avatar-block {
     339        overflow: hidden;
    340340}
    341341
    342342#footer-widget-area ul.item-list div.item-title,
     
    352352        font-size: 11px;
    353353}
    354354
    355 #footer-widget-area div.item-meta, 
     355#footer-widget-area div.item-meta,
    356356#footer-widget-area div.item-content,
    357 div#sidebar div.item-meta, 
     357div#sidebar div.item-meta,
    358358div#sidebar div.item-content {
    359359        margin-left: 38px;
    360360        font-size: 11px;
     
    386386        -moz-border-radius-bottomleft: 6px;
    387387        -webkit-border-bottom-left-radius: 6px;
    388388}
    389        
     389
    390390div#content .one-column {
    391391        margin-right: 0;
    392392        border-right: 0 none;
     
    409409        overflow: hidden;
    410410}
    411411
    412 div#item-header div#item-header-content { 
    413         margin-left: 170px; 
     412div#item-header div#item-header-content {
     413        margin-left: 170px;
    414414}
    415415
    416416div#item-header h2 {
     
    418418        margin: 0 0 15px 0;
    419419        line-height: 120%;
    420420}
    421                
     421
    422422div#item-header h2 a {
    423423        text-decoration: none;
    424424        color: #777;
     
    429429        margin: 0 15px 25px 0;
    430430}
    431431
    432 div#item-header h2 { 
    433         margin-bottom: 5px; 
     432div#item-header h2 {
     433        margin-bottom: 5px;
    434434}
    435435
    436 div#item-header span.activity, 
     436div#item-header span.activity,
    437437div#item-header h2 span.highlight {
    438438        vertical-align: middle;
    439439        font-size: 11px;
     
    442442        margin-bottom: 7px;
    443443}
    444444
    445 div#item-header h2 span.highlight { 
    446         font-size: 16px; 
     445div#item-header h2 span.highlight {
     446        font-size: 16px;
    447447}
    448448
    449449div#item-header h2 span.highlight span {
     
    477477        margin: 0 0 15px 15px;
    478478        text-align: right;
    479479}
    480                
     480
    481481div#item-header div#item-actions h3 {
    482482        font-size: 12px;
    483483        margin: 0 0 5px 0;
     
    488488        margin-bottom: 15px;
    489489}
    490490
    491 div#item-header ul h5, 
    492 div#item-header ul span, 
     491div#item-header ul h5,
     492div#item-header ul span,
    493493div#item-header ul hr {
    494494        display: none;
    495495}
     
    498498        float: right;
    499499}
    500500
    501 div#item-header ul img.avatar, 
     501div#item-header ul img.avatar,
    502502div#item-header ul.avatars img.avatar {
    503503        width: 30px;
    504504        height: 30px;
    505505        margin: 2px;
    506506}
    507507
    508 div#item-header div.generic-button, 
     508div#item-header div.generic-button,
    509509div#item-header a.button {
    510510        float: left;
    511511        margin: 10px 10px 0 0;
     
    522522ul.item-list {
    523523        width: 100%;
    524524}
    525        
     525
    526526ul.item-list li {
    527527        position: relative;
    528528        padding: 15px 0;
    529529        border-bottom: 1px solid #eaeaea;
    530530}
    531                
    532 ul.single-line li { 
    533         border: none; 
     531
     532ul.single-line li {
     533        border: none;
    534534}
    535535
    536536ul.item-list li img.avatar {
     
    538538        margin: 0 10px 10px 0;
    539539}
    540540
    541 ul.item-list li div.item-title, 
     541ul.item-list li div.item-title,
    542542ul.item-list li h4 {
    543543        font-weight: normal;
    544544        font-size: 14px;
    545545        width: 75%;
    546546        margin: 0;
    547547}
    548                        
     548
    549549ul.item-list li div.item-title span {
    550550        font-size: 12px;
    551551        color: #999;
     
    586586        margin: 25px -19px 20px -19px;
    587587        background: #eaeaea;
    588588}
    589        
     589
    590590div.item-list-tabs ul li a {
    591591        text-decoration: none;
    592592}
     
    594594div.item-list-tabs ul {
    595595        width: 100%;
    596596}
    597                
     597
    598598div.item-list-tabs ul li {
    599599        float: left;
    600600        margin: 5px 0 0 5px;
    601601}
    602                        
     602
    603603div.item-list-tabs#subnav ul li {
    604604        margin-top: 0;
    605605}
     
    612612        float: right;
    613613        margin: 7px 20px 0 0;
    614614}
    615                                
     615
    616616div.item-list-tabs#subnav ul li.last {
    617617        margin-top: 4px;
    618618}
     
    627627        padding: 5px 10px;
    628628        text-decoration: none;
    629629}
    630                        
     630
    631631div.item-list-tabs ul li span {
    632632        color: #aaa;
    633633}
     
    648648        -moz-border-radius-topright: 3px;
    649649        -webkit-border-top-right-radius: 3px;
    650650}
    651                        
     651
    652652ul li.loading a {
    653653        background-image: url( ../images/ajax-loader.gif );
    654654        background-position: 92% 50%;
    655655        background-repeat: no-repeat;
    656656        padding-right: 30px !important;
    657657}
    658                                
     658
    659659div#item-nav ul li.loading a {
    660660        background-position: 88% 50%;
    661661}
     
    685685        margin: 20px 0;
    686686}
    687687
    688 span.activity, 
     688span.activity,
    689689div#message p {
    690690        display: inline-block;
    691691        font-size: 11px;
     
    710710        float: right;
    711711        margin: -37px 0 0 0;
    712712}
    713        
     713
    714714div.dir-search input[type=text] {
    715715        padding: 4px;
    716716        font-size: 12px;
     
    728728        font-size: 11px;
    729729        height: 16px;
    730730}
    731        
    732 div.pagination#user-pag, 
     731
     732div.pagination#user-pag,
    733733.friends div.pagination,
    734 .mygroups div.pagination, 
    735 .myblogs div.pagination, 
     734.mygroups div.pagination,
     735.myblogs div.pagination,
    736736noscript div.pagination {
    737737        background: #f8f8f8;
    738738        border: none;
     
    746746div.pagination .pagination-links {
    747747        float: right;
    748748}
    749                
     749
    750750div.pagination .pagination-links span,
    751751div.pagination .pagination-links a {
    752752        font-size: 12px;
    753753        padding: 0 5px;
    754754}
    755                        
     755
    756756div.pagination .pagination-links a:hover {
    757757        font-weight: bold;
    758758}
     
    768768div#message {
    769769        margin: 15px 0;
    770770}
    771        
     771
    772772div#message.updated {
    773         clear: both; 
     773        clear: both;
    774774}
    775775
    776776div#message p {
     
    778778        font-size: 12px;
    779779        display:block;
    780780}
    781        
     781
    782782div#message.error p {
    783783        background: #e41717;
    784784        color: #fff;
     
    807807/* > Buttons
    808808-------------------------------------------------------------- */
    809809
    810 a.button, 
    811 input[type=submit], 
    812 input[type=button], 
     810a.button,
     811input[type=submit],
     812input[type=button],
    813813input[type=reset],
    814 ul.button-nav li a, 
     814ul.button-nav li a,
    815815div.generic-button a {
    816816        background: url( ../images/white-grad.png ) top left repeat-x;
    817817        border: 1px solid #ddd;
     
    826826        vertical-align: bottom;
    827827        cursor: pointer;
    828828}
    829        
    830 a.button:hover, 
    831 a.button:focus, 
    832 input[type=submit]:hover, 
    833 input[type=button]:hover, 
     829
     830a.button:hover,
     831a.button:focus,
     832input[type=submit]:hover,
     833input[type=button]:hover,
    834834input[type=reset]:hover,
    835 ul.button-nav li a:hover, 
     835ul.button-nav li a:hover,
    836836ul.button-nav li.current a,
    837837div.generic-button a:hover {
    838838        border-color: #aaa;
     
    846846        color: #bbb;
    847847        cursor: default;
    848848}
    849        
    850 div.pending a:hover, 
    851 a.disabled:hover { 
    852         border-color: #eee; 
    853         color: #bbb; 
     849
     850div.pending a:hover,
     851a.disabled:hover {
     852        border-color: #eee;
     853        color: #bbb;
    854854}
    855855
    856 div.accept, 
     856div.accept,
    857857div.reject {
    858858        float: left;
    859859        margin-left: 10px;
     
    863863        float: left;
    864864        margin: 0 10px 10px 0;
    865865}
    866        
     866
    867867ul.button-nav li.current a {
    868868        font-weight: bold;
    869869}
     
    887887/* > Input Forms
    888888-------------------------------------------------------------- */
    889889
    890 form.standard-form textarea, 
     890form.standard-form textarea,
    891891form.standard-form input[type=text],
    892 form.standard-form select, 
     892form.standard-form select,
    893893form.standard-form input[type=password],
    894894.dir-search input[type=text] {
    895895        border: 1px inset #ccc;
     
    901901        font-size: 14px;
    902902        color: #888;
    903903}
    904                
     904
    905905form.standard-form select {
    906906        padding: 3px;
    907907}
     
    910910        margin-bottom: 5px;
    911911}
    912912
    913 form.standard-form label, 
     913form.standard-form label,
    914914form.standard-form span.label {
    915915        display: block;
    916916        font-weight: bold;
    917917        margin: 15px 0 5px 0;
    918918}
    919                
     919
    920920form.standard-form div.checkbox label,
    921921form.standard-form div.radio label {
    922922        font-weight: normal;
     
    932932form.standard-form input[type=text] {
    933933        width: 75%;
    934934}
    935                
     935
    936936form.standard-form#sidebar-login-form input[type=text],
    937937form.standard-form#sidebar-login-form input[type=password] {
    938938        padding: 4px;
     
    948948form.standard-form#signup_form textarea {
    949949        width: 90%;
    950950}
    951                        
     951
    952952form.standard-form#signup_form div.submit {
    953         float: right; 
     953        float: right;
    954954}
    955955
    956 div#signup-avatar img { 
    957         margin: 0 15px 10px 0; 
     956div#signup-avatar img {
     957        margin: 0 15px 10px 0;
    958958}
    959        
     959
    960960form.standard-form textarea {
    961961        width: 75%;
    962962        height: 120px;
    963963}
    964                
     964
    965965form.standard-form textarea#message_content {
    966966        height: 200px;
    967967}
     
    980980        padding: 15px 0;
    981981        clear: both;
    982982}
    983                
     983
    984984form.standard-form div.submit input {
    985985        margin-right: 15px;
    986986}
     
    989989        margin: 10px 0 15px 38px;
    990990        list-style: disc;
    991991}
    992                
     992
    993993form.standard-form div.radio ul li {
    994994        margin-bottom: 5px;
    995995}
     
    10001000        outline: none;
    10011001}
    10021002
    1003 form.standard-form #basic-details-section, 
     1003form.standard-form #basic-details-section,
    10041004form.standard-form #blog-details-section,
    10051005form.standard-form #profile-details-section {
    10061006        float: left;
    10071007        width: 48%;
    10081008}
    1009        
    1010 form.standard-form #profile-details-section { 
    1011         float: right; 
     1009
     1010form.standard-form #profile-details-section {
     1011        float: right;
    10121012}
    10131013
    10141014form.standard-form #blog-details-section {
    10151015        clear: left;
    10161016}
    10171017
    1018 form.standard-form input:focus, 
    1019 form.standard-form textarea:focus, 
     1018form.standard-form input:focus,
     1019form.standard-form textarea:focus,
    10201020form.standard-form select:focus {
    10211021        background: #fafafa;
    10221022        color: #555;
     
    10251025form#send-invite-form {
    10261026        margin-top: 20px;
    10271027}
    1028        
     1028
    10291029div#invite-list {
    10301030        height: 400px;
    10311031        overflow: scroll;
     
    10461046table {
    10471047        width: 100%;
    10481048}
    1049        
     1049
    10501050table thead tr {
    10511051        background: #eaeaea;
    10521052}
     
    10571057}
    10581058
    10591059table.profile-fields {
    1060         margin-bottom: 20px; 
     1060        margin-bottom: 20px;
    10611061}
    10621062
    10631063div#sidebar table {
     
    10691069        padding: 8px;
    10701070        vertical-align: middle;
    10711071}
    1072                
     1072
    10731073table tr td.label {
    10741074        border-right: 1px solid #eaeaea;
    10751075        font-weight: bold;
    10761076        width: 25%;
    10771077}
    1078                
    1079 table tr td.thread-info p { 
    1080         margin: 0; 
     1078
     1079table tr td.thread-info p {
     1080        margin: 0;
    10811081}
    10821082
    10831083table tr td.thread-info p.thread-excerpt {
     
    10851085        font-size: 11px;
    10861086        margin-top: 3px;
    10871087}
    1088        
     1088
    10891089div#sidebar table td,
    1090 table.forum td { 
    1091         text-align: center; 
     1090table.forum td {
     1091        text-align: center;
    10921092}
    10931093
    10941094table tr.alt {
     
    10991099        margin-bottom: 20px;
    11001100        text-align: left;
    11011101}
    1102        
    1103 table.notification-settings th.icon, 
    1104 table.notification-settings td:first-child { 
    1105         display: none; 
     1102
     1103table.notification-settings th.icon,
     1104table.notification-settings td:first-child {
     1105        display: none;
    11061106}
    11071107
    1108 table.notification-settings th.title { 
    1109         width: 80%; 
     1108table.notification-settings th.title {
     1109        width: 80%;
    11101110}
    1111        
    1112 table.notification-settings .yes, 
    1113 table.notification-settings .no { 
    1114         width: 40px; 
    1115         text-align: center; 
     1111
     1112table.notification-settings .yes,
     1113table.notification-settings .no {
     1114        width: 40px;
     1115        text-align: center;
    11161116}
    11171117
    11181118table.forum {
    11191119        margin: -9px -20px 20px -20px;
    11201120        width: auto;
    11211121}
    1122        
     1122
    11231123table.forum tr.sticky td {
    11241124        background: #fff9db;
    11251125        border-top: 1px solid #ffe8C4;
     
    11381138        font-size: 11px;
    11391139}
    11401140
    1141 table.forum tr > td:first-child, 
     1141table.forum tr > td:first-child,
    11421142table.forum tr > th:first-child {
    11431143        padding-left: 15px;
    11441144}
    11451145
    1146 table.forum tr > td:last-child, 
     1146table.forum tr > td:last-child,
    11471147table.forum tr > th:last-child {
    11481148        padding-right: 15px;
    11491149}
    11501150
    1151 table.forum tr th#th-title, 
     1151table.forum tr th#th-title,
    11521152table.forum tr th#th-poster,
    1153 table.forum tr th#th-group, 
     1153table.forum tr th#th-group,
    11541154table.forum td.td-poster,
    1155 table.forum td.td-group, 
    1156 table.forum td.td-title { 
    1157         text-align: left; 
     1155table.forum td.td-group,
     1156table.forum td.td-title {
     1157        text-align: left;
    11581158}
    11591159
    11601160table.forum td.td-freshness {
     
    12261226        -webkit-border-radius: 3px;
    12271227        border-radius: 3px;
    12281228}
    1229        
     1229
    12301230form#whats-new-form textarea {
    12311231        width: 100%;
    12321232        height: 50px;
     
    12701270        min-height: 35px;
    12711271        padding: 12px 0 0 0;
    12721272}
    1273        
     1273
    12741274.activity-list li.mini div.activity-meta {
    12751275        margin: 0;
    12761276}
     
    12851285        height: 20px;
    12861286        margin-left: 36px;
    12871287}
    1288                
     1288
    12891289.activity-list li.activity_comment .activity-avatar img.avatar,
    12901290.activity-list li.activity_comment .activity-avatar img.FB_profile_pic {
    12911291        width: 40px;
     
    13131313        position: absolute;
    13141314        right: 0;
    13151315}
    1316        
     1316
    13171317body.activity-permalink .activity-list li.mini .activity-meta {
    13181318        position: absolute;
    13191319        right: 15px;
     
    13331333        padding-left: 25px;
    13341334        background: url( ../images/replyto_arrow.gif ) 7px 0 no-repeat;
    13351335}
    1336        
     1336
    13371337.activity-list li .activity-inreplyto > p {
    13381338        margin: 0;
    13391339        display: inline;
     
    13531353        width: 50px;
    13541354        height: 50px;
    13551355}
    1356                
     1356
    13571357body.activity-permalink .activity-list .activity-avatar img {
    13581358        width: 100px;
    13591359        height: 100px;
     
    13621362.activity-list .activity-content {
    13631363        margin-left: 70px;
    13641364}
    1365        
     1365
    13661366body.activity-permalink .activity-list li .activity-content {
    13671367        -moz-border-radius: 4px;
    13681368        -webkit-border-radius: 4px;
     
    13771377        min-height: 35px;
    13781378        margin-right: 0;
    13791379}
    1380        
     1380
    13811381body.activity-permalink .activity-list li .activity-header > p {
    13821382        background: url( ../images/activity_arrow.gif ) top left no-repeat;
    13831383        margin-left: -35px;
     
    13921392        color: #888;
    13931393        line-height: 220%;
    13941394}
    1395        
     1395
    13961396.activity-list .activity-content .activity-header img.avatar {
    13971397        float: none !important;
    13981398        margin: 0 5px -8px 0 !important;
     
    14111411        border-radius: 4px;
    14121412        margin-right: 3px;
    14131413}
    1414        
     1414
    14151415.activity-list .activity-header a:first-child:hover {
    14161416        background: #059ae7 !important;
    14171417        color: #fff !important;
    14181418}
    1419                
    1420 .activity-list .activity-content a:first-child:focus { 
    1421         outline: none; 
     1419
     1420.activity-list .activity-content a:first-child:focus {
     1421        outline: none;
    14221422}
    14231423
    14241424.activity-list .activity-content span.time-since {
     
    14341434        color: #aaa;
    14351435        text-decoration: underline;
    14361436}
    1437                
     1437
    14381438.activity-list .activity-content span.activity-header-meta a:hover {
    14391439        color: inherit;
    14401440        text-decoration: none;
     
    14451445        margin: 15px 0 15px 5px;
    14461446        overflow: hidden;
    14471447}
    1448                
     1448
    14491449body.activity-permalink .activity-content .activity-inner,
    14501450body.activity-permalink .activity-content blockquote {
    14511451        margin-top: 5px;
    14521452}
    14531453
    14541454/* Backwards compatibility. */
    1455 .activity-inner > .activity-inner { 
    1456         margin: 0 !important; 
     1455.activity-inner > .activity-inner {
     1456        margin: 0 !important;
    14571457}
    1458                
    1459 .activity-inner > blockquote { 
    1460         margin: 0 !important; 
     1458
     1459.activity-inner > blockquote {
     1460        margin: 0 !important;
    14611461}
    14621462
    14631463.activity-list .activity-content img.thumbnail {
     
    14781478        -webkit-border-radius: 4px;
    14791479        border-radius: 4px;
    14801480}
    1481        
     1481
    14821482.activity-list li.load-more a {
    14831483        color: #555;
    14841484}
     
    15051505        border-radius: 4px;
    15061506        margin-right: 3px;
    15071507}
    1508        
     1508
    15091509.activity-list div.activity-meta a.acomment-reply {
    15101510        background: #fff9db;
    15111511        border-bottom: 1px solid #ffe8c4;
     
    15131513        color: #ffa200;
    15141514}
    15151515
    1516 div.activity-meta a:focus { 
    1517         outline: none; 
     1516div.activity-meta a:focus {
     1517        outline: none;
    15181518}
    1519        
     1519
    15201520div.activity-meta a:hover {
    15211521        background: #aaa;
    15221522        color: #fff;
    15231523        border-color: #aaa;
    15241524}
    1525                
     1525
    15261526div.activity-meta a.acomment-reply:hover {
    15271527        background: #f7740a;
    15281528        color: #fff;
     
    15621562        border-top: 2px solid #fff;
    15631563        padding: 10px 0 0;
    15641564}
    1565                
     1565
    15661566body.activity-permalink .activity-list li.mini .activity-comments {
    15671567        clear: none;
    15681568        margin-top: 0;
     
    15891589        margin-top: 0;
    15901590        margin-left: 20px;
    15911591}
    1592                
     1592
    15931593body.activity-permalink div.activity-comments ul li > ul {
    15941594        margin-top: 15px;
    15951595}
     
    16051605        margin-left: 39px;
    16061606        margin-top: 5px;
    16071607}
    1608                
    1609 div.acomment-content .time-since { 
    1610         display: none; 
     1608
     1609div.acomment-content .time-since {
     1610        display: none;
    16111611}
    16121612
    1613 div.acomment-content .activity-delete-link { 
    1614         display: none; 
     1613div.acomment-content .activity-delete-link {
     1614        display: none;
    16151615}
    1616                
    1617 div.acomment-content .comment-header { 
    1618         display: none; 
     1616
     1617div.acomment-content .comment-header {
     1618        display: none;
    16191619}
    16201620
    16211621body.activity-permalink div.activity-comments div.acomment-content {
     
    16371637        border-radius: 4px;
    16381638        padding: 8px;
    16391639}
    1640                
     1640
    16411641div.activity-comments li form.ac-form {
    16421642        margin-right: 15px;
    16431643}
     
    16561656        background-position: 2% 95%;
    16571657        background-repeat: no-repeat;
    16581658}
    1659        
     1659
    16601660div.activity-comments form .ac-textarea {
    16611661        padding: 8px;
    16621662        border: 1px inset #ccc;
     
    16661666        -webkit-border-radius: 3px;
    16671667        border-radius: 3px;
    16681668}
    1669                        
     1669
    16701670div.activity-comments form textarea {
    16711671        width: 100%;
    16721672        font-family: inherit;
     
    16761676        border: none;
    16771677        padding: 0;
    16781678}
    1679                                
     1679
    16801680div.activity-comments form input {
    16811681        margin-top: 5px;
    16821682}
     
    16841684div.activity-comments form div.ac-reply-avatar {
    16851685        float: left;
    16861686}
    1687                        
     1687
    16881688div.ac-reply-avatar img {
    16891689        border: 2px solid #fff !important;
    16901690}
     
    17111711        background: #fff;
    17121712}
    17131713
    1714 li span.unread-count, 
     1714li span.unread-count,
    17151715tr.unread span.unread-count {
    17161716        background: #dd0000;
    17171717        padding: 2px 8px;
     
    17211721        -webkit-border-radius: 3px;
    17221722        border-radius: 3px;
    17231723}
    1724                
     1724
    17251725div.item-list-tabs ul li a span.unread-count {
    17261726        padding: 1px 6px;
    17271727        color: #fff;
     
    17391739        margin: 0 -20px;
    17401740        padding: 15px;
    17411741}
    1742        
     1742
    17431743div#message-thread div.alt {
    17441744        background: #f4f4f4;
    17451745}
     
    17581758        margin: 0;
    17591759        font-size: 16px;
    17601760}
    1761                
     1761
    17621762div#message-thread strong a {
    17631763        text-decoration: none;
    17641764}
     
    18131813        color: #888;
    18141814        font-size: 11px;
    18151815}
    1816        
     1816
    18171817div#topic-meta div.admin-links {
    18181818        bottom: 0;
    18191819        right: 0;
     
    18241824        position: relative;
    18251825        padding: 5px 0;
    18261826}
    1827        
     1827
    18281828div#topic-meta h3 {
    1829         font-size: 20px;       
     1829        font-size: 20px;
    18301830}
    18311831
    18321832div#new-topic-post {
     
    18431843        overflow: hidden;
    18441844}
    18451845
    1846 div.post h2.pagetitle, 
     1846div.post h2.pagetitle,
    18471847div.post h2.posttitle {
    18481848        margin: 0;
    18491849        line-height: 120%;
    18501850}
    1851                
    1852 div.post h2.pagetitle a, 
     1851
     1852div.post h2.pagetitle a,
    18531853div.post h2.posttitle a {
    18541854        color: #666;
    18551855        text-decoration: none;
    18561856}
    18571857
    1858 .navigation, 
    1859 .paged-navigation, 
     1858.navigation,
     1859.paged-navigation,
    18601860.comment-navigation {
    18611861        overflow: hidden;
    18621862        font-family: georgia, times, serif;
     
    18761876        margin-right: 15px;
    18771877}
    18781878
    1879 div.post p { 
    1880         margin: 0 0 20px 0; 
     1879div.post p {
     1880        margin: 0 0 20px 0;
    18811881}
    18821882
    1883 div.post ul, 
    1884 div.post ol, 
    1885 div.post dl { 
    1886         margin: 0 0 18px 1.5em; 
     1883div.post ul,
     1884div.post ol,
     1885div.post dl {
     1886        margin: 0 0 18px 1.5em;
    18871887}
    1888        
     1888
    18891889div.post ul {
    1890         list-style: square; 
     1890        list-style: square;
    18911891}
    1892        
    1893 div.post ol { 
     1892
     1893div.post ol {
    18941894        list-style: decimal;
    18951895}
    1896        
    1897 div.post ol ol { 
    1898         list-style: upper-alpha; 
     1896
     1897div.post ol ol {
     1898        list-style: upper-alpha;
    18991899}
    1900        
    1901 div.post dl { 
    1902         margin-left: 0; 
     1900
     1901div.post dl {
     1902        margin-left: 0;
    19031903}
    1904        
    1905 div.post dt { 
    1906         font-size: 14px; 
    1907         font-weight: bold; 
     1904
     1905div.post dt {
     1906        font-size: 14px;
     1907        font-weight: bold;
    19081908}
    1909        
    1910 div.post dd { 
     1909
     1910div.post dd {
    19111911        margin: 0 0 15px 0;
    19121912}
    19131913
    1914 div.post pre, 
     1914div.post pre,
    19151915div.post code p {
    19161916        padding: 15px;
    19171917        background: #f4f4f4;
     
    19211921}
    19221922
    19231923div.post code {
    1924         font-family: "Monaco", courier, sans-serif; 
     1924        font-family: "Monaco", courier, sans-serif;
    19251925}
    19261926
    19271927div.post blockquote {
     
    19381938        border-spacing:0;
    19391939        border: 1px solid #eee;
    19401940}
    1941                
     1941
    19421942div.post table th {
    1943         border-top: 1px solid #eee; 
    1944         text-align: left; 
     1943        border-top: 1px solid #eee;
     1944        text-align: left;
    19451945}
    1946                
    1947 div.post table td { 
    1948         border-top: 1px solid #eee; 
     1946
     1947div.post table td {
     1948        border-top: 1px solid #eee;
    19491949}
    1950        
    1951 div.post div.author-box, 
     1950
     1951div.post div.author-box,
    19521952div.comment-avatar-box {
    19531953        background: #f0f0f0;
    19541954        padding: 10px;
     
    19621962        -webkit-border-radius: 3px;
    19631963        border-radius: 3px;
    19641964}
    1965                
    1966 div.author-box p, 
    1967 div.comment-avatar-box p { 
    1968         margin: 5px 0 0; 
     1965
     1966div.author-box p,
     1967div.comment-avatar-box p {
     1968        margin: 5px 0 0;
    19691969}
    1970                
    1971 div.author-box a, 
    1972 div.comment-avatar-box a { 
    1973         text-decoration: none; 
     1970
     1971div.author-box a,
     1972div.comment-avatar-box a {
     1973        text-decoration: none;
    19741974}
    19751975
    1976 div.post div.author-box img, 
     1976div.post div.author-box img,
    19771977div.comment-avatar-box img {
    19781978        float: none;
    19791979        border: 4px solid #fff;
    19801980        margin: 0;
    19811981}
    19821982
    1983 div.post div.post-content, 
     1983div.post div.post-content,
    19841984div.comment-content {
    19851985        margin-left: 105px;
    19861986}
    19871987
    1988 div.post p.date, div.post p.postmetadata, 
     1988div.post p.date, div.post p.postmetadata,
    19891989div.comment-meta, div.comment-options {
    19901990        color: #888;
    19911991        font-size: 12px;
     
    20022002        overflow: hidden;
    20032003}
    20042004
    2005 div.post .tags { 
    2006         float: left; 
     2005div.post .tags {
     2006        float: left;
    20072007}
    20082008
    2009 div.post .comments { 
    2010         float: right; 
     2009div.post .comments {
     2010        float: right;
    20112011}
    20122012
    2013 div.post img { 
    2014         margin-bottom: 15px; 
     2013div.post img {
     2014        margin-bottom: 15px;
    20152015}
    20162016
    2017 div.post img.wp-smiley { 
    2018         padding: 0 !important; 
    2019         margin: 0 !important; 
    2020         border: none !important; 
    2021         float: none !important; 
    2022         clear: none !important; 
     2017div.post img.wp-smiley {
     2018        padding: 0 !important;
     2019        margin: 0 !important;
     2020        border: none !important;
     2021        float: none !important;
     2022        clear: none !important;
    20232023}
    20242024
    20252025div.post img.centered, img.aligncenter {
     
    20402040        display: inline;
    20412041}
    20422042
    2043 div.post .aligncenter, 
     2043div.post .aligncenter,
    20442044div.post div.aligncenter {
    20452045        display: block;
    20462046        margin-left: auto;
     
    20632063        border: 0 none;
    20642064}
    20652065
    2066 div.post dd.wp-caption p.wp-caption-text, 
     2066div.post dd.wp-caption p.wp-caption-text,
    20672067div.post .wp-caption p.wp-caption-text {
    20682068        font-size: 0.9em;
    20692069        line-height: 17px;
     
    20822082        margin-top: 30px;
    20832083}
    20842084
    2085 #comments h3, 
    2086 #trackbacks h3, 
     2085#comments h3,
     2086#trackbacks h3,
    20872087#respond h3 {
    20882088        font-size: 20px;
    20892089        margin: 5px 0 25px 0;
     
    20912091        color: #555;
    20922092}
    20932093
    2094 #comments span.title, 
     2094#comments span.title,
    20952095#trackbacks span.title {
    20962096        color: #aaa;
    20972097}
     
    21172117        border-bottom: none;
    21182118}
    21192119
    2120 ol.commentlist ul.children { 
    2121         margin-left: 105px; 
     2120ol.commentlist ul.children {
     2121        margin-left: 105px;
    21222122}
    21232123
    21242124
     
    21352135        border-bottom: 1px solid #e0e0e0;
    21362136        background: #fff;
    21372137}
    2138        
     2138
    21392139#site-generator {
    21402140        text-align: center;
    21412141        color: #bbb;
     
    21622162        background: #eaeaea;
    21632163        padding: 5px 15px;
    21642164        font-size: 12px;
    2165         clear: left;   
     2165        clear: left;
    21662166}
    21672167
    21682168#footer-widget-area div div.item-options {
     
    21842184        z-index: 99999;
    21852185        right: 0;
    21862186}
    2187        
     2187
    21882188#nav li:hover > ul {
    21892189        display: block;
    21902190}
  • bp-themes/bp-default/_inc/ajax.php

     
    567567        // Include everyone in the autocomplete, or just friends?
    568568        if ( $bp->messages->slug == $bp->current_component )
    569569                $autocomplete_all = $bp->messages->autocomplete_all;
    570        
     570
    571571        $friends = false;
    572572
    573573        $limit = $_GET['limit'] ? $_GET['limit'] : apply_filters( 'bp_autocomplete_max_results', 10 );
     
    575575        // Get the user ids based on the search terms
    576576        if ( $autocomplete_all ) {
    577577                $users = BP_Core_User::search_users( $_GET['q'], $limit, $pag_page );
    578                
     578
    579579                if ( !empty( $users['users'] ) ) {
    580580                        // Build an array with the correct format
    581581                        $user_ids = array();
     
    583583                                if ( $user->id != $bp->loggedin_user->id )
    584584                                        $user_ids[] = $user->id;
    585585                        }
    586                        
     586
    587587                        $user_ids = apply_filters( 'bp_core_autocomplete_ids', $user_ids, $_GET['q'], $limit );
    588588                }
    589589        } else {
    590590                if ( function_exists( 'friends_search_friends' ) ) {
    591591                        $users = friends_search_friends( $_GET['q'], $bp->loggedin_user->id, $limit, 1 );
    592                        
     592
    593593                        // Keeping the bp_friends_autocomplete_list filter for backward compatibility
    594594                        $users = apply_filters( 'bp_friends_autocomplete_list', $users, $_GET['q'], $limit );
    595                        
     595
    596596                        if ( !empty( $users['friends'] ) )
    597597                                $user_ids = apply_filters( 'bp_friends_autocomplete_ids', $users['friends'], $_GET['q'], $limit );
    598598                }
    599599        }
    600        
    601600
     601
    602602        if ( $user_ids ) {
    603603                foreach ( $user_ids as $user_id ) {
    604604                        $ud = get_userdata($user_id);
  • bp-themes/bp-default/_inc/global.js

     
    824824        }).mouseout( function() {
    825825                jq(this).removeClass('over');
    826826        });
    827                
     827
    828828        jq('body#bp-default table.zebra tbody tr:odd').addClass('alt');
    829829
    830830        jq('div.message-box').each( function(i) {
  • bp-themes/bp-default/registration/register.php

     
    162162                                        <?php do_action( 'bp_after_signup_profile_fields' ) ?>
    163163
    164164                                <?php endif; ?>
    165                                
     165
    166166                                <?php if ( bp_get_blog_signup_allowed() ) : ?>
    167167
    168168                                        <?php do_action( 'bp_before_blog_details_fields' ) ?>
  • bp-themes/bp-default/forums/index.php

     
    115115                        <?php do_action( 'bp_after_directory_forums_content' ) ?>
    116116
    117117                </form>
    118                
     118
    119119                <?php do_action( 'bp_after_directory_forums' ) ?>
    120120
    121121                </div><!-- .padder -->
  • bp-themes/bp-default/comments.php

     
    1818                                $numTrackBacks = 0; $numComments = 0;
    1919                                foreach ( (array)$comments as $comment )
    2020                                        if ( 'comment' != get_comment_type() )
    21                                                 $numTrackBacks++; 
     21                                                $numTrackBacks++;
    2222                                        else
    2323                                                $numComments++;
    2424                        ?>
  • bp-xprofile/admin/js/admin.dev.js

     
    1212
    1313        var label = document.createElement('label');
    1414        label.setAttribute('for', forWhat + '_option' + theId);
    15        
     15
    1616        var txt = document.createTextNode("Option " + theId + ": ");
    1717        label.appendChild(txt);
    18        
     18
    1919        var isDefault = document.createElement('input');
    20        
     20
    2121        if(forWhat == 'checkbox' || forWhat == 'multiselectbox') {
    2222                isDefault.setAttribute('type', 'checkbox');
    2323                isDefault.setAttribute('name', 'isDefault_' + forWhat + '_option[' + theId + ']');
    2424        } else {
    2525                isDefault.setAttribute('type', 'radio');
    26                 isDefault.setAttribute('name', 'isDefault_' + forWhat + '_option');                                     
     26                isDefault.setAttribute('name', 'isDefault_' + forWhat + '_option');
    2727        }
    28        
     28
    2929        isDefault.setAttribute('value', theId);
    30        
     30
    3131        var label1 = document.createElement('label');
    3232        var txt1 = document.createTextNode(" Default Value ");
    33        
     33
    3434        label1.appendChild(txt1);
    3535        label1.setAttribute('for', 'isDefault_' + forWhat + '_option[]');
    3636        toDelete = document.createElement('a');
    37        
     37
    3838        toDeleteText = document.createTextNode('[x]');
    3939        toDelete.setAttribute('href',"javascript:hide('" + forWhat + '_div' + theId + "')");
    40        
     40
    4141        toDelete.setAttribute('class','delete');
    4242
    4343        toDelete.appendChild(toDeleteText);
     
    4646        newDiv.appendChild(newOption);
    4747        newDiv.appendChild(document.createTextNode(" "));
    4848        newDiv.appendChild(isDefault);
    49         newDiv.appendChild(label1);     
    50         newDiv.appendChild(toDelete);   
     49        newDiv.appendChild(label1);
     50        newDiv.appendChild(toDelete);
    5151        holder.appendChild(newDiv);
    52        
    53        
     52
     53
    5454        theId++
    5555        document.getElementById(forWhat + "_option_number").value = theId;
    5656}
     
    6060        document.getElementById("selectbox").style.display = "none";
    6161        document.getElementById("multiselectbox").style.display = "none";
    6262        document.getElementById("checkbox").style.display = "none";
    63        
     63
    6464        if(forWhat == "radio")
    6565                document.getElementById("radio").style.display = "";
    66        
     66
    6767        if(forWhat == "selectbox")
    68                 document.getElementById("selectbox").style.display = "";                                               
    69        
     68                document.getElementById("selectbox").style.display = "";
     69
    7070        if(forWhat == "multiselectbox")
    71                 document.getElementById("multiselectbox").style.display = "";                                           
    72        
     71                document.getElementById("multiselectbox").style.display = "";
     72
    7373        if(forWhat == "checkbox")
    74                 document.getElementById("checkbox").style.display = "";                                         
     74                document.getElementById("checkbox").style.display = "";
    7575}
    7676
    7777function hide(id) {
    7878        if ( !document.getElementById(id) ) return false;
    79        
     79
    8080        document.getElementById(id).style.display = "none";
    8181        document.getElementById(id).value = '';
    8282}
    8383
    8484// Set up deleting options ajax
    8585jQuery(document).ready( function() {
    86        
    87         jQuery("a.ajax-option-delete").click( 
     86
     87        jQuery("a.ajax-option-delete").click(
    8888                function() {
    8989                        var theId = this.id.split('-');
    9090                        theId = theId[1];
    91                        
     91
    9292                        jQuery.post( ajaxurl, {
    9393                                action: 'xprofile_delete_option',
    9494                                'cookie': encodeURIComponent(document.cookie),
    9595                                '_wpnonce': jQuery("input#_wpnonce").val(),
    96                                
     96
    9797                                'option_id': theId
    9898                        },
    9999                        function(response)
    100100                        {});
    101101                }
    102         );                             
     102        );
    103103});
    104104
    105105var fixHelper = function(e, ui) {
     
    160160        .css( 'cursor', 'move' );
    161161
    162162        /* tabs init with a custom tab template and an "add" callback filling in the content */
    163         var $tab_items; 
     163        var $tab_items;
    164164        var $tabs = jQuery( "#tabs" ).tabs();
    165165        set_tab_items( $tabs );
    166166
  • bp-xprofile/bp-xprofile-classes.php

     
    760760        function exists() {
    761761                global $wpdb, $bp;
    762762
    763                
     763
    764764                $retval = $wpdb->get_row( $wpdb->prepare( "SELECT id FROM {$bp->profile->table_name_data} WHERE user_id = %d AND field_id = %d", $this->user_id, $this->field_id ) );
    765765
    766766                return apply_filters( 'xprofile_data_exists', (bool)$retval, $this );
  • bp-core/bp-core-signup.php

     
    1515                return false;
    1616
    1717        $bp->is_directory = false;
    18        
     18
    1919        if ( bp_is_component_front_page( 'register' ) && ( is_user_logged_in() || !bp_get_signup_allowed() ) )
    2020                bp_core_redirect( $bp->root_domain . '/' . $bp->members->slug );
    2121
     
    325325
    326326        if ( defined( 'BP_ACTIVATION_SLUG' ) )
    327327                $bp_component_slugs[] = BP_ACTIVATION_SLUG;
    328        
     328
    329329        // Add our slugs to the array and allow them to be filtered
    330330        $filtered_illegal_names = apply_filters( 'bp_core_illegal_usernames', array_merge( array( 'www', 'web', 'root', 'admin', 'main', 'invite', 'administrator' ), $bp_component_slugs ) );
    331331
     
    634634        $message = apply_filters( 'bp_core_activation_signup_user_notification_message', $message, $user_id );
    635635
    636636        wp_mail( $to, $subject, $message, $message_headers );
    637        
     637
    638638        do_action( 'bp_core_sent_user_validation_email', $admin_email, $subject, $message, $user_id, $user_email, $key );
    639639}
    640640
  • bp-core/bp-core-widgets.php

     
    6363                                                                <span class="activity">
    6464                                                                <?php
    6565                                                                        if ( 'newest' == $instance['member_default'] )
    66                                                                                 bp_member_registered();                                                         
     66                                                                                bp_member_registered();
    6767                                                                        if ( 'active' == $instance['member_default'] )
    6868                                                                                bp_member_last_active();
    6969                                                                        if ( 'popular' == $instance['member_default'] )
     
    107107                        'member_default' => 'active'
    108108                );
    109109                $instance = wp_parse_args( (array) $instance, $defaults );
    110                
     110
    111111                $title = strip_tags( $instance['title'] );
    112112                $max_members = strip_tags( $instance['max_members'] );
    113113                $member_default = strip_tags( $instance['member_default'] );
     
    116116                <p><label for="bp-core-widget-title"><?php _e('Title:', 'buddypress'); ?> <input class="widefat" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" type="text" value="<?php echo esc_attr( $title ); ?>" style="width: 100%" /></label></p>
    117117
    118118                <p><label for="bp-core-widget-members-max"><?php _e('Max members to show:', 'buddypress'); ?> <input class="widefat" id="<?php echo $this->get_field_id( 'max_members' ); ?>" name="<?php echo $this->get_field_name( 'max_members' ); ?>" type="text" value="<?php echo esc_attr( $max_members ); ?>" style="width: 30%" /></label></p>
    119                                
     119
    120120                <p>
    121                         <label for="bp-core-widget-groups-default"><?php _e('Default members to show:', 'buddypress'); ?> 
     121                        <label for="bp-core-widget-groups-default"><?php _e('Default members to show:', 'buddypress'); ?>
    122122                        <select name="<?php echo $this->get_field_name( 'member_default' ) ?>">
    123123                                <option value="newest" <?php if ( $member_default == 'newest' ) : ?>selected="selected"<?php endif; ?>><?php _e( 'Newest', 'buddypress' ) ?></option>
    124124                                <option value="active" <?php if ( $member_default == 'active' ) : ?>selected="selected"<?php endif; ?>><?php _e( 'Active', 'buddypress' ) ?></option>
    125125                                <option value="popular"  <?php if ( $member_default == 'popular' ) : ?>selected="selected"<?php endif; ?>><?php _e( 'Popular', 'buddypress' ) ?></option>
    126                         </select>                       
     126                        </select>
    127127                        </label>
    128128                </p>
    129        
     129
    130130        <?php
    131131        }
    132132}
     
    183183                        'max_members' => 15
    184184                );
    185185                $instance = wp_parse_args( (array) $instance, $defaults );
    186                
     186
    187187                $title = strip_tags( $instance['title'] );
    188188                $max_members = strip_tags( $instance['max_members'] );
    189189                ?>
     
    247247                        'max_members' => 15
    248248                );
    249249                $instance = wp_parse_args( (array) $instance, $defaults );
    250                
     250
    251251                $title = strip_tags( $instance['title'] );
    252252                $max_members = strip_tags( $instance['max_members'] );
    253253                ?>
     
    298298                                                <?php if ( 'active' == $type ) : ?>
    299299                                                        <div class="item-meta"><span class="activity"><?php bp_member_last_active() ?></span></div>
    300300                                                <?php elseif ( 'newest' == $type ) : ?>
    301                                                         <div class="item-meta"><span class="activity"><?php bp_member_registered() ?></span></div> 
     301                                                        <div class="item-meta"><span class="activity"><?php bp_member_registered() ?></span></div>
    302302                                                <?php elseif ( bp_is_active( 'friends' ) ) : ?>
    303303                                                        <div class="item-meta"><span class="activity"><?php bp_member_total_friend_count() ?></span></div>
    304304                                                <?php endif; ?>
  • bp-core/bp-core-filters.php

     
    205205        $message = apply_filters( 'bp_core_activation_signup_blog_notification_message', $message, $domain, $path, $title, $user, $user_email, $key, $meta );
    206206
    207207        wp_mail( $to, $subject, $message, $message_headers );
    208        
     208
    209209        do_action( 'bp_core_sent_blog_signup_email', $admin_email, $subject, $message, $domain, $path, $title, $user, $user_email, $key, $meta );
    210210
    211211        // Return false to stop the original WPMU function from continuing
  • bp-core/admin/bp-core-upgrade.php

     
    99
    1010// Install site options on activation
    1111bp_core_activate_site_options( array( 'bp-disable-account-deletion' => 0, 'bp-disable-avatar-uploads' => 0, 'bp-disable-blogforum-comments' => 0,  'bp-disable-forum-directory' => 0,  'bp-disable-profile-sync' => 0 ) );
    12  
     12
    1313/**
    1414 * bp_core_activate_site_options()
    1515 *
     
    5555                if ( !$this->current_version = get_site_option( 'bp-db-version' ) )
    5656                        if ( $this->current_version = get_option( 'bp-db-version' ) )
    5757                                $this->is_network_activate = true;
    58                
     58
    5959                $this->new_version = constant( 'BP_DB_VERSION' );
    6060                $this->setup_type = ( empty( $this->current_version ) && !(int)get_site_option( 'bp-core-db-version' ) ) ? 'new' : 'upgrade';
    6161                $this->current_step = $this->current_step();
     
    103103                        }
    104104                } else {
    105105                        // Upgrade wizard steps
    106                        
     106
    107107                        if ( $this->is_network_activate )
    108108                                $steps[] = __( 'Multisite Upgrade', 'buddypress' );
    109                        
     109
    110110                        if ( $this->current_version < $this->new_version )
    111111                                $steps[] = __( 'Database Upgrade', 'buddypress' );
    112112
     
    242242                </div>
    243243        <?php
    244244        }
    245        
     245
    246246        function step_ms_upgrade() {
    247247                if ( !current_user_can( 'activate_plugins' ) )
    248248                        return false;
     
    251251                        $blogs_slug = constant( 'BP_BLOGS_SLUG' );
    252252                else
    253253                        $blogs_slug = __( 'blogs', 'buddypress' );
    254                
     254
    255255                if ( !defined( 'BP_ENABLE_MULTIBLOG' ) && is_multisite() )
    256256                        $existing_pages = get_blog_option( BP_ROOT_BLOG, 'bp-pages' );
    257257                else
     
    261261                <div class="prev-next submit clear">
    262262                        <p><input type="submit" value="<?php _e( 'Save &amp; Next &rarr;', 'buddypress' ) ?>" name="submit" /></p>
    263263                </div>
    264                
     264
    265265                <p><?php printf( __( 'It looks like you have just activated WordPress Multisite mode, which allows members of your BuddyPress community to have their own WordPress blogs. You can enable or disable this feature at any time at <a href="%s">Network Options</a>.', 'buddypress' ), admin_url( 'ms-options.php' ) ); ?></p>
    266                
     266
    267267                <p><?php _e( "Please select the WordPress page you would like to use to display the blog directory. You can either choose an existing page or let BuddyPress auto-create a page for you. If you'd like to manually create pages, please go ahead and do that now, you can come back to this step once you are finished.", 'buddypress' ) ?></p>
    268268
    269269                <p><strong><?php _e( 'Please Note:', 'buddypress' ) ?></strong> <?php _e( "If you have manually added BuddyPress navigation links in your theme you may need to remove these from your header.php to avoid duplicate links.", 'buddypress' ) ?></p>
     
    280280                                        <p><input type="radio" name="bp_pages[blogs]" checked="checked" value="<?php echo $blogs_slug ?>" /> <?php _e( 'Automatically create a page at:', 'buddypress' ) ?> <?php echo site_url( $blogs_slug ) ?>/</p>
    281281                                </td>
    282282                        </tr>
    283                        
     283
    284284                </table>
    285                
     285
    286286                <p><?php _e( 'Would you like to enable blog tracking, which tracks blog activity across your network?', 'buddypress' ); ?></p>
    287                
     287
    288288                <div class="left-col">
    289                        
     289
    290290                        <div class="component">
    291291                                <h5><?php _e( "Blog Tracking", 'buddypress' ) ?></h5>
    292292
     
    297297
    298298                                <img src="<?php echo plugins_url( 'buddypress/screenshot-7.gif' ) ?>" alt="Activity Streams" />
    299299                                        <p><?php _e( "Track new blogs, new posts and new comments across your entire blog network.", 'buddypress' ) ?></p>
    300                         </div>         
     300                        </div>
    301301                </div>
    302                
     302
    303303                <div class="submit clear">
    304304                        <p><input type="submit" value="<?php _e( 'Save &amp; Next &rarr;', 'buddypress' ) ?>" name="submit" /></p>
    305305
     
    307307                        <input type="hidden" name="step" value="<?php echo esc_attr( $this->current_step ) ?>" />
    308308                        <?php wp_nonce_field( 'bpwizard_ms_upgrade' ) ?>
    309309                </div>
    310                
     310
    311311                <script type="text/javascript">
    312312                        jQuery('select').click( function() {
    313313                                jQuery(this).parent().children('input').attr( 'checked', 'checked' );
     
    837837                                // Make sure that the pages are created on the BP_ROOT_BLOG, no matter which Dashboard the setup is being run on
    838838                                if ( $current_blog->blog_id != BP_ROOT_BLOG && !defined( 'BP_ENABLE_MULTIBLOG' ) )
    839839                                        switch_to_blog( BP_ROOT_BLOG );
    840        
     840
    841841                                $existing_pages = get_option( 'bp-pages' );
    842842
    843843                                $bp_pages = $this->setup_pages( (array)$_POST['bp_pages'] );
    844                                
     844
    845845                                $bp_pages = array_merge( (array)$existing_pages, (array)$bp_pages );
    846        
     846
    847847                                update_option( 'bp-pages', $bp_pages );
    848848
    849849                                if ( $current_blog->blog_id != BP_ROOT_BLOG )
    850850                                        restore_current_blog();
    851                        
     851
    852852                                unset( $disabled['bp-blogs.php'] );
    853                                
     853
    854854                                bp_core_install( $disabled );
    855855                        }
    856                        
     856
    857857                        update_site_option( 'bp-deactivated-components', $disabled );
    858858
    859859                        return true;
     
    10441044
    10451045                return false;
    10461046        }
    1047        
     1047
    10481048        function setup_pages( $pages ) {
    10491049                foreach ( $pages as $key => $value ) {
    10501050                        if ( 'page' == $value ) {
     
    10581058                                $bp_pages[$key] = wp_insert_post( array( 'post_title' => ucwords( $value ), 'post_status' => 'publish', 'post_type' => 'page' ) );
    10591059                        }
    10601060                }
    1061                
     1061
    10621062                return $bp_pages;
    10631063        }
    10641064
  • bp-core/admin/bp-core-schema.php

     
    227227                            KEY can_delete (can_delete),
    228228                            KEY is_required (is_required)
    229229                           ) {$charset_collate};";
    230                
     230
    231231        $sql[] = "CREATE TABLE {$wpdb->base_prefix}bp_xprofile_data (
    232232                            id bigint(20) unsigned NOT NULL AUTO_INCREMENT PRIMARY KEY,
    233233                            field_id bigint(20) unsigned NOT NULL,
  • bp-core/bp-core-templatetags.php

     
    704704}
    705705        function bp_get_avatar_admin_step() {
    706706                global $bp;
    707                
     707
    708708                if ( isset( $bp->avatar_admin->step ) )
    709709                        $step = $bp->avatar_admin->step;
    710710                else
     
    718718}
    719719        function bp_get_avatar_to_crop() {
    720720                global $bp;
    721                
     721
    722722                if ( isset( $bp->avatar_admin->image->url ) )
    723723                        $url = $bp->avatar_admin->image->url;
    724724                else
     
    10231023        global $bp;
    10241024
    10251025        $options = array();
    1026        
     1026
    10271027        if ( bp_is_active( 'xprofile' ) )
    10281028                $options['members'] = __( 'Members', 'buddypress' );
    10291029
     
    15301530                $path = bp_core_get_site_path();
    15311531        else
    15321532                $path = $current_blog->path;
    1533                
     1533
    15341534        if ( 'page' != get_option( 'show_on_front' ) || !$component || empty( $bp->pages->{$component} ) || $_SERVER['REQUEST_URI'] != $path )
    15351535                return false;
    15361536
  • bp-core/bp-core-classes.php

     
    140140
    141141                if ( 'alphabetical' == $type )
    142142                        $sql['where_alpha'] = "AND pd.field_id = 1";
    143                
     143
    144144                if ( !empty( $exclude ) )
    145145                        $sql['where_exclude'] = "AND u.ID NOT IN ({$exclude})";
    146146
     
    259259
    260260                $total_users_sql = apply_filters( 'bp_core_users_by_letter_count_sql', $wpdb->prepare( "SELECT COUNT(DISTINCT u.ID) FROM " . CUSTOM_USER_TABLE . " u LEFT JOIN {$bp->profile->table_name_data} pd ON u.ID = pd.user_id LEFT JOIN {$bp->profile->table_name_fields} pf ON pd.field_id = pf.id WHERE {$status_sql} AND pf.name = %s {$exclude_sql} AND pd.value LIKE '$letter%%'  ORDER BY pd.value ASC", BP_XPROFILE_FULLNAME_FIELD_NAME ), $letter );
    261261                $paged_users_sql = apply_filters( 'bp_core_users_by_letter_sql', $wpdb->prepare( "SELECT DISTINCT u.ID as id, u.user_registered, u.user_nicename, u.user_login, u.user_email FROM " . CUSTOM_USER_TABLE . " u LEFT JOIN {$bp->profile->table_name_data} pd ON u.ID = pd.user_id LEFT JOIN {$bp->profile->table_name_fields} pf ON pd.field_id = pf.id WHERE {$status_sql} AND pf.name = %s {$exclude_sql} AND pd.value LIKE '$letter%%' ORDER BY pd.value ASC{$pag_sql}", BP_XPROFILE_FULLNAME_FIELD_NAME ), $letter, $pag_sql );
    262                
     262
    263263                $total_users = $wpdb->get_var( $total_users_sql );
    264264                $paged_users = $wpdb->get_results( $paged_users_sql );
    265265
  • bp-core/bp-core-settings.php

     
    2323
    2424        if ( !is_super_admin() && empty( $bp->site_options['bp-disable-account-deletion'] ) )
    2525                bp_core_new_subnav_item( array( 'name' => __( 'Delete Account', 'buddypress' ), 'slug' => 'delete-account', 'parent_url' => $settings_link, 'parent_slug' => $bp->settings->slug, 'screen_function' => 'bp_core_screen_delete_account', 'position' => 90, 'user_has_access' => bp_is_my_profile() ) );
    26        
     26
    2727        do_action( 'bp_core_settings_setup_nav' );
    2828}
    2929add_action( 'bp_setup_nav', 'bp_core_add_settings_nav' );
     
    4444                require_once( WPINC . '/registration.php' );
    4545
    4646                // Form has been submitted and nonce checks out, lets do it.
    47                
     47
    4848                // Validate the user again for the current password when making a big change
    4949                if ( !empty( $_POST['pwd'] ) && $_POST['pwd'] != '' && wp_check_password($_POST['pwd'], $current_user->user_pass, $current_user->ID) ) {
    50  
     50
    5151                        // Make sure changing an email address does not already exist
    5252                        if ( $_POST['email'] != '' ) {
    53  
     53
    5454                                // What is missing from the profile page vs signup - lets double check the goodies
    5555                                $user_email = sanitize_email( wp_specialchars( trim( $_POST['email'] ) ) );
    56  
     56
    5757                                if ( !is_email( $user_email ) )
    5858                                        $email_error = true;
    59  
     59
    6060                                $limited_email_domains = get_site_option( 'limited_email_domains', 'buddypress' );
    61  
     61
    6262                                if ( is_array( $limited_email_domains ) && empty( $limited_email_domains ) == false ) {
    6363                                        $emaildomain = substr( $user_email, 1 + strpos( $user_email, '@' ) );
    64  
     64
    6565                                        if ( in_array( $emaildomain, (array)$limited_email_domains ) == false ) {
    6666                                                $email_error = true;
    67                                                
     67
    6868                                        }
    6969                                }
    70  
     70
    7171                                if ( !$email_error && $current_user->user_email != $user_email  ) {
    72                                
     72
    7373                                        //we don't want email dups in the system
    7474                                        if ( email_exists( $user_email ) )
    7575                                                $email_error = true;
    76                                                
     76
    7777                                        if (!$email_error)
    7878                                                $current_user->user_email = $user_email;
    7979                                }
    8080                        }
    81  
     81
    8282                        if ( $_POST['pass1'] != '' && $_POST['pass2'] != '' ) {
    83                        
     83
    8484                                if ( $_POST['pass1'] == $_POST['pass2'] && !strpos( " " . $_POST['pass1'], "\\" ) )
    8585                                        $current_user->user_pass = $_POST['pass1'];
    8686                                else
    8787                                        $pass_error = true;
    88  
     88
    8989                        } else if ( empty( $_POST['pass1'] ) && !empty( $_POST['pass2'] ) || !empty( $_POST['pass1'] ) && empty( $_POST['pass2'] ) ) {
    9090                                $pass_error = true;
    9191                        } else {
    9292                                unset( $current_user->user_pass );
    9393                        }
    94  
     94
    9595                        if ( !$email_error && !$pass_error && wp_update_user( get_object_vars( $current_user ) ) )
    9696                                $bp_settings_updated = true;
    97                        
     97
    9898                } else {
    9999                        $pwd_error = true;
    100100                }
    101                
     101
    102102                do_action( 'bp_core_general_settings_after_save' );
    103103        }
    104104
     
    126126                        <p><?php _e( 'Your passwords did not match', 'buddypress' ) ?></p>
    127127                </div>
    128128        <?php } ?>
    129        
     129
    130130        <?php if ( $pwd_error && !$bp_settings_updated ) { ?>
    131131                <div id="message" class="error fade">
    132132                        <p><?php _e( 'Your password is incorrect', 'buddypress' ) ?></p>
    133133                </div>
    134134        <?php } ?>
    135135
    136         <?php 
     136        <?php
    137137        if ( $email_error && !$bp_settings_updated ) { ?>
    138138                <div id="message" class="error fade">
    139139                        <p><?php _e( 'Sorry, that email address is already used or is invalid', 'buddypress' ) ?></p>
     
    152152                <label for="pass1"><?php _e( 'Change Password <span>(leave blank for no change)</span>', 'buddypress' ) ?></label>
    153153                <input type="password" name="pass1" id="pass1" size="16" value="" class="settings-input small" /> &nbsp;<?php _e( 'New Password', 'buddypress' ) ?><br />
    154154                <input type="password" name="pass2" id="pass2" size="16" value="" class="settings-input small" /> &nbsp;<?php _e( 'Repeat New Password', 'buddypress' ) ?>
    155                
     155
    156156                <?php do_action( 'bp_core_general_settings_before_submit' ) ?>
    157157
    158158                <div class="submit">
    159159                        <input type="submit" name="submit" value="<?php _e( 'Save Changes', 'buddypress' ) ?>" id="submit" class="auto" />
    160160                </div>
    161                
     161
    162162                <?php do_action( 'bp_core_general_settings_after_submit' ) ?>
    163163
    164164                <?php wp_nonce_field('bp_settings_general') ?>
     
    183183                }
    184184
    185185                $bp_settings_updated = true;
    186                
     186
    187187                do_action( 'bp_core_notification_settings_after_save' );
    188188        }
    189189
     
    216216                </div>
    217217
    218218                <?php do_action( 'bp_core_notification_settings_after_submit' ) ?>
    219                
     219
    220220                <?php wp_nonce_field('bp_settings_notifications') ?>
    221221
    222222        </form>
     
    256256                <input type="checkbox" name="delete-account-understand" id="delete-account-understand" value="1" onclick="if(this.checked) { document.getElementById('delete-account-button').disabled = ''; } else { document.getElementById('delete-account-button').disabled = 'disabled'; }" /> <?php _e( 'I understand the consequences of deleting my account.', 'buddypress' ); ?>
    257257
    258258                <?php do_action( 'bp_core_delete_account_before_submit' ) ?>
    259                
     259
    260260                <div class="submit">
    261261                        <input type="submit" disabled="disabled" value="<?php _e( 'Delete My Account', 'buddypress' ) ?> &rarr;" id="delete-account-button" name="delete-account-button" />
    262262                </div>
    263                
     263
    264264                <?php do_action( 'bp_core_delete_account_after_submit' ) ?>
    265265
    266266                <?php wp_nonce_field('delete-account') ?>
  • bp-core/bp-core-avatars.php

     
    484484 */
    485485function bp_core_fetch_avatar_filter( $avatar, $user, $size, $default, $alt ) {
    486486        global $pagenow;
    487        
     487
    488488        // Do not filter if inside WordPress options page
    489489        if ( 'options-discussion.php' == $pagenow )
    490490                return $avatar;
    491        
     491
    492492        // If passed an object, assume $user->user_id
    493493        if ( is_object( $user ) )
    494494                $id = $user->user_id;
  • bp-core/bp-core-catchuri.php

     
    6565
    6666        // Running off blog other than root
    6767        if ( defined( 'BP_ENABLE_MULTIBLOG' ) || 1 != BP_ROOT_BLOG ) {
    68  
     68
    6969                // Any subdirectory names must be removed from $bp_uri.
    7070                // This includes two cases: (1) when WP is installed in a subdirectory,
    7171                // and (2) when BP is running on secondary blog of a subdirectory
     
    7373                if ( $chunks = explode( '/', $current_blog->path ) ) {
    7474                        foreach( $chunks as $key => $chunk ) {
    7575                                $bkey = array_search( $chunk, $bp_uri );
    76  
     76
    7777                                if ( $bkey !== false )
    7878                                        unset( $bp_uri[$bkey] );
    79  
     79
    8080                                $bp_uri = array_values( $bp_uri );
    8181                        }
    8282                }
     
    139139
    140140                unset( $uri_chunks );
    141141        }
    142        
     142
    143143        // Search doesn't have an associated page, so we check for it separately
    144144        if ( !empty( $bp_uri[0] ) && BP_SEARCH_SLUG == $bp_uri[0] )
    145145                $matches[] = 1;
    146                
     146
    147147        // This is not a BuddyPress page, so just return.
    148148        if ( !isset( $matches ) )
    149149                return false;
  • bp-friends/bp-friends-notifications.php

     
    3939        $message = apply_filters( 'friends_notification_new_request_message', $message, $initiator_name, $initiator_link, $all_requests_link );
    4040
    4141        wp_mail( $to, $subject, $message );
    42        
     42
    4343        do_action( 'bp_friends_sent_request_email', $friend_id, $subject, $message, $friendship_id, $initiator_id );
    4444}
    4545
     
    7979        $message = apply_filters( 'friends_notification_accepted_request_message', $message, $friend_name, $friend_link );
    8080
    8181        wp_mail( $to, $subject, $message );
    82        
     82
    8383        do_action( 'bp_friends_sent_accepted_email', $initator_id, $subject, $message, $friendship_id, $friend_id );
    8484}
    8585
  • bp-activity/bp-activity-filters.php

     
    109109 * Finds and links @-mentioned users in activity updates
    110110 *
    111111 * @package BuddyPress Activity
    112  * 
     112 *
    113113 * @param string $content The activity content
    114114 */
    115115function bp_activity_at_name_filter( $content ) {
  • bp-activity/bp-activity-notifications.php

     
    1414        foreach( (array)$usernames as $username ) {
    1515                if ( !$receiver_user_id = bp_core_get_userid( $username ) )
    1616                        continue;
    17                        
    18                 bp_core_add_notification( $activity_id, $receiver_user_id, 'activity', 'new_at_mention', $poster_user_id );
    1917
     18                bp_core_add_notification( $activity_id, $receiver_user_id, 'activity', 'new_at_mention', $poster_user_id );
     19
    2020                // Now email the user with the contents of the message (if they have enabled email notifications)
    2121                if ( 'no' != get_user_meta( $receiver_user_id, 'notification_activity_new_mention', true ) ) {
    2222                        $poster_name = bp_core_get_user_displayname( $poster_user_id );
     
    5353                        wp_mail( $to, $subject, $message );
    5454                }
    5555        }
    56        
     56
    5757        do_action( 'bp_activity_sent_mention_email', $usernames, $subject, $message, $content, $poster_user_id, $activity_id );
    5858}
    5959add_action( 'bp_activity_posted_update', 'bp_activity_at_message_notification', 10, 3 );
     
    9797                $message = apply_filters( 'bp_activity_new_comment_notification_message', $message, $poster_name, $content, $thread_link );
    9898
    9999                wp_mail( $to, $subject, $message );
    100                
     100
    101101                do_action( 'bp_activity_sent_reply_to_update_email', $original_activity->user_id, $subject, $message, $comment_id, $commenter_id, $params );
    102102        }
    103103
     
    142142                $message = apply_filters( 'bp_activity_new_comment_notification_comment_author_message', $message, $poster_name, $content );
    143143
    144144                wp_mail( $to, $subject, $message );
    145                
     145
    146146                do_action( 'bp_activity_sent_reply_to_reply_email', $original_activity->user_id, $subject, $message, $comment_id, $commenter_id, $params );
    147147        }
    148148}
  • bp-activity/bp-activity-templatetags.php

     
    135135/**
    136136 * bp_has_activities()
    137137 *
    138  * Initializes the activity loop. 
     138 * Initializes the activity loop.
    139139 *
    140140 * Based on the $args passed, bp_has_activities() populates the $activities_template global.
    141141 *
     
    173173                if ( 'public' != $bp->groups->current_group->status && ( groups_is_user_member( $bp->loggedin_user->id, $bp->groups->current_group->id ) || $bp->loggedin_user->is_super_admin ) )
    174174                        $show_hidden = true;
    175175        }
    176        
     176
    177177        // The default scope should recognize custom slugs
    178178        if ( array_key_exists( $bp->current_action, (array)$bp->active_components ) ) {
    179179                $scope = $bp->active_components[$bp->current_action];
     
    941941        return apply_filters( 'bp_activity_can_comment_reply', $can_comment, $comment );
    942942}
    943943
    944 function bp_activity_can_favorite() {   
     944function bp_activity_can_favorite() {
    945945        $can_favorite = true;
    946        
     946
    947947        return apply_filters( 'bp_activity_can_favorite', $can_favorite );
    948948}
    949949
     
    10301030function bp_member_activity_feed_link() {
    10311031        echo bp_get_member_activity_feed_link();
    10321032}
    1033 function bp_activities_member_rss_link() { 
    1034         echo bp_get_member_activity_feed_link(); 
     1033function bp_activities_member_rss_link() {
     1034        echo bp_get_member_activity_feed_link();
    10351035}
    10361036
    10371037        function bp_get_member_activity_feed_link() {
  • bp-activity/bp-activity-classes.php

     
    120120                // Exclude specified items
    121121                if ( $exclude )
    122122                        $where_conditions['exclude'] = "a.id NOT IN ({$exclude})";
    123                
     123
    124124                // The specific ids to which you want to limit the query
    125125                if ( !empty( $in ) ) {
    126126                        if ( is_array( $in ) )
     
    461461
    462462                // array of prepared integers or quoted strings
    463463                $items_prepared = array();
    464                
     464
    465465                // clean up and format each item
    466466                foreach ( $items_dirty as $item ) {
    467467                        // clean up the string
  • bp-loader.php

     
    112112                'registration',
    113113                'fileupload_maxk'
    114114        ) );
    115        
     115
    116116        // These options always come from the options table of BP_ROOT_BLOG
    117117        $root_blog_options = apply_filters( 'bp_core_root_blog_options', array(
    118118                'avatar_default'
     
    124124                $site_meta = $wpdb->get_results( "SELECT meta_key AS name, meta_value AS value FROM {$wpdb->sitemeta} WHERE meta_key IN ({$meta_keys}) AND site_id = {$wpdb->siteid}" );
    125125        else
    126126                $site_meta = $wpdb->get_results( "SELECT option_name AS name, option_value AS value FROM {$wpdb->options} WHERE option_name IN ({$meta_keys})" );
    127                
     127
    128128        $root_blog_meta_keys = "'" . implode( "','", (array)$root_blog_options ) ."'";
    129        
     129
    130130        $root_blog_meta_table = $wpdb->get_blog_prefix( BP_ROOT_BLOG ) . 'options';
    131131        $root_blog_meta = $wpdb->get_results( $wpdb->prepare( "SELECT option_name AS name, option_value AS value FROM {$root_blog_meta_table} WHERE option_name IN ({$root_blog_meta_keys})" ) );
    132132
  • bp-blogs.php

     
    475475
    476476        if ( empty( $role ) ) {
    477477                $key = $wpdb->get_blog_prefix( $id ). 'capabilities';
    478                
     478
    479479                $roles = get_user_meta( $user_id, $key, true );
    480                
     480
    481481                if ( is_array( $roles ) )
    482482                        $role = array_search( 1, $roles );
    483483                else
  • bp-forums.php

     
    7272                                                $error_message = __( 'Please provide a title for your forum topic.', 'buddypress' );
    7373                                        else if ( empty( $_POST['topic_text'] ) )
    7474                                                $error_message = __( 'Forum posts cannot be empty. Please enter some text.', 'buddypress' );
    75                                        
     75
    7676                                        if ( $error_message ) {
    7777                                                bp_core_add_message( $error_message, 'error' );
    7878                                                $redirect = bp_get_group_permalink( $bp->groups->current_group ) . 'forum';
     
    8585                                                        $redirect = bp_get_group_permalink( $bp->groups->current_group ) . 'forum/topic/' . $topic->topic_slug . '/';
    8686                                                }
    8787                                        }
    88                                        
     88
    8989                                        bp_core_redirect( $redirect );
    90                                
     90
    9191                                } else {
    9292                                        bp_core_add_message( __( 'Please pick the group forum where you would like to post this topic.', 'buddypress' ), 'error' );
    9393                                }
  • bp-groups.php

     
    495495                                        $error_message = __( 'Please provide a title for your forum topic.', 'buddypress' );
    496496                                else if ( empty( $_POST['topic_text'] ) )
    497497                                        $error_message = __( 'Forum posts cannot be empty. Please enter some text.', 'buddypress' );
    498                                
     498
    499499                                if ( isset( $error_message ) ) {
    500500                                        bp_core_add_message( $error_message, 'error' );
    501501                                        $redirect = bp_get_group_permalink( $bp->groups->current_group ) . 'forum';
     
    10381038                                bp_core_add_message( __( 'Please fill in all of the required fields', 'buddypress' ), 'error' );
    10391039                                bp_core_redirect( $bp->root_domain . '/' . $bp->groups->slug . '/create/step/' . $bp->groups->current_create_step . '/' );
    10401040                        }
    1041                        
     1041
    10421042                        $new_group_id = isset( $bp->groups->new_group_id ) ? $bp->groups->new_group_id : 0;
    10431043
    10441044                        if ( !$bp->groups->new_group_id = groups_create_group( array( 'group_id' => $new_group_id, 'name' => $_POST['group-name'], 'description' => $_POST['group-desc'], 'slug' => groups_check_slug( sanitize_title( esc_attr( $_POST['group-name'] ) ) ), 'date_created' => bp_core_current_time(), 'status' => 'public' ) ) ) {
     
    13301330
    13311331function groups_update_last_activity( $group_id = false ) {
    13321332        global $bp;
    1333        
     1333
    13341334        if ( !$group_id )
    13351335                $group_id = $bp->groups->current_group->id;
    1336                
     1336
    13371337        if ( !$group_id )
    13381338                return false;
    1339        
     1339
    13401340        groups_update_groupmeta( $group_id, 'last_activity', bp_core_current_time() );
    13411341}
    13421342add_action( 'groups_leave_group', 'groups_update_last_activity' );
  • bp-blogs/bp-blogs-classes.php

     
    112112                foreach ( (array)$paged_blogs as $blog ) {
    113113                        $blog_ids[] = $blog->blog_id;
    114114                }
    115                
     115
    116116                $blog_ids = $wpdb->escape( join( ',', (array)$blog_ids ) );
    117117                $paged_blogs = BP_Blogs_Blog::get_blog_extras( &$paged_blogs, $blog_ids, $type );
    118118
  • bp-messages/bp-messages-notifications.php

     
    4343
    4444                wp_mail( $email_to, $email_subject, $email_content );
    4545        }
    46        
     46
    4747        do_action( 'bp_messages_sent_notification_email', $recipients, $email_subject, $email_content, $args );
    4848}
    4949
  • bp-messages/bp-messages-templatetags.php

     
    660660
    661661function bp_thread_has_messages( $args = '' ) {
    662662        global $bp, $thread_template, $group_id;
    663        
     663
    664664        $defaults = array(
    665665                'thread_id' => false,
    666666                'order' => 'ASC'
  • bp-messages/js/autocomplete/jquery.autocompletefb.dev.js

     
    66 * Credits:
    77 * - Idea: Facebook
    88 * - Guillermo Rauch: Original MooTools script
    9  * - InteRiders <http://interiders.com/> 
     9 * - InteRiders <http://interiders.com/>
    1010 *
    1111 * Copyright (c) 2008 Widi Harsojo <wharsojo@gmail.com>, http://wharsojo.wordpress.com/
    1212 * Dual licensed under the MIT and GPL licenses:
    1313 *   http://www.opensource.org/licenses/mit-license.php
    1414 *   http://www.gnu.org/licenses/gpl.html
    1515 */
    16  
    17 jQuery.fn.autoCompletefb = function(options) 
     16
     17jQuery.fn.autoCompletefb = function(options)
    1818{
    1919        var tmp = this;
    20         var settings = 
     20        var settings =
    2121        {
    2222                ul         : tmp,
    2323                urlLookup  : [""],
     
    2525                foundClass : ".friend-tab",
    2626                inputClass : ".send-to-input"
    2727        }
    28        
     28
    2929        if(options) jQuery.extend(settings, options);
    30        
    31         var acfb = 
     30
     31        var acfb =
    3232        {
    3333                params  : settings,
    3434                removeFind : function(o){
     
    4242                        jQuery('#send-to-usernames').removeClass(newID[1]);
    4343                }
    4444        }
    45        
     45
    4646        jQuery(settings.foundClass+" img.p").click(function(){
    4747                acfb.removeFind(this);
    4848        });
    49        
     49
    5050        jQuery(settings.inputClass,tmp).autocomplete(settings.urlLookup,settings.acOptions);
    5151        jQuery(settings.inputClass,tmp).result(function(e,d,f){
    5252                var f = settings.foundClass.replace(/\./,'');
     
    5656                var l = jQuery(ln).attr('value');
    5757                var v = '<li class="'+f+'" id="un-'+un+'"><span><a href="'+l+'">'+d[0]+'</a></span> <span class="p">X</span></li>';
    5858                var x = jQuery(settings.inputClass,tmp).before(v);
    59                
     59
    6060                jQuery('#send-to-usernames').addClass(un);
    61                
     61
    6262                jQuery('.p',x[0].previousSibling).click(function(){
    6363                        acfb.removeFind(this);
    6464                });
    6565                jQuery(settings.inputClass,tmp).val('');
    6666        });
    67        
     67
    6868        jQuery(settings.inputClass,tmp).focus();
    6969        return acfb;
    7070}
  • bp-messages/js/autocomplete/jquery.autocompletefb.js

     
    66 * Credits:
    77 * - Idea: Facebook
    88 * - Guillermo Rauch: Original MooTools script
    9  * - InteRiders <http://interiders.com/> 
     9 * - InteRiders <http://interiders.com/>
    1010 *
    1111 * Copyright (c) 2008 Widi Harsojo <wharsojo@gmail.com>, http://wharsojo.wordpress.com/
    1212 * Dual licensed under the MIT and GPL licenses:
  • bp-messages/js/autocomplete/jquery.bgiframe.min.js

     
    11/* Copyright (c) 2006 Brandon Aaron (http://brandonaaron.net)
    2  * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php) 
     2 * Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
    33 * and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
    44 *
    55 * $LastChangedDate: 2007-07-22 01:45:56 +0200 (Son, 22 Jul 2007) $
  • bp-messages/js/autocomplete/jquery.dimensions.dev.js

     
    1212 */
    1313
    1414(function($){
    15        
     15
    1616$.dimensions = {
    1717        version: '@VERSION'
    1818};
    1919
    2020// Create innerHeight, innerWidth, outerHeight and outerWidth methods
    2121$.each( [ 'Height', 'Width' ], function(i, name){
    22        
     22
    2323        // innerHeight and innerWidth
    2424        $.fn[ 'inner' + name ] = function() {
    2525                if (!this[0]) return;
    26                
     26
    2727                var torl = name == 'Height' ? 'Top'    : 'Left',  // top or left
    2828                    borr = name == 'Height' ? 'Bottom' : 'Right'; // bottom or right
    29                
     29
    3030                return this[ name.toLowerCase() ]() + num(this, 'padding' + torl) + num(this, 'padding' + borr);
    3131        };
    32        
     32
    3333        // outerHeight and outerWidth
    3434        $.fn[ 'outer' + name ] = function(options) {
    3535                if (!this[0]) return;
    36                
     36
    3737                var torl = name == 'Height' ? 'Top'    : 'Left',  // top or left
    3838                    borr = name == 'Height' ? 'Bottom' : 'Right'; // bottom or right
    39                
     39
    4040                options = $.extend({ margin: false }, options || {});
    41                
     41
    4242                return this[ name.toLowerCase() ]()
    4343                                + num(this, 'border' + torl + 'Width') + num(this, 'border' + borr + 'Width')
    4444                                + num(this, 'padding' + torl) + num(this, 'padding' + borr)
     
    5050$.each( ['Left', 'Top'], function(i, name) {
    5151        $.fn[ 'scroll' + name ] = function(val) {
    5252                if (!this[0]) return;
    53                
     53
    5454                return val != undefined ?
    55                
     55
    5656                        // Set the scroll offset
    5757                        this.each(function() {
    5858                                this == window || this == document ?
    59                                         window.scrollTo( 
     59                                        window.scrollTo(
    6060                                                name == 'Left' ? val : $(window)[ 'scrollLeft' ](),
    6161                                                name == 'Top'  ? val : $(window)[ 'scrollTop'  ]()
    6262                                        ) :
    6363                                        this[ 'scroll' + name ] = val;
    6464                        }) :
    65                        
     65
    6666                        // Return the scroll offset
    6767                        this[0] == window || this[0] == document ?
    6868                                self[ (name == 'Left' ? 'pageXOffset' : 'pageYOffset') ] ||
     
    7575$.fn.extend({
    7676        position: function() {
    7777                var left = 0, top = 0, elem = this[0], offset, parentOffset, offsetParent, results;
    78                
     78
    7979                if (elem) {
    8080                        // Get *real* offsetParent
    8181                        offsetParent = this.offsetParent();
    82                        
     82
    8383                        // Get correct offsets
    8484                        offset       = this.offset();
    8585                        parentOffset = offsetParent.offset();
    86                        
     86
    8787                        // Subtract element margins
    8888                        offset.top  -= num(elem, 'marginTop');
    8989                        offset.left -= num(elem, 'marginLeft');
    90                        
     90
    9191                        // Add offsetParent borders
    9292                        parentOffset.top  += num(offsetParent, 'borderTopWidth');
    9393                        parentOffset.left += num(offsetParent, 'borderLeftWidth');
    94                        
     94
    9595                        // Subtract the two offsets
    9696                        results = {
    9797                                top:  offset.top  - parentOffset.top,
    9898                                left: offset.left - parentOffset.left
    9999                        };
    100100                }
    101                
     101
    102102                return results;
    103103        },
    104        
     104
    105105        offsetParent: function() {
    106106                var offsetParent = this[0].offsetParent;
    107107                while ( offsetParent && (!/^body|html$/i.test(offsetParent.tagName) && $.css(offsetParent, 'position') == 'static') )
  • bp-forums/bp-forums-filters.php

     
    88add_filter( 'bp_get_the_topic_latest_post_excerpt', 'bp_forums_filter_kses', 1 );
    99add_filter( 'bp_get_the_topic_post_content', 'bp_forums_filter_kses', 1 );
    1010
    11 add_filter( 'bp_get_the_topic_title', 'force_balance_tags' ); 
     11add_filter( 'bp_get_the_topic_title', 'force_balance_tags' );
    1212add_filter( 'bp_get_the_topic_latest_post_excerpt', 'force_balance_tags' );
    1313add_filter( 'bp_get_the_topic_post_content', 'force_balance_tags' );
    1414
     
    120120 */
    121121function bp_forums_strip_mentions_on_post_edit( $content ) {
    122122        global $bp;
    123        
     123
    124124        $content = htmlspecialchars_decode( $content );
    125        
     125
    126126        $pattern = "|<a href=&#039;" . $bp->root_domain . "/" . $bp->members->slug . "/[A-Za-z0-9-_\.]+/&#039; rel=&#039;nofollow&#039;>(@[A-Za-z0-9-_\.]+)</a>|";
    127        
     127
    128128        $content = preg_replace( $pattern, "$1", $content );
    129        
     129
    130130        return $content;
    131131}
    132132add_filter( 'bp_get_the_topic_post_edit_text', 'bp_forums_strip_mentions_on_post_edit' );
  • bp-core.php

     
    482482                        $wpdb->update( $wpdb->users, array( 'spam' => $is_spam ), array( 'ID' => $bp->displayed_user->id ) );
    483483
    484484                $wpdb->update( $wpdb->users, array( 'user_status' => $is_spam ), array( 'ID' => $bp->displayed_user->id ) );
    485                
     485
    486486                if ( $is_spam )
    487487                        bp_core_add_message( __( 'User marked as spammer. Spam users are visible only to site admins.', 'buddypress' ) );
    488488                else
     
    491491                /* Hide this user's activity */
    492492                if ( $is_spam && function_exists( 'bp_activity_hide_user_activity' ) )
    493493                        bp_activity_hide_user_activity( $bp->displayed_user->id );
    494                
     494
    495495                // We need a special hook for is_spam so that components can delete data at spam time
    496496                if ( $is_spam )
    497497                        do_action( 'bp_make_spam_user', $bp->displayed_user->id );
     
    20002000 * Functions to set up custom BuddyPress actions that all other components can
    20012001 * hook in to.
    20022002 */
    2003  
     2003
    20042004/**
    20052005 * bp_include()
    20062006 *
  • bp-xprofile.php

     
    633633        if ( is_array( $values ) ) {
    634634                $data = array();
    635635                foreach( (array)$values as $value ) {
    636                         $data[] = apply_filters( 'xprofile_get_field_data', $value ); 
     636                        $data[] = apply_filters( 'xprofile_get_field_data', $value );
    637637                }
    638638        } else {
    639639                $data = apply_filters( 'xprofile_get_field_data', $values );
    640640        }
    641        
     641
    642642        return $data;
    643643}
    644644
     
    927927
    928928        if ( !$object_id )
    929929                return false;
    930        
     930
    931931        if ( !isset( $object_type ) )
    932932                return false;
    933        
     933
    934934        if ( !in_array( $object_type, array( 'group', 'field', 'data' ) ) )
    935935                return false;
    936936
     
    961961
    962962        if ( !$object_id )
    963963                return false;
    964        
     964
    965965        if ( !isset( $object_type ) )
    966966                return false;
    967        
     967
    968968        if ( !in_array( $object_type, array( 'group', 'field', 'data' ) ) )
    969969                return false;
    970970
     
    10021002
    10031003        if ( !$object_id )
    10041004                return false;
    1005        
     1005
    10061006        if ( !isset( $object_type ) )
    10071007                return false;
    1008        
     1008
    10091009        if ( !in_array( $object_type, array( 'group', 'field', 'data' ) ) )
    10101010                return false;
    1011                
     1011
    10121012        $meta_key = preg_replace( '|[^a-z0-9_]|i', '', $meta_key );
    10131013
    10141014        if ( is_string( $meta_value ) )
     
    10181018
    10191019        if ( empty( $meta_value ) )
    10201020                return bp_xprofile_delete_meta( $object_id, $object_type, $meta_key );
    1021        
     1021
    10221022        $cur = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM " . $bp->profile->table_name_meta . " WHERE object_id = %d AND object_type = %s AND meta_key = %s", $object_id, $object_type, $meta_key ) );
    10231023
    10241024        if ( !$cur )
     
    10351035}
    10361036
    10371037function bp_xprofile_update_fieldgroup_meta( $field_group_id, $meta_key, $meta_value ) {
    1038         return bp_xprofile_update_meta( $field_group_id, 'group', $meta_key, $meta_value );     
     1038        return bp_xprofile_update_meta( $field_group_id, 'group', $meta_key, $meta_value );
    10391039}
    10401040
    10411041function bp_xprofile_update_field_meta( $field_id, $meta_key, $meta_value ) {
    1042         return bp_xprofile_update_meta( $field_id, 'field', $meta_key, $meta_value );   
     1042        return bp_xprofile_update_meta( $field_id, 'field', $meta_key, $meta_value );
    10431043}
    10441044
    10451045function bp_xprofile_update_fielddata_meta( $field_data_id, $meta_key, $meta_value ) {
    1046         return bp_xprofile_update_meta( $field_data_id, 'data', $meta_key, $meta_value );       
     1046        return bp_xprofile_update_meta( $field_data_id, 'data', $meta_key, $meta_value );
    10471047}
    10481048
    10491049/********************************************************************************
  • bp-groups/bp-groups-classes.php

     
    288288                        $include = $wpdb->escape( $include );
    289289                        $sql['include'] = " AND g.id IN ({$include})";
    290290                }
    291                
     291
    292292                if ( !empty( $exclude ) ) {
    293293                        $exclude = $wpdb->escape( $exclude );
    294294                        $sql['exclude'] = " AND g.id NOT IN ({$exclude})";
     
    357357
    358358                return array( 'groups' => $paged_groups, 'total' => $total_groups );
    359359        }
    360        
     360
    361361        function get_by_most_forum_topics( $limit = null, $page = null, $user_id = false, $search_terms = false, $populate_extras = true, $exclude = false ) {
    362362                global $wpdb, $bp, $bbdb;
    363363
     
    375375                        $search_terms = like_escape( $wpdb->escape( $search_terms ) );
    376376                        $search_sql = " AND ( g.name LIKE '%%{$search_terms}%%' OR g.description LIKE '%%{$search_terms}%%' )";
    377377                }
    378                
     378
    379379                if ( !empty( $exclude ) ) {
    380380                        $exclude = $wpdb->escape( $exclude );
    381381                        $exclude_sql = " AND g.id NOT IN ({$exclude})";
     
    416416                        $search_terms = like_escape( $wpdb->escape( $search_terms ) );
    417417                        $search_sql = " AND ( g.name LIKE '%%{$search_terms}%%' OR g.description LIKE '%%{$search_terms}%%' )";
    418418                }
    419                
     419
    420420                if ( !empty( $exclude ) ) {
    421421                        $exclude = $wpdb->escape( $exclude );
    422422                        $exclude_sql = " AND g.id NOT IN ({$exclude})";
     
    493493                        $search_terms = like_escape( $wpdb->escape( $search_terms ) );
    494494                        $search_sql = " AND ( g.name LIKE '%%{$search_terms}%%' OR g.description LIKE '%%{$search_terms}%%' )";
    495495                }
    496                
     496
    497497                if ( !empty( $exclude ) ) {
    498498                        $exclude = $wpdb->escape( $exclude );
    499499                        $exclude_sql = " AND g.id NOT IN ({$exclude})";
     
    866866                global $wpdb, $bp;
    867867
    868868                $pag_sql = ( !empty( $limit ) && !empty( $page ) ) ? $wpdb->prepare( " LIMIT %d, %d", intval( ( $page - 1 ) * $limit), intval( $limit ) ) : '';
    869                
     869
    870870                $exclude_sql = !empty( $exclude ) ? $wpdb->prepare( " AND g.id NOT IN (%s)", $exclude ) : '';
    871871
    872872                $paged_groups = $wpdb->get_results( $wpdb->prepare( "SELECT g.*, gm1.meta_value as total_member_count, gm2.meta_value as last_activity FROM {$bp->groups->table_name_groupmeta} gm1, {$bp->groups->table_name_groupmeta} gm2, {$bp->groups->table_name_members} m, {$bp->groups->table_name} g WHERE g.id = m.group_id AND g.id = gm1.group_id AND g.id = gm2.group_id AND gm2.meta_key = 'last_activity' AND gm1.meta_key = 'total_member_count' AND m.is_confirmed = 0 AND m.inviter_id != 0 AND m.invite_sent = 1 AND m.user_id = %d {$exclude_sql} ORDER BY m.date_modified ASC {$pag_sql}", $user_id ) );
  • bp-groups/bp-groups-widgets.php

     
    2323
    2424        function widget( $args, $instance ) {
    2525                global $bp;
    26                
     26
    2727                $user_id = apply_filters( 'bp_group_widget_user_id', '0' );
    2828
    2929                extract( $args );
     
    9999                        'title' => __( 'Groups', 'buddypress' ),
    100100                        'max_members' => 5,
    101101                        'group_default' => 'active'
    102                 );     
     102                );
    103103                $instance = wp_parse_args( (array) $instance, $defaults );
    104                
     104
    105105                $title = strip_tags( $instance['title'] );
    106106                $max_groups = strip_tags( $instance['max_groups'] );
    107107                $group_default = strip_tags( $instance['group_default'] );
    108108                ?>
    109                
     109
    110110                <p><label for="bp-groups-widget-title"><?php _e('Title:', 'buddypress'); ?> <input class="widefat" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" type="text" value="<?php echo esc_attr( $title ); ?>" style="width: 100%" /></label></p>
    111111
    112112                <p><label for="bp-groups-widget-groups-max"><?php _e('Max groups to show:', 'buddypress'); ?> <input class="widefat" id="<?php echo $this->get_field_id( 'max_groups' ); ?>" name="<?php echo $this->get_field_name( 'max_groups' ); ?>" type="text" value="<?php echo esc_attr( $max_groups ); ?>" style="width: 30%" /></label></p>
    113                
     113
    114114                <p>
    115                         <label for="bp-groups-widget-groups-default"><?php _e('Default groups to show:', 'buddypress'); ?> 
     115                        <label for="bp-groups-widget-groups-default"><?php _e('Default groups to show:', 'buddypress'); ?>
    116116                        <select name="<?php echo $this->get_field_name( 'group_default' ); ?>">
    117117                                <option value="newest" <?php if ( $group_default == 'newest' ) : ?>selected="selected"<?php endif; ?>><?php _e( 'Newest', 'buddypress' ) ?></option>
    118118                                <option value="active" <?php if ( $group_default == 'active' ) : ?>selected="selected"<?php endif; ?>><?php _e( 'Active', 'buddypress' ) ?></option>
    119119                                <option value="popular"  <?php if ( $group_default == 'popular' ) : ?>selected="selected"<?php endif; ?>><?php _e( 'Popular', 'buddypress' ) ?></option>
    120                         </select>                       
     120                        </select>
    121121                        </label>
    122122                </p>
    123123        <?php
  • bp-groups/bp-groups-notifications.php

     
    3838
    3939                unset( $message, $to );
    4040        }
    41        
     41
    4242        do_action( 'bp_groups_sent_updated_email', $user_ids, $subject, $message, $group_id );
    4343}
    4444
     
    8686        $message = apply_filters( 'groups_notification_new_membership_request_message', $message, &$group, $requesting_user_name, $profile_link, $group_requests );
    8787
    8888        wp_mail( $to, $subject, $message );
    89        
     89
    9090        do_action( 'bp_groups_sent_membership_request_email', $admin_id, $subject, $message, $requesting_user_id, $group_id, $membership_id );
    9191}
    9292
     
    142142        $message = apply_filters( 'groups_notification_membership_request_completed_message', $message, &$group, $group_link  );
    143143
    144144        wp_mail( $to, $subject, $message );
    145        
     145
    146146        do_action( 'bp_groups_sent_membership_approved_email', $requesting_user_id, $subject, $message, $group_id );
    147147}
    148148
     
    190190        $message = apply_filters( 'groups_notification_promoted_member_message', $message, &$group, $promoted_to, $group_link );
    191191
    192192        wp_mail( $to, $subject, $message );
    193        
     193
    194194        do_action( 'bp_groups_sent_promoted_email', $user_id, $subject, $message, $group_id );
    195195}
    196196add_action( 'groups_promoted_member', 'groups_notification_promoted_member', 10, 2 );
     
    245245
    246246                wp_mail( $to, $subject, $message );
    247247        }
    248        
     248
    249249        do_action( 'bp_groups_sent_invited_email', $invited_user_id, $subject, $message, $group );
    250250}
    251251
     
    306306                        wp_mail( $to, $subject, $message );
    307307                }
    308308        }
    309        
     309
    310310        do_action( 'bp_groups_sent_mention_email', $usernames, $subject, $message, $content, $poster_user_id, $group_id, $activity_id );
    311311}
    312312add_action( 'bp_groups_posted_update', 'groups_at_message_notification', 10, 4 );
  • bp-groups/bp-groups-templatetags.php

     
    17151715}
    17161716        function bp_get_new_group_id() {
    17171717                global $bp;
    1718                
     1718
    17191719                if ( isset( $bp->groups->new_group_id ) )
    17201720                        $new_group_id = $bp->groups->new_group_id;
    17211721                else
    17221722                        $new_group_id = 0;
    1723                
     1723
    17241724                return apply_filters( 'bp_get_new_group_id', $new_group_id );
    17251725        }
    17261726
     
    17291729}
    17301730        function bp_get_new_group_name() {
    17311731                global $bp;
    1732                
     1732
    17331733                if ( isset( $bp->groups->current_group->name ) )
    17341734                        $name = $bp->groups->current_group->name;
    17351735                else
    17361736                        $name = '';
    1737                
     1737
    17381738                return apply_filters( 'bp_get_new_group_name', $name );
    17391739        }
    17401740
     
    17431743}
    17441744        function bp_get_new_group_description() {
    17451745                global $bp;
    1746                
     1746
    17471747                if ( isset( $bp->groups->current_group->description ) )
    17481748                        $description = $bp->groups->current_group->description;
    17491749                else
    17501750                        $description = '';
    1751                        
     1751
    17521752                return apply_filters( 'bp_get_new_group_description', $description );
    17531753        }
    17541754
     
    18551855
    18561856                        for ( $i = 0; $i < count( $friends ); $i++ ) {
    18571857                                $checked = '';
    1858                                
     1858
    18591859                                if ( !empty( $invites ) ) {
    18601860                                        if ( in_array( $friends[$i]['id'], $invites ) )
    18611861                                                $checked = ' checked="checked"';
     
    22452245
    22462246        if ( !$group_id ) {
    22472247                /* Backwards compatibility */
    2248                 if ( !empty( $bp->groups->current_group ) ) 
     2248                if ( !empty( $bp->groups->current_group ) )
    22492249                        $group_id = $bp->groups->current_group->id;
    22502250                if ( !empty( $bp->groups->new_group_id ) )
    22512251                        $group_id = $bp->groups->new_group_id;