Update: please note that I have since switched to using a set of bash scripts instead of poluting the Git repository with git svn
.
Author: Kaspars Dambis
kaspars.net / @konstruktors
<?php | |
add_filter( 'json_query_vars', function( $valid_vars ) { | |
$valid_vars = array_merge( $valid_vars, array( 'meta_key', 'meta_value' ) ); | |
return $valid_vars; | |
}); |
<?php | |
if ( ! class_exists( 'Imath_Auto_Join_Groups' ) ) : | |
/** | |
* AutoJoin new members to chosen groups | |
* | |
* This is a little snippet, feel free to : | |
* - use it | |
* - extend it.. |
<?php | |
/** | |
* Modify BuddyPress group search to work on a word-wise basis | |
*/ | |
function openlab_group_search_breakup( $sql, $s ) { | |
global $bp; | |
if ( ! empty( $s['search'] ) ) { | |
// Get the search terms |
<?php | |
/* | |
beginning of the code to paste in the functions.php of the active theme (twentyten, twentyeleven or twentytwelve) | |
If you want to adapt it to your theme, you'll need to check if it uses some body_class to render its layout and eventually | |
adapt lines 70 to 101. | |
*/ | |
class Imath_WP_Editor_Template | |
{ | |
<?php | |
function bbg_activity_subnav( $items, $menu, $args ) { | |
// Find the Activity item | |
$bp_pages = bp_core_get_directory_page_ids(); | |
if ( isset( $bp_pages['activity'] ) ) { | |
$activity_directory_page = $bp_pages['activity']; | |
} else { | |
return $items; |
<?php | |
/** | |
* File class | |
* | |
* @package Molajo | |
* @copyright 2013 Amy Stephen. All rights reserved. | |
* @license MIT, GPL v2 or later | |
*/ | |
namespace Molajo; |
/*jslint undef: false, browser: true, devel: false, eqeqeq: false, bitwise: false, white: false, plusplus: false, regexp: false, nomen: false */ | |
/*global wp,jQuery */ | |
jQuery(document).ready(function($) { | |
if (!window.wp || !window.wp.media) { | |
return; | |
} | |
var media = window.wp.media; |
<?php | |
/* | |
Plugin Name: Easy Digital Downloads - Variable Pricing License Activation Limits | |
Plugin URL: http://easydigitaldownloads.com/extension/ | |
Description: Limit the number of license activations permitted based on variable prices | |
Version: 1.0 | |
Author: Pippin Williamson | |
Author URI: http://pippinsplugins.com | |
Contributors: mordauk | |
*/ |
/** | |
* Remove the group activity post form | |
*/ | |
add_action( 'bp_before_group_activity_post_form', create_function( '', 'ob_start();' ), 9999 ); | |
add_action( 'bp_after_group_activity_post_form', create_function( '', 'ob_end_clean();' ), 0 ); |
Update: please note that I have since switched to using a set of bash scripts instead of poluting the Git repository with git svn
.
Author: Kaspars Dambis
kaspars.net / @konstruktors