PluginProbe
Ever Compare – Products Compare Plugin for WooCommerce / 1.0.0
Ever Compare – Products Compare Plugin for WooCommerce v1.0.0
1.3.7 1.1.7 1.1.8 1.1.9 1.2.0 1.2.1 1.2.2 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 trunk 1.0.0 1.0.1 1.0.2 All 31 releases
ever-compare / includes / classes / Installer.php

Installer.php in Ever Compare – Products Compare Plugin for WooCommerce 1.0.0, at includes/classes/Installer.php

39 lines 755 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 namespace EverCompare;
3 /**
4 * Installer class
5 */
6 class Installer {
7
8 /**
9 * Run the installer
10 *
11 * @return void
12 */
13 public function run() {
14 $this->add_version();
15 $this->add_redirection_flag();
16 }
17
18 /**
19 * Add time and version on DB
20 */
21 public function add_version() {
22 $installed = get_option( 'evercompare_installed' );
23
24 if ( ! $installed ) {
25 update_option( 'evercompare_installed', time() );
26 }
27
28 update_option( 'evercompare_version', EVERCOMPARE_VERSION );
29 }
30
31 /**
32 * [add_redirection_flag] redirection flug
33 */
34 public function add_redirection_flag(){
35 add_option( 'evercompare_do_activation_redirect', true );
36 }
37
38
39 }