/** * Check if the minimum version of Gravity Perks is installed for this perk. * */ public function is_gravity_perks_supported() { if (isset($this->min_gravity_perks_version)) { $is_supported = version_compare(GWPerks::get_version(), $this->min_gravity_perks_version, '>='); } else { $is_supported = true; } return $is_supported; }
public static function get_request_args($args = array()) { return wp_parse_args($args, array('user-agent' => 'Gravity Perks ' . GWPerks::get_version(), 'timeout' => 15)); }
public static function load_api() { require_once dirname(__FILE__) . '/includes/storefront_api.php'; self::$api = new GWAPI(array('plugin_file' => plugin_basename(__FILE__), 'version' => GWPerks::get_version(), 'license' => GWPerks::get_license_key(), 'item_name' => 'Gravity Perks', 'author' => 'David Smith')); }