Skip to content

Instantly share code, notes, and snippets.

View ryanhellyer's full-sized avatar

Ryan Hellyer ryanhellyer

View GitHub Profile
@ryanhellyer
ryanhellyer / disable theme updates
Created November 29, 2012 19:05
Code to disable WordPress theme updates
<?php
/*
* Disable theme updates
*
* @param array $r Response header
* @param string $url The update URL
*/
function slug_hidden_theme( $r, $url ) {
if ( 0 !== strpos( $url, 'http://api.wordpress.org/themes/update-check' ) )
@ryanhellyer
ryanhellyer / SharePulse.php
Last active August 29, 2015 14:05
Allow for addition of extra post-types by providing a filter on the get_posts() arguments.
--- <SharePulse.php>
+++ <SharePulse.php>
@@ -159,14 +159,16 @@
$options = $this->get_sp_options();
- $ids = get_posts(array(
- 'orderby' => 'comment_count',
- 'posts_per_page' => -1,
- 'cache_results' => false,