本文整理匯總了PHP中GFAddOn::setup方法的典型用法代碼示例。如果您正苦於以下問題:PHP GFAddOn::setup方法的具體用法?PHP GFAddOn::setup怎麽用?PHP GFAddOn::setup使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類GFAddOn
的用法示例。
在下文中一共展示了GFAddOn::setup方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: setup
protected function setup()
{
parent::setup();
//upgrading Feed Add-On base class
$installed_version = get_option("gravityformsaddon_feed-base_version");
//if ($installed_version != $this->_feed_version)
//$this->upgrade_base($installed_version);
//update_option("gravityformsaddon_feed-base_version", $this->_feed_version);
}
示例2: setup
protected function setup()
{
//upgrading Feed Add-On base class
$installed_version = get_option('gravityformsaddon_feed-base_version');
if ($installed_version != $this->_feed_version) {
$this->upgrade_base($installed_version);
}
update_option('gravityformsaddon_feed-base_version', $this->_feed_version);
parent::setup();
}
示例3: setup
/**
* Performs upgrade tasks when the version of the Add-On changes. To add additional upgrade tasks, override the upgrade() function, which will only get executed when the plugin version has changed.
*/
public function setup()
{
global $wpdb;
$table_name = $wpdb->prefix . 'gf_addon_feed';
// upgrading Feed Add-On base class
$installed_version = get_option('gravityformsaddon_feed-base_version');
if ($installed_version != $this->_feed_version || isset($_GET['setup']) && $this->is_plugin_settings() && !$this->table_exists($table_name)) {
$this->upgrade_base($installed_version);
update_option('gravityformsaddon_feed-base_version', $this->_feed_version);
}
parent::setup();
}
示例4: setup
protected function setup()
{
global $wpdb;
$table_name = $wpdb->prefix . 'gf_addon_feed';
//upgrading Feed Add-On base class
$installed_version = get_option('gravityformsaddon_feed-base_version');
if ($installed_version != $this->_feed_version || !$this->table_exists($table_name)) {
$this->upgrade_base($installed_version);
update_option('gravityformsaddon_feed-base_version', $this->_feed_version);
}
parent::setup();
}