[wp-hackers] With wordpress 3.7 our function that prevented checking for upgrade on wordpress.org has broken, what has changed?
Nicola Peluchetti
nicola.peluchetti at gmail.com
Sat Oct 26 14:48:09 UTC 2013
Hi,
we have a premium version of our plugin which stops checking for updates
from wordpress.org. I guess 3.7 broke that. This is our function
// ================================================
// = Disable updates checking for premium version =
// ================================================
function ai1ec_disable_updates( $r, $url ) {
if ( 0 !== strpos( $url, 'http://api.wordpress.org/plugins/update-check' ) )
return $r; // Not a plugin update request.
$plugins = unserialize( $r['body']['plugins'] );
unset( $plugins->plugins[ plugin_basename( __FILE__ ) ] );
unset( $plugins->active[ array_search( plugin_basename( __FILE__ ),
$plugins->active ) ] );
$r['body']['plugins'] = serialize( $plugins );
return $r;
}
how can i change this to make it work with 3.7?
* *
*Nicola Peluchetti - Senior PHP Developer @ Timely**
*
Twitter: @nik_peluchetti <https://twitter.com/#!/nik_peluchetti>
Facebook: nicola.peluchetti <https://www.facebook.com/nicola.peluchetti>
Stackoverflow: Stackoverflow<http://stackoverflow.com/users/397861/nicola-peluchetti>
Mobile: +39 339 7507235
More information about the wp-hackers
mailing list