-
Notifications
You must be signed in to change notification settings - Fork 0
/
plugin.php
49 lines (38 loc) · 983 Bytes
/
plugin.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?php
/*
Plugin Name: Multiflow Contacts
Plugin URI: http://mildfuzz.com
Description: A plugin for creating a contact form that easily reroutes the email form to relevant people through the use of sections.
Version: 0.1
Author: Mild Fuzz
Author URI: http://mildfuzz.com
License: GPL2
*/
//load core classes
include 'core_classes.php';
global $mf_plugin;
$pluginTables = array(
'tables' => array(
"contacts" => array(
'email' => 'text NOT NULL',
'name' => 'text NOT NULL',
'section' => 'text NOT NULL'
)
)
);
$mf_plugin = new PluginTables($pluginTables);
register_activation_hook(__FILE__,'mf_activate_plugin');
register_deactivation_hook(__FILE__,'mf_deactivate_plugin');
function mf_activate_plugin(){
global $mf_plugin;
$mf_plugin->activate();
}
function mf_deactivate_plugin(){
global $mf_plugin;
$mf_plugin->deactivate();
}
//after install
include 'pages.php';
include 'utilities.php';
include 'shortcode.php';
?>