Version Description
- Added: Custom javascript event, occurs after form is submitted.
- Changed: Code structure refactoring.
- Fixed: Bug on required fields PHP validation.
- Fixed: Bug on saving a theme.
- Added: Loading for add-ons options.
- Changed: label_order field length.
- Fixed: Do not allow negative numbers as quantity.
- Improved: Insert placeholder functionality.
- Fixed: Action after submission text for popup forms.
- Changed: Updated translations.
- Added: Gutenberg integration.
- Fixed: Required mark for "Receive Copy" field.
- Fixed: Bug on selecting options from database.
- Minor fix: an incorrect link
- Improved: Insert placeholder functionality.
- Fixed: Action after submission text for popup forms.
- Fixed: Do not allow negative numbers as quantity.
- Added: Loading for add-ons options.
- Added: Premium version page new style.
- Added: Add-ons page new style.
- Fixed: Submission id bug.
- Fixed: Security issue reported by Sairam Jetty.
Download this release
Release Info
Developer | webdorado |
Plugin | Contact Form by WD – responsive drag & drop contact form builder tool |
Version | 1.12.28 |
Comparing to | |
See all releases |
Code changes from version 1.12.22 to 1.12.28
- WDFM.php +8 -0
- admin/controllers/Addons_fm.php +155 -0
- admin/controllers/Blocked_ips_fm.php +30 -30
- admin/controllers/Checkpaypal.php +29 -29
- admin/controllers/FMShortocde.php +4 -4
- admin/controllers/FormMakerEditCountryinPopup.php +3 -3
- admin/controllers/FormMakerIpinfoinPopup.php +4 -4
- admin/controllers/FormMakerMapEditinPopup.php +5 -5
- admin/controllers/FormMakerSQLMapping.php +7 -7
- admin/controllers/FormMakerSubmits.php +3 -3
- admin/controllers/Formmakerwdcaptcha.php +2 -2
- admin/controllers/Formmakerwdmathcaptcha.php +2 -2
- admin/controllers/Generete_csv.php +10 -4
- admin/controllers/Generete_xml.php +2 -2
- admin/controllers/Licensing_fm.php +0 -26
- admin/controllers/Manage_fm.php +273 -263
- admin/controllers/Options_fm.php +9 -9
- admin/controllers/Paypal_info.php +4 -4
- admin/controllers/Pricing_fm.php +54 -0
- admin/controllers/Product_option.php +5 -5
- admin/controllers/Select_data_from_db.php +9 -9
- admin/controllers/Show_matrix.php +2 -2
- admin/controllers/Submissions_fm.php +34 -34
- admin/controllers/Themes_fm.php +486 -486
- admin/controllers/Uninstall_fm.php +8 -8
- admin/controllers/Widget.php +15 -10
- admin/controllers/controller.php +10 -0
- admin/models/Blocked_ips_fm.php +4 -4
- admin/models/Checkpaypal.php +1 -1
- admin/models/FMPaypalInfo.php +1 -1
- admin/models/FMSelectDataFromDb.php +12 -12
- admin/models/FMShortocde.php +3 -2
- admin/models/FMSqlMapping.php +13 -13
- admin/models/FormMakerSubmits.php +1 -1
- admin/models/Manage_fm.php +48 -47
- admin/models/Options_fm.php +6 -6
- admin/models/Submissions_fm.php +8 -6
- admin/models/Themes_fm.php +1 -1
- admin/models/Uninstall_fm.php +6 -5
- admin/models/Widget.php +7 -2
- admin/models/model.php +10 -0
- admin/views/Addons_fm.php +84 -0
- admin/views/Blocked_ips_fm.php +18 -18
- admin/views/Checkpaypal.php +19 -19
- admin/views/FMCaptcha.php +3 -3
- admin/views/FMEditCountryinPopup.php +5 -5
- admin/views/FMIpinfoinPopup.php +8 -8
- admin/views/FMMapEditinPopup.php +5 -5
- admin/views/FMMathCaptcha.php +3 -3
- admin/views/FMPaypalInfo.php +1 -1
- admin/views/FMProductOption.php +4 -4
- admin/views/FMSelectDataFromDb.php +9 -9
- admin/views/FMShortocde.php +42 -40
- admin/views/FMShowMatrix.php +1 -1
- admin/views/FMSqlMapping.php +21 -21
- admin/views/FormMakerSubmits.php +1 -1
- admin/views/Licensing_fm.php +0 -70
- admin/views/Manage_fm.php +657 -734
- admin/views/Options_fm.php +24 -24
- admin/views/Pricing_fm.php +174 -0
- admin/views/Submissions_fm.php +133 -127
- admin/views/Themes_fm.php +63 -63
- admin/views/Uninstall_fm.php +18 -16
- admin/views/view.php +321 -29
- assets/add-ons-icon.png +0 -0
- assets/calculator.png +0 -0
- assets/conditional-emails-update.png +0 -0
- assets/dropbox-integration-update.png +0 -0
- assets/form-maker.png +0 -0
- assets/google_drive_integration.png +0 -0
- assets/import_export.png +0 -0
- assets/mailchimp.png +0 -0
- assets/pdf-integration.png +0 -0
- assets/post-generation-update.png +0 -0
- assets/pushover.png +0 -0
- assets/reg.png +0 -0
- assets/save-progress.png +0 -0
- assets/stripe-integration-update.png +0 -0
- assets/updates_icon.jpg +0 -0
- contact-form-maker.php +314 -353
- css/form_maker_frontend.css +2 -1
- css/form_maker_tables.css +182 -68
- css/license.css +0 -158
- css/pricing.css +860 -0
- css/style.css +2 -2
- css/tw-gb/block.css +50 -0
- featured/admin.css +0 -741
- featured/featured.php +0 -163
- featured/images/Add_Ons.jpg +0 -0
- featured/images/calendar.png +0 -0
- featured/images/calendar1.png +0 -0
- featured/images/calendar_hover.png +0 -0
- featured/images/calendar_menu.png +0 -0
- featured/images/delete_el.png +0 -0
- featured/images/down.png +0 -0
- featured/images/downarrow.png +0 -0
- featured/images/download.jpg +0 -0
- featured/images/download_plugins.png +0 -0
- featured/images/form.png +0 -0
- featured/images/form_import.png +0 -0
- featured/images/index.html +0 -11
- featured/images/loadingAnimation.gif +0 -0
- featured/images/tb-close.png +0 -0
- featured/images/up.png +0 -0
- featured/index.html +0 -11
- featured/style.css +0 -208
- featured/updates.php +0 -158
- form_maker_insert.php +26 -14
- form_maker_update.php +15 -0
- framework/WDW_FM_Library.php +385 -333
- frontend/controllers/form_maker.php +9 -4
- frontend/controllers/verify_email.php +9 -4
- frontend/models/form_maker.php +333 -342
WDFM.php
ADDED
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
function WDFM( $version = 0 ) {
|
4 |
+
if ( $version == 2 ) {
|
5 |
+
return WDCFM::instance();
|
6 |
+
}
|
7 |
+
return WDFM::instance();
|
8 |
+
}
|
admin/controllers/Addons_fm.php
ADDED
@@ -0,0 +1,155 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Class FMControllerAddons_fmc
|
4 |
+
*/
|
5 |
+
class FMControllerAddons_fmc extends CFMAdminController {
|
6 |
+
/**
|
7 |
+
* @var $model
|
8 |
+
*/
|
9 |
+
private $model;
|
10 |
+
/**
|
11 |
+
* @var $view
|
12 |
+
*/
|
13 |
+
private $view;
|
14 |
+
/**
|
15 |
+
* @var string $page
|
16 |
+
*/
|
17 |
+
private $page;
|
18 |
+
|
19 |
+
public function __construct() {
|
20 |
+
$this->page = WDW_FM_Library(self::PLUGIN)->get('page');
|
21 |
+
$this->page_url = add_query_arg( array (
|
22 |
+
'page' => $this->page,
|
23 |
+
WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce),
|
24 |
+
), admin_url('admin.php')
|
25 |
+
);
|
26 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Addons_fm.php";
|
27 |
+
$this->view = new FMViewAddons_fmc();
|
28 |
+
}
|
29 |
+
|
30 |
+
/**
|
31 |
+
* Execute.
|
32 |
+
*/
|
33 |
+
public function execute() {
|
34 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task');
|
35 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
36 |
+
if (method_exists($this, $task)) {
|
37 |
+
$this->$task($id);
|
38 |
+
}
|
39 |
+
else {
|
40 |
+
$this->display();
|
41 |
+
}
|
42 |
+
}
|
43 |
+
|
44 |
+
/**
|
45 |
+
* Display.
|
46 |
+
*/
|
47 |
+
public function display() {
|
48 |
+
// Set params for view.
|
49 |
+
$params = array();
|
50 |
+
$params['page'] = $this->page;
|
51 |
+
$params['page_url'] = $this->page_url;
|
52 |
+
$params['addons'] = array(
|
53 |
+
'Form Maker Add-ons' => array(
|
54 |
+
'imp_exp' => array(
|
55 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
56 |
+
'dir' => 'form-maker-export-import/fm_exp_imp.php',
|
57 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/export-import.html',
|
58 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/import_export.svg',
|
59 |
+
'name' => __('Import/Export', WDFMInstance(self::PLUGIN)->prefix),
|
60 |
+
'description' => __('Form Maker Export/Import WordPress plugin allows exporting and importing forms with/without submissions.', WDFMInstance(self::PLUGIN)->prefix)
|
61 |
+
),
|
62 |
+
'mailchimp' => array(
|
63 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
64 |
+
'dir' => 'form-maker-mailchimp/fm_mailchimp.php',
|
65 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/mailchimp.html',
|
66 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/mailchimp.svg',
|
67 |
+
'name' => __('MailChimp', WDFMInstance(self::PLUGIN)->prefix),
|
68 |
+
'description' => __('This add-on is an integration of the Form Maker with MailChimp which allows to add contacts to your subscription lists just from submitted forms.', WDFMInstance(self::PLUGIN)->prefix)
|
69 |
+
),
|
70 |
+
'registration' => array(
|
71 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
72 |
+
'dir' => 'form-maker-reg/fm_reg.php',
|
73 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/registration.html',
|
74 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/registration.svg',
|
75 |
+
'name' => __('Registration', WDFMInstance(self::PLUGIN)->prefix),
|
76 |
+
'description' => __('User Registration add-on integrates with Form maker forms allowing users to create accounts at your website.', WDFMInstance(self::PLUGIN)->prefix)
|
77 |
+
),
|
78 |
+
'post_generation' => array(
|
79 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
80 |
+
'dir' => 'form-maker-post-generation/fm_post_generation.php',
|
81 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/post-generation.html',
|
82 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/post_generation.svg',
|
83 |
+
'name' => __('Post Generation', WDFMInstance(self::PLUGIN)->prefix),
|
84 |
+
'description' => 'Post Generation add-on allows creating a post, page or custom post based on the submitted data.',
|
85 |
+
),
|
86 |
+
'conditional_emails' => array(
|
87 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
88 |
+
'dir' => 'form-maker-conditional-emails/fm_conditional_emails.php',
|
89 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/conditional-emails.html',
|
90 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/conditional_emails.svg',
|
91 |
+
'name' => __('Conditional Emails', WDFMInstance(self::PLUGIN)->prefix),
|
92 |
+
'description' => __('Conditional Emails add-on allows to send emails to different recipients depending on the submitted data .', WDFMInstance(self::PLUGIN)->prefix)
|
93 |
+
),
|
94 |
+
'dropbox_integration' => array(
|
95 |
+
'pro' => WDFMInstance(self::PLUGIN)->is_free,
|
96 |
+
'dir' => 'form-maker-dropbox-integration/fm_dropbox_integration.php',
|
97 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/dropbox.html',
|
98 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/dropbox_integration.svg',
|
99 |
+
'name' => __('Dropbox Integration', WDFMInstance(self::PLUGIN)->prefix),
|
100 |
+
'description' => __('The Form Maker Dropbox Integration addon is extending the Form Maker capabilities allowing to store the form attachments straight to your Dropbox account.', WDFMInstance(self::PLUGIN)->prefix)
|
101 |
+
),
|
102 |
+
'gdrive_integration' => array(
|
103 |
+
'pro' => WDFMInstance(self::PLUGIN)->is_free,
|
104 |
+
'dir' => 'form-maker-gdrive-integration/fm_gdrive_integration.php',
|
105 |
+
'name' => 'Google Drive Integration',
|
106 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/google-drive.html',
|
107 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/gdrive_integration.svg',
|
108 |
+
'name' => __('Google Drive Integration', WDFMInstance(self::PLUGIN)->prefix),
|
109 |
+
'description' => __('The Google Drive Integration add-on integrates Form Maker with Google Drive and allows you to send the file uploads to the Google Drive', WDFMInstance(self::PLUGIN)->prefix)
|
110 |
+
),
|
111 |
+
'pdf_integration' => array(
|
112 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
113 |
+
'dir' => 'form-maker-pdf-integration/fm_pdf_integration.php',
|
114 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/pdf.html',
|
115 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/pdf_integration.svg',
|
116 |
+
'name' => __('PDF Integration', WDFMInstance(self::PLUGIN)->prefix),
|
117 |
+
'description' => __('The Form Maker PDF Integration add-on allows sending submitted forms in PDF format.', WDFMInstance(self::PLUGIN)->prefix)
|
118 |
+
),
|
119 |
+
'pushover' => array(
|
120 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
121 |
+
'dir' => 'form-maker-pushover/fm_pushover.php',
|
122 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/pushover.html',
|
123 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/pushover.svg',
|
124 |
+
'name' => __('Pushover', WDFMInstance(self::PLUGIN)->prefix),
|
125 |
+
'description' => __('Form Maker Pushover integration allows to receive real-time notifications when a user submits a new form. This means messages can be pushed to Android and Apple devices, as well as desktop notification board.', WDFMInstance(self::PLUGIN)->prefix)
|
126 |
+
),
|
127 |
+
'form-maker-save-progress' => array(
|
128 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
129 |
+
'dir' => 'form-maker-save-progress/fm_save.php',
|
130 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/save-progress.html',
|
131 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/save_progress.svg',
|
132 |
+
'name' => __('Save Progress', WDFMInstance(self::PLUGIN)->prefix),
|
133 |
+
'description' => __('The add-on allows to save filled in forms as draft and continue editing them subsequently.', WDFMInstance(self::PLUGIN)->prefix)
|
134 |
+
),
|
135 |
+
'stripe' => array(
|
136 |
+
'pro' => WDFMInstance(self::PLUGIN)->is_free,
|
137 |
+
'dir' => 'form-maker-stripe/fm_stripe.php',
|
138 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/stripe.html',
|
139 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/stripe.svg',
|
140 |
+
'name' => __('Stripe', WDFMInstance(self::PLUGIN)->prefix),
|
141 |
+
'description' => __('Form Maker Stripe Integration Add-on allows to accept direct payments made by Credit Cards. Users will remain on your website during the entire process.', WDFMInstance(self::PLUGIN)->prefix)
|
142 |
+
),
|
143 |
+
'calculator' => array(
|
144 |
+
'pro' => (WDFMInstance(self::PLUGIN)->is_free == 2),
|
145 |
+
'dir' => 'form-maker-calculator/fm_calculator.php',
|
146 |
+
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/calculator.html',
|
147 |
+
'icon' => WDFMInstance(self::PLUGIN)->plugin_url . '/images/addons/calculator.svg',
|
148 |
+
'name' => __('Calculator', WDFMInstance(self::PLUGIN)->prefix),
|
149 |
+
'description' => __('The Form Maker Calculator add-on allows creating forms with dynamically calculated fields.', WDFMInstance(self::PLUGIN)->prefix)
|
150 |
+
)
|
151 |
+
)
|
152 |
+
);
|
153 |
+
$this->view->display( $params );
|
154 |
+
}
|
155 |
+
}
|
admin/controllers/Blocked_ips_fm.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerBlocked_ips_fmc
|
5 |
*/
|
6 |
-
class FMControllerBlocked_ips_fmc {
|
7 |
private $model;
|
8 |
private $view;
|
9 |
private $bulk_action_name = '';
|
@@ -11,31 +11,31 @@ class FMControllerBlocked_ips_fmc {
|
|
11 |
private $actions = array();
|
12 |
|
13 |
public function __construct() {
|
14 |
-
require_once
|
15 |
-
require_once
|
16 |
$this->model = new FMModelBlocked_ips_fmc();
|
17 |
$this->view = new FMViewBlocked_ips_fmc();
|
18 |
|
19 |
-
$this->page =
|
20 |
|
21 |
$this->bulk_action_name = 'bulk_action';
|
22 |
|
23 |
$this->actions = array(
|
24 |
'delete' => array(
|
25 |
-
'title' => __('Delete',
|
26 |
-
$this->bulk_action_name => __('deleted',
|
27 |
),
|
28 |
);
|
29 |
}
|
30 |
|
31 |
public function execute() {
|
32 |
-
$task =
|
33 |
-
$id = (int)
|
34 |
|
35 |
if ( method_exists($this, $task) ) {
|
36 |
-
check_admin_referer(
|
37 |
$block_action = $this->bulk_action_name;
|
38 |
-
$action =
|
39 |
if ( $action != -1 ) {
|
40 |
$this->$block_action($action);
|
41 |
}
|
@@ -50,8 +50,8 @@ class FMControllerBlocked_ips_fmc {
|
|
50 |
|
51 |
public function display() {
|
52 |
$params = array();
|
53 |
-
$params['order'] =
|
54 |
-
$params['orderby'] =
|
55 |
// To prevent SQL injections.
|
56 |
if ( !in_array($params['orderby'], array( 'id', 'ip' )) ) {
|
57 |
$params['orderby'] = 'id';
|
@@ -78,7 +78,7 @@ class FMControllerBlocked_ips_fmc {
|
|
78 |
public function bulk_action($task) {
|
79 |
$message = 0;
|
80 |
$successfully_updated = 0;
|
81 |
-
$check =
|
82 |
if ( $check ) {
|
83 |
foreach ( $check as $id => $item ) {
|
84 |
if ( method_exists($this, $task) ) {
|
@@ -91,10 +91,10 @@ class FMControllerBlocked_ips_fmc {
|
|
91 |
}
|
92 |
if ( $successfully_updated ) {
|
93 |
$block_action = $this->bulk_action_name;
|
94 |
-
$message = sprintf(_n('%s item successfully %s.', '%s items successfully %s.', $successfully_updated,
|
95 |
}
|
96 |
}
|
97 |
-
|
98 |
'page' => $this->page,
|
99 |
'task' => 'display',
|
100 |
($message === 2 ? 'message' : 'msg') => $message,
|
@@ -103,14 +103,14 @@ class FMControllerBlocked_ips_fmc {
|
|
103 |
|
104 |
public function insert_blocked_ip() {
|
105 |
|
106 |
-
$page =
|
107 |
|
108 |
-
$ip =
|
109 |
|
110 |
$insert = $this->model->insert_fm_blocked(array('ip' => $ip,), array('%s',));
|
111 |
if( !$insert ){
|
112 |
$message = 2;
|
113 |
-
|
114 |
'page' => $page,
|
115 |
'task' => 'display',
|
116 |
'message' => $message,
|
@@ -119,7 +119,7 @@ class FMControllerBlocked_ips_fmc {
|
|
119 |
}
|
120 |
|
121 |
public function delete_blocked_ip( $id ) {
|
122 |
-
$page =
|
123 |
// check id for db
|
124 |
if(isset($id) && $id != "") {
|
125 |
$id = intval($id);
|
@@ -127,7 +127,7 @@ class FMControllerBlocked_ips_fmc {
|
|
127 |
|
128 |
if( !$delete ){
|
129 |
$message = 2;
|
130 |
-
|
131 |
'page' => $page,
|
132 |
'task' => 'display',
|
133 |
'message' => $message,
|
@@ -137,7 +137,7 @@ class FMControllerBlocked_ips_fmc {
|
|
137 |
}
|
138 |
else { // return message Failed
|
139 |
$message = 2;
|
140 |
-
|
141 |
'page' => $page,
|
142 |
'task' => 'display',
|
143 |
'message' => $message,
|
@@ -154,17 +154,17 @@ class FMControllerBlocked_ips_fmc {
|
|
154 |
}
|
155 |
|
156 |
public function update_blocked_ip( $id ) {
|
157 |
-
$page =
|
158 |
|
159 |
// check id for db
|
160 |
if(isset($id) && $id != "") {
|
161 |
$id = intval($id);
|
162 |
-
$ip =
|
163 |
$update = $this->model->update_fm_blocked(array('ip' => $ip,), array('id' => $id));
|
164 |
|
165 |
if( !$update ){
|
166 |
$message = 2;
|
167 |
-
|
168 |
'page' => $page,
|
169 |
'task' => 'display',
|
170 |
'message' => $message,
|
@@ -174,7 +174,7 @@ class FMControllerBlocked_ips_fmc {
|
|
174 |
}
|
175 |
else { // return message Failed
|
176 |
$message = 2;
|
177 |
-
|
178 |
'page' => $page,
|
179 |
'task' => 'display',
|
180 |
'message' => $message,
|
@@ -195,7 +195,7 @@ class FMControllerBlocked_ips_fmc {
|
|
195 |
return $message;
|
196 |
}
|
197 |
else {
|
198 |
-
|
199 |
'page' => $this->page,
|
200 |
'task' => 'display',
|
201 |
'message' => $message,
|
@@ -205,8 +205,8 @@ class FMControllerBlocked_ips_fmc {
|
|
205 |
|
206 |
public function save() {
|
207 |
$message = $this->save_db();
|
208 |
-
$page =
|
209 |
-
|
210 |
'page' => $page,
|
211 |
'task' => 'display',
|
212 |
'message' => $message,
|
@@ -260,8 +260,8 @@ class FMControllerBlocked_ips_fmc {
|
|
260 |
else {
|
261 |
$message = 0;
|
262 |
}
|
263 |
-
$page =
|
264 |
-
|
265 |
'page' => $page,
|
266 |
'task' => 'display',
|
267 |
'message' => $message,
|
3 |
/**
|
4 |
* Class FMControllerBlocked_ips_fmc
|
5 |
*/
|
6 |
+
class FMControllerBlocked_ips_fmc extends CFMAdminController {
|
7 |
private $model;
|
8 |
private $view;
|
9 |
private $bulk_action_name = '';
|
11 |
private $actions = array();
|
12 |
|
13 |
public function __construct() {
|
14 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/Blocked_ips_fm.php";
|
15 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Blocked_ips_fm.php";
|
16 |
$this->model = new FMModelBlocked_ips_fmc();
|
17 |
$this->view = new FMViewBlocked_ips_fmc();
|
18 |
|
19 |
+
$this->page = WDW_FM_Library(self::PLUGIN)->get('page');
|
20 |
|
21 |
$this->bulk_action_name = 'bulk_action';
|
22 |
|
23 |
$this->actions = array(
|
24 |
'delete' => array(
|
25 |
+
'title' => __('Delete', WDFMInstance(self::PLUGIN)->prefix),
|
26 |
+
$this->bulk_action_name => __('deleted', WDFMInstance(self::PLUGIN)->prefix),
|
27 |
),
|
28 |
);
|
29 |
}
|
30 |
|
31 |
public function execute() {
|
32 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task');
|
33 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
34 |
|
35 |
if ( method_exists($this, $task) ) {
|
36 |
+
check_admin_referer(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce);
|
37 |
$block_action = $this->bulk_action_name;
|
38 |
+
$action = WDW_FM_Library(self::PLUGIN)->get( $block_action, -1 );
|
39 |
if ( $action != -1 ) {
|
40 |
$this->$block_action($action);
|
41 |
}
|
50 |
|
51 |
public function display() {
|
52 |
$params = array();
|
53 |
+
$params['order'] = WDW_FM_Library(self::PLUGIN)->get('order', 'desc');
|
54 |
+
$params['orderby'] = WDW_FM_Library(self::PLUGIN)->get('orderby', 'id');
|
55 |
// To prevent SQL injections.
|
56 |
if ( !in_array($params['orderby'], array( 'id', 'ip' )) ) {
|
57 |
$params['orderby'] = 'id';
|
78 |
public function bulk_action($task) {
|
79 |
$message = 0;
|
80 |
$successfully_updated = 0;
|
81 |
+
$check = WDW_FM_Library(self::PLUGIN)->get('check', '');
|
82 |
if ( $check ) {
|
83 |
foreach ( $check as $id => $item ) {
|
84 |
if ( method_exists($this, $task) ) {
|
91 |
}
|
92 |
if ( $successfully_updated ) {
|
93 |
$block_action = $this->bulk_action_name;
|
94 |
+
$message = sprintf(_n('%s item successfully %s.', '%s items successfully %s.', $successfully_updated, WDFMInstance(self::PLUGIN)->prefix), $successfully_updated, $this->actions[$task][$block_action]);
|
95 |
}
|
96 |
}
|
97 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
98 |
'page' => $this->page,
|
99 |
'task' => 'display',
|
100 |
($message === 2 ? 'message' : 'msg') => $message,
|
103 |
|
104 |
public function insert_blocked_ip() {
|
105 |
|
106 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
107 |
|
108 |
+
$ip = WDW_FM_Library(self::PLUGIN)->get('ip','');
|
109 |
|
110 |
$insert = $this->model->insert_fm_blocked(array('ip' => $ip,), array('%s',));
|
111 |
if( !$insert ){
|
112 |
$message = 2;
|
113 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
114 |
'page' => $page,
|
115 |
'task' => 'display',
|
116 |
'message' => $message,
|
119 |
}
|
120 |
|
121 |
public function delete_blocked_ip( $id ) {
|
122 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
123 |
// check id for db
|
124 |
if(isset($id) && $id != "") {
|
125 |
$id = intval($id);
|
127 |
|
128 |
if( !$delete ){
|
129 |
$message = 2;
|
130 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
131 |
'page' => $page,
|
132 |
'task' => 'display',
|
133 |
'message' => $message,
|
137 |
}
|
138 |
else { // return message Failed
|
139 |
$message = 2;
|
140 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
141 |
'page' => $page,
|
142 |
'task' => 'display',
|
143 |
'message' => $message,
|
154 |
}
|
155 |
|
156 |
public function update_blocked_ip( $id ) {
|
157 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
158 |
|
159 |
// check id for db
|
160 |
if(isset($id) && $id != "") {
|
161 |
$id = intval($id);
|
162 |
+
$ip = WDW_FM_Library(self::PLUGIN)->get('ip', '');
|
163 |
$update = $this->model->update_fm_blocked(array('ip' => $ip,), array('id' => $id));
|
164 |
|
165 |
if( !$update ){
|
166 |
$message = 2;
|
167 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
168 |
'page' => $page,
|
169 |
'task' => 'display',
|
170 |
'message' => $message,
|
174 |
}
|
175 |
else { // return message Failed
|
176 |
$message = 2;
|
177 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
178 |
'page' => $page,
|
179 |
'task' => 'display',
|
180 |
'message' => $message,
|
195 |
return $message;
|
196 |
}
|
197 |
else {
|
198 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
199 |
'page' => $this->page,
|
200 |
'task' => 'display',
|
201 |
'message' => $message,
|
205 |
|
206 |
public function save() {
|
207 |
$message = $this->save_db();
|
208 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
209 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
210 |
'page' => $page,
|
211 |
'task' => 'display',
|
212 |
'message' => $message,
|
260 |
else {
|
261 |
$message = 0;
|
262 |
}
|
263 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
264 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
265 |
'page' => $page,
|
266 |
'task' => 'display',
|
267 |
'message' => $message,
|
admin/controllers/Checkpaypal.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerCheckpaypal
|
5 |
*/
|
6 |
-
class FMControllerCheckpaypal {
|
7 |
/**
|
8 |
* @var $model
|
9 |
*/
|
@@ -18,10 +18,10 @@ class FMControllerCheckpaypal {
|
|
18 |
*/
|
19 |
public function __construct() {
|
20 |
// Load FMModelCheckpaypal class.
|
21 |
-
require_once
|
22 |
$this->model = new FMModelCheckpaypal();
|
23 |
// Load FMViewCheckpaypal class.
|
24 |
-
require_once
|
25 |
$this->view = new FMViewCheckpaypal();
|
26 |
}
|
27 |
|
@@ -37,10 +37,10 @@ class FMControllerCheckpaypal {
|
|
37 |
*/
|
38 |
public function display() {
|
39 |
// Get form by id.
|
40 |
-
$form_id =
|
41 |
$form = $this->model->get_form_by_id($form_id);
|
42 |
// Get form session by group id.
|
43 |
-
$group_id =
|
44 |
$form_session = $this->model->get_form_session_by_group_id($group_id);
|
45 |
// Connect to paypal.
|
46 |
$post_fields = '';
|
@@ -52,10 +52,10 @@ class FMControllerCheckpaypal {
|
|
52 |
$post_fields .= 'cmd=_notify-validate';
|
53 |
$paypal_params = array( 'checkout_mode' => $form->checkout_mode, 'post_fields' => $post_fields );
|
54 |
$response = $this->model->connect_to_paypal($paypal_params);
|
55 |
-
$tax =
|
56 |
-
$total =
|
57 |
-
$shipping =
|
58 |
-
$payment_status =
|
59 |
// Update payment status for formmaker_submits table.
|
60 |
$this->model->update_submission_status($payment_status, $group_id);
|
61 |
$form_currency = '$';
|
@@ -115,28 +115,28 @@ class FMControllerCheckpaypal {
|
|
115 |
$form_currency = $currency_sign[array_search($payment_currency, $currency_code)];
|
116 |
}
|
117 |
$currency = $payment_currency . $form_currency;
|
118 |
-
$email =
|
119 |
-
$first_name =
|
120 |
-
$last_name =
|
121 |
$full_name = (($first_name != '') ? $first_name : '') . (($last_name != '') ? ' ' . $last_name : '');
|
122 |
-
$phone_a =
|
123 |
-
$phone_b =
|
124 |
-
$phone_c =
|
125 |
$phone = (($phone_a != '') ? $phone_a : '') . (($phone_b != '') ? ' - ' . $phone_b : '') . (($phone_c != '') ? ' - ' . $phone_c : '');
|
126 |
$address = '';
|
127 |
-
$address .= (
|
128 |
-
$address .= (
|
129 |
-
$address .= (
|
130 |
-
$address .= (
|
131 |
-
$address .= (
|
132 |
-
$address .= (
|
133 |
-
$address .= (
|
134 |
$paypal_info = "";
|
135 |
-
$paypal_info .= (
|
136 |
-
$paypal_info .= (
|
137 |
-
$paypal_info .= (
|
138 |
-
$paypal_info .= (
|
139 |
-
$paypal_info .= (
|
140 |
$post = array(
|
141 |
'form_id' => $form_id,
|
142 |
'group_id' => $group_id,
|
@@ -165,14 +165,14 @@ class FMControllerCheckpaypal {
|
|
165 |
if ( !empty($form_session) ) {
|
166 |
$recipient = $form->mail ? $form->mail : '';
|
167 |
if ( $recipient ) {
|
168 |
-
$subject = __("Payment information",
|
169 |
// Get template for payment information.
|
170 |
$template_params = array( 'form_session' => $form_session, 'data' => $post );
|
171 |
$message = $this->view->payment_information_template($template_params);
|
172 |
$header_arr = array();
|
173 |
$header_arr['content_type'] = "text/html";
|
174 |
$header_arr['charset'] = 'UTF-8';
|
175 |
-
|
176 |
}
|
177 |
}
|
178 |
|
3 |
/**
|
4 |
* Class FMControllerCheckpaypal
|
5 |
*/
|
6 |
+
class FMControllerCheckpaypal extends FMAdminController {
|
7 |
/**
|
8 |
* @var $model
|
9 |
*/
|
18 |
*/
|
19 |
public function __construct() {
|
20 |
// Load FMModelCheckpaypal class.
|
21 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/Checkpaypal.php";
|
22 |
$this->model = new FMModelCheckpaypal();
|
23 |
// Load FMViewCheckpaypal class.
|
24 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Checkpaypal.php";
|
25 |
$this->view = new FMViewCheckpaypal();
|
26 |
}
|
27 |
|
37 |
*/
|
38 |
public function display() {
|
39 |
// Get form by id.
|
40 |
+
$form_id = WDW_FM_Library(self::PLUGIN)->get('form_id', 0);
|
41 |
$form = $this->model->get_form_by_id($form_id);
|
42 |
// Get form session by group id.
|
43 |
+
$group_id = WDW_FM_Library(self::PLUGIN)->get('group_id', 0);
|
44 |
$form_session = $this->model->get_form_session_by_group_id($group_id);
|
45 |
// Connect to paypal.
|
46 |
$post_fields = '';
|
52 |
$post_fields .= 'cmd=_notify-validate';
|
53 |
$paypal_params = array( 'checkout_mode' => $form->checkout_mode, 'post_fields' => $post_fields );
|
54 |
$response = $this->model->connect_to_paypal($paypal_params);
|
55 |
+
$tax = WDW_FM_Library(self::PLUGIN)->get('tax', 0);
|
56 |
+
$total = WDW_FM_Library(self::PLUGIN)->get('mc_gross', 0);
|
57 |
+
$shipping = WDW_FM_Library(self::PLUGIN)->get('mc_shipping', 0);
|
58 |
+
$payment_status = WDW_FM_Library(self::PLUGIN)->get('payment_status', 0);
|
59 |
// Update payment status for formmaker_submits table.
|
60 |
$this->model->update_submission_status($payment_status, $group_id);
|
61 |
$form_currency = '$';
|
115 |
$form_currency = $currency_sign[array_search($payment_currency, $currency_code)];
|
116 |
}
|
117 |
$currency = $payment_currency . $form_currency;
|
118 |
+
$email = WDW_FM_Library(self::PLUGIN)->get('payer_email', '');
|
119 |
+
$first_name = WDW_FM_Library(self::PLUGIN)->get('first_name', '');
|
120 |
+
$last_name = WDW_FM_Library(self::PLUGIN)->get('last_name', '');
|
121 |
$full_name = (($first_name != '') ? $first_name : '') . (($last_name != '') ? ' ' . $last_name : '');
|
122 |
+
$phone_a = WDW_FM_Library(self::PLUGIN)->get('night_phone_a', '');
|
123 |
+
$phone_b = WDW_FM_Library(self::PLUGIN)->get('night_phone_b', '');
|
124 |
+
$phone_c = WDW_FM_Library(self::PLUGIN)->get('night_phone_c', '');
|
125 |
$phone = (($phone_a != '') ? $phone_a : '') . (($phone_b != '') ? ' - ' . $phone_b : '') . (($phone_c != '') ? ' - ' . $phone_c : '');
|
126 |
$address = '';
|
127 |
+
$address .= (WDW_FM_Library(self::PLUGIN)->get('address_country', '') != '') ? "Country: " . WDW_FM_Library(self::PLUGIN)->get('address_country', '') : '';
|
128 |
+
$address .= (WDW_FM_Library(self::PLUGIN)->get('address_state', '') != '') ? "<br>State: " . WDW_FM_Library(self::PLUGIN)->get('address_state', '') : '';
|
129 |
+
$address .= (WDW_FM_Library(self::PLUGIN)->get('address_city', '') != '') ? "<br>City: " . WDW_FM_Library(self::PLUGIN)->get('address_city', '') : '';
|
130 |
+
$address .= (WDW_FM_Library(self::PLUGIN)->get('address_street', '') != '') ? "<br>Street: " . WDW_FM_Library(self::PLUGIN)->get('address_street', '') : '';
|
131 |
+
$address .= (WDW_FM_Library(self::PLUGIN)->get('address_zip', '') != '') ? "<br>Zip Code: " . WDW_FM_Library(self::PLUGIN)->get('address_zip', '') : '';
|
132 |
+
$address .= (WDW_FM_Library(self::PLUGIN)->get('address_status', '') != '') ? "<br>Address Status: " . WDW_FM_Library(self::PLUGIN)->get('address_status', '') : '';
|
133 |
+
$address .= (WDW_FM_Library(self::PLUGIN)->get('address_name', '') != '') ? "<br>Name: " . WDW_FM_Library(self::PLUGIN)->get('address_name', '') : '';
|
134 |
$paypal_info = "";
|
135 |
+
$paypal_info .= (WDW_FM_Library(self::PLUGIN)->get('payer_status', '') != '') ? "<br>Payer Status - " . WDW_FM_Library(self::PLUGIN)->get('payer_status', '') : '';
|
136 |
+
$paypal_info .= (WDW_FM_Library(self::PLUGIN)->get('payer_email', '') != '') ? "<br>Payer Email - " . WDW_FM_Library(self::PLUGIN)->get('payer_email', '') : '';
|
137 |
+
$paypal_info .= (WDW_FM_Library(self::PLUGIN)->get('txn_id', '') != '') ? "<br>Transaction - " . WDW_FM_Library(self::PLUGIN)->get('txn_id', '') : '';
|
138 |
+
$paypal_info .= (WDW_FM_Library(self::PLUGIN)->get('payment_type', '') != '') ? "<br>Payment Type - " . WDW_FM_Library(self::PLUGIN)->get('payment_type', '') : '';
|
139 |
+
$paypal_info .= (WDW_FM_Library(self::PLUGIN)->get('residence_country', '') != '') ? "<br>Residence Country - " . WDW_FM_Library(self::PLUGIN)->get('residence_country', '') : '';
|
140 |
$post = array(
|
141 |
'form_id' => $form_id,
|
142 |
'group_id' => $group_id,
|
165 |
if ( !empty($form_session) ) {
|
166 |
$recipient = $form->mail ? $form->mail : '';
|
167 |
if ( $recipient ) {
|
168 |
+
$subject = __("Payment information", WDFMInstance(self::PLUGIN)->prefix);
|
169 |
// Get template for payment information.
|
170 |
$template_params = array( 'form_session' => $form_session, 'data' => $post );
|
171 |
$message = $this->view->payment_information_template($template_params);
|
172 |
$header_arr = array();
|
173 |
$header_arr['content_type'] = "text/html";
|
174 |
$header_arr['charset'] = 'UTF-8';
|
175 |
+
WDW_FM_Library(self::PLUGIN)->mail($recipient, $subject, $message, $header_arr);
|
176 |
}
|
177 |
}
|
178 |
|
admin/controllers/FMShortocde.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerFMShortocde
|
5 |
*/
|
6 |
-
class FMControllerFMShortocde_fmc {
|
7 |
private $model;
|
8 |
private $view;
|
9 |
|
@@ -11,10 +11,10 @@ class FMControllerFMShortocde_fmc {
|
|
11 |
* FMControllerFMShortocde constructor.
|
12 |
*/
|
13 |
public function __construct() {
|
14 |
-
require_once
|
15 |
$this->model = new FMModelFMShortocde_fmc();
|
16 |
|
17 |
-
require_once
|
18 |
$this->view = new FMViewFMShortocde_fmc();
|
19 |
}
|
20 |
|
@@ -22,7 +22,7 @@ class FMControllerFMShortocde_fmc {
|
|
22 |
* Execute.
|
23 |
*/
|
24 |
public function execute() {
|
25 |
-
$task =
|
26 |
$this->display($task);
|
27 |
}
|
28 |
|
3 |
/**
|
4 |
* Class FMControllerFMShortocde
|
5 |
*/
|
6 |
+
class FMControllerFMShortocde_fmc extends CFMAdminController {
|
7 |
private $model;
|
8 |
private $view;
|
9 |
|
11 |
* FMControllerFMShortocde constructor.
|
12 |
*/
|
13 |
public function __construct() {
|
14 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/FMShortocde.php";
|
15 |
$this->model = new FMModelFMShortocde_fmc();
|
16 |
|
17 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMShortocde.php";
|
18 |
$this->view = new FMViewFMShortocde_fmc();
|
19 |
}
|
20 |
|
22 |
* Execute.
|
23 |
*/
|
24 |
public function execute() {
|
25 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task');
|
26 |
$this->display($task);
|
27 |
}
|
28 |
|
admin/controllers/FormMakerEditCountryinPopup.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerFormmakereditcountryinpopup_fmc
|
5 |
*/
|
6 |
-
class FMControllerFormmakereditcountryinpopup_fmc {
|
7 |
/**
|
8 |
* @var $view
|
9 |
*/
|
@@ -21,11 +21,11 @@ class FMControllerFormmakereditcountryinpopup_fmc {
|
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewFromeditcountryinpopup class.
|
24 |
-
require_once
|
25 |
$this->view = new FMViewFromeditcountryinpopup_fmc();
|
26 |
// Set params for view.
|
27 |
$params = array();
|
28 |
-
$params['field_id'] =
|
29 |
$this->view->display($params);
|
30 |
}
|
31 |
}
|
3 |
/**
|
4 |
* Class FMControllerFormmakereditcountryinpopup_fmc
|
5 |
*/
|
6 |
+
class FMControllerFormmakereditcountryinpopup_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* @var $view
|
9 |
*/
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewFromeditcountryinpopup class.
|
24 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMEditCountryinPopup.php";
|
25 |
$this->view = new FMViewFromeditcountryinpopup_fmc();
|
26 |
// Set params for view.
|
27 |
$params = array();
|
28 |
+
$params['field_id'] = WDW_FM_Library(self::PLUGIN)->get('field_id', 0);
|
29 |
$this->view->display($params);
|
30 |
}
|
31 |
}
|
admin/controllers/FormMakerIpinfoinPopup.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerFormmakeripinfoinpopup_fmc
|
5 |
*/
|
6 |
-
class FMControllerFormmakeripinfoinpopup_fmc {
|
7 |
/**
|
8 |
* @var view
|
9 |
*/
|
@@ -21,10 +21,10 @@ class FMControllerFormmakeripinfoinpopup_fmc {
|
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewFromipinfoinpopup class.
|
24 |
-
require_once
|
25 |
$this->view = new FMViewFromipinfoinpopup_fmc();
|
26 |
// Get IP
|
27 |
-
$ip =
|
28 |
// Connect to IP api service and get IP info.
|
29 |
$ipinfo = @unserialize(file_get_contents('http://ip-api.com/php/' . $ip));
|
30 |
$city = '-';
|
@@ -38,7 +38,7 @@ class FMControllerFormmakeripinfoinpopup_fmc {
|
|
38 |
$city = $ipinfo['city'];
|
39 |
$country = $ipinfo['country'];
|
40 |
$countryCode = $ipinfo['countryCode'];
|
41 |
-
$country_flag = '<img width="16px" src="' .
|
42 |
$timezone = $ipinfo['timezone'];
|
43 |
$lat = $ipinfo['lat'];
|
44 |
$lon = $ipinfo['lon'];
|
3 |
/**
|
4 |
* Class FMControllerFormmakeripinfoinpopup_fmc
|
5 |
*/
|
6 |
+
class FMControllerFormmakeripinfoinpopup_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* @var view
|
9 |
*/
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewFromipinfoinpopup class.
|
24 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMIpinfoinPopup.php";
|
25 |
$this->view = new FMViewFromipinfoinpopup_fmc();
|
26 |
// Get IP
|
27 |
+
$ip = WDW_FM_Library(self::PLUGIN)->get('data_ip', '');
|
28 |
// Connect to IP api service and get IP info.
|
29 |
$ipinfo = @unserialize(file_get_contents('http://ip-api.com/php/' . $ip));
|
30 |
$city = '-';
|
38 |
$city = $ipinfo['city'];
|
39 |
$country = $ipinfo['country'];
|
40 |
$countryCode = $ipinfo['countryCode'];
|
41 |
+
$country_flag = '<img width="16px" src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/flags/' . strtolower($ipinfo['countryCode']) . '.png" class="sub-align" alt="' . $ipinfo['country'] . '" title="' . $ipinfo['country'] . '" />';
|
42 |
$timezone = $ipinfo['timezone'];
|
43 |
$lat = $ipinfo['lat'];
|
44 |
$lon = $ipinfo['lon'];
|
admin/controllers/FormMakerMapEditinPopup.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerFormmakermapeditinpopup_fmc
|
5 |
*/
|
6 |
-
class FMControllerFormmakermapeditinpopup_fmc {
|
7 |
/**
|
8 |
* @var view
|
9 |
*/
|
@@ -21,15 +21,15 @@ class FMControllerFormmakermapeditinpopup_fmc {
|
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewFrommapeditinpopup class.
|
24 |
-
require_once
|
25 |
$this->view = new FMViewFrommapeditinpopup_fmc();
|
26 |
// Get form maker settings.
|
27 |
-
$fm_settings = get_option('fmc_settings');
|
28 |
// Set params for view.
|
29 |
$params = array();
|
30 |
$params['map_key'] = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
31 |
-
$params['long'] =
|
32 |
-
$params['lat'] =
|
33 |
$this->view->display($params);
|
34 |
}
|
35 |
}
|
3 |
/**
|
4 |
* Class FMControllerFormmakermapeditinpopup_fmc
|
5 |
*/
|
6 |
+
class FMControllerFormmakermapeditinpopup_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* @var view
|
9 |
*/
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewFrommapeditinpopup class.
|
24 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMMapEditinPopup.php";
|
25 |
$this->view = new FMViewFrommapeditinpopup_fmc();
|
26 |
// Get form maker settings.
|
27 |
+
$fm_settings = get_option(WDFMInstance(self::PLUGIN)->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
28 |
// Set params for view.
|
29 |
$params = array();
|
30 |
$params['map_key'] = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
31 |
+
$params['long'] = WDW_FM_Library(self::PLUGIN)->get('long', 0);
|
32 |
+
$params['lat'] = WDW_FM_Library(self::PLUGIN)->get('lat', 0);
|
33 |
$this->view->display($params);
|
34 |
}
|
35 |
}
|
admin/controllers/FormMakerSQLMapping.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerFormMakerSQLMapping_fmc
|
5 |
*/
|
6 |
-
class FMControllerFormMakerSQLMapping_fmc {
|
7 |
/**
|
8 |
* @var $model
|
9 |
*/
|
@@ -18,10 +18,10 @@ class FMControllerFormMakerSQLMapping_fmc {
|
|
18 |
*/
|
19 |
public function __construct() {
|
20 |
// Load FMModelFormMakerSQLMapping class.
|
21 |
-
require_once
|
22 |
$this->model = new FMModelFormMakerSQLMapping_fmc();
|
23 |
// Load FMViewFormMakerSQLMapping class.
|
24 |
-
require_once
|
25 |
$this->view = new FMViewFormMakerSQLMapping_fmc();
|
26 |
}
|
27 |
|
@@ -29,9 +29,9 @@ class FMControllerFormMakerSQLMapping_fmc {
|
|
29 |
* Execute.
|
30 |
*/
|
31 |
public function execute() {
|
32 |
-
$id =
|
33 |
-
$form_id =
|
34 |
-
$task =
|
35 |
if ( $task && method_exists($this, $task) ) {
|
36 |
$this->$task($form_id);
|
37 |
}
|
@@ -122,7 +122,7 @@ class FMControllerFormMakerSQLMapping_fmc {
|
|
122 |
* @param int $form_id
|
123 |
*/
|
124 |
public function db_table_struct( $form_id ) {
|
125 |
-
$con_method =
|
126 |
// Get labels by form id.
|
127 |
$label = $this->model->get_labels($form_id);
|
128 |
// Get table struct.
|
3 |
/**
|
4 |
* Class FMControllerFormMakerSQLMapping_fmc
|
5 |
*/
|
6 |
+
class FMControllerFormMakerSQLMapping_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* @var $model
|
9 |
*/
|
18 |
*/
|
19 |
public function __construct() {
|
20 |
// Load FMModelFormMakerSQLMapping class.
|
21 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/FMSqlMapping.php";
|
22 |
$this->model = new FMModelFormMakerSQLMapping_fmc();
|
23 |
// Load FMViewFormMakerSQLMapping class.
|
24 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMSqlMapping.php";
|
25 |
$this->view = new FMViewFormMakerSQLMapping_fmc();
|
26 |
}
|
27 |
|
29 |
* Execute.
|
30 |
*/
|
31 |
public function execute() {
|
32 |
+
$id = WDW_FM_Library(self::PLUGIN)->get('id', '');
|
33 |
+
$form_id = WDW_FM_Library(self::PLUGIN)->get('form_id', '');
|
34 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task', '');
|
35 |
if ( $task && method_exists($this, $task) ) {
|
36 |
$this->$task($form_id);
|
37 |
}
|
122 |
* @param int $form_id
|
123 |
*/
|
124 |
public function db_table_struct( $form_id ) {
|
125 |
+
$con_method = WDW_FM_Library(self::PLUGIN)->get('con_method', '');
|
126 |
// Get labels by form id.
|
127 |
$label = $this->model->get_labels($form_id);
|
128 |
// Get table struct.
|
admin/controllers/FormMakerSubmits.php
CHANGED
@@ -3,14 +3,14 @@
|
|
3 |
/**
|
4 |
* Class FMControllerFormMakerSubmits_fmc
|
5 |
*/
|
6 |
-
class FMControllerFormMakerSubmits_fmc {
|
7 |
private $model;
|
8 |
private $view;
|
9 |
|
10 |
public function __construct() {
|
11 |
-
require_once
|
12 |
$this->model = new FMModelFormMakerSubmits_fmc();
|
13 |
-
require_once
|
14 |
$this->view = new FMViewFormMakerSubmits_fmc();
|
15 |
}
|
16 |
|
3 |
/**
|
4 |
* Class FMControllerFormMakerSubmits_fmc
|
5 |
*/
|
6 |
+
class FMControllerFormMakerSubmits_fmc extends CFMAdminController {
|
7 |
private $model;
|
8 |
private $view;
|
9 |
|
10 |
public function __construct() {
|
11 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/FormMakerSubmits.php";
|
12 |
$this->model = new FMModelFormMakerSubmits_fmc();
|
13 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FormMakerSubmits.php";
|
14 |
$this->view = new FMViewFormMakerSubmits_fmc();
|
15 |
}
|
16 |
|
admin/controllers/Formmakerwdcaptcha.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/**
|
3 |
* Class FMControllerFormmakerwdcaptcha_fmc
|
4 |
*/
|
5 |
-
class FMControllerFormmakerwdcaptcha_fmc {
|
6 |
/**
|
7 |
* @var view
|
8 |
*/
|
@@ -20,7 +20,7 @@ class FMControllerFormmakerwdcaptcha_fmc {
|
|
20 |
*/
|
21 |
public function display() {
|
22 |
// Load FMViewFormmakerwdcaptcha class.
|
23 |
-
require_once
|
24 |
$this->view = new FMViewFormmakerwdcaptcha_fmc();
|
25 |
// Set params for view.
|
26 |
$params = array();
|
2 |
/**
|
3 |
* Class FMControllerFormmakerwdcaptcha_fmc
|
4 |
*/
|
5 |
+
class FMControllerFormmakerwdcaptcha_fmc extends CFMAdminController {
|
6 |
/**
|
7 |
* @var view
|
8 |
*/
|
20 |
*/
|
21 |
public function display() {
|
22 |
// Load FMViewFormmakerwdcaptcha class.
|
23 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMCaptcha.php";
|
24 |
$this->view = new FMViewFormmakerwdcaptcha_fmc();
|
25 |
// Set params for view.
|
26 |
$params = array();
|
admin/controllers/Formmakerwdmathcaptcha.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerFormmakerwdmathcaptcha_fmc
|
5 |
*/
|
6 |
-
class FMControllerFormmakerwdmathcaptcha_fmc {
|
7 |
/**
|
8 |
* @var $view
|
9 |
*/
|
@@ -21,7 +21,7 @@ class FMControllerFormmakerwdmathcaptcha_fmc {
|
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewFormmakerwdmathcaptcha class.
|
24 |
-
require_once
|
25 |
$this->view = new FMViewFormmakerwdmathcaptcha_fmc();
|
26 |
// Set params for view.
|
27 |
$params = array();
|
3 |
/**
|
4 |
* Class FMControllerFormmakerwdmathcaptcha_fmc
|
5 |
*/
|
6 |
+
class FMControllerFormmakerwdmathcaptcha_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* @var $view
|
9 |
*/
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewFormmakerwdmathcaptcha class.
|
24 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMMathCaptcha.php";
|
25 |
$this->view = new FMViewFormmakerwdmathcaptcha_fmc();
|
26 |
// Set params for view.
|
27 |
$params = array();
|
admin/controllers/Generete_csv.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerGenerete_csv_fmc
|
5 |
*/
|
6 |
-
class FMControllerGenerete_csv_fmc {
|
7 |
/**
|
8 |
* Execute.
|
9 |
*/
|
@@ -16,16 +16,16 @@ class FMControllerGenerete_csv_fmc {
|
|
16 |
*/
|
17 |
public function display() {
|
18 |
// Get form maker settings
|
19 |
-
$fm_settings = get_option('fmc_settings');
|
20 |
$csv_delimiter = isset($fm_settings['csv_delimiter']) ? $fm_settings['csv_delimiter'] : ',';
|
21 |
$form_id = (int) $_REQUEST['form_id'];
|
22 |
$limitstart = (int) $_REQUEST['limitstart'];
|
23 |
$send_header = (int) $_REQUEST['send_header'];
|
24 |
-
$params =
|
25 |
$data = $params[0];
|
26 |
$title = $params[1];
|
27 |
|
28 |
-
$labels_parameters =
|
29 |
|
30 |
$sorted_label_names_original = $labels_parameters[4];
|
31 |
$sorted_label_names_original = array_merge(array(
|
@@ -86,9 +86,15 @@ class FMControllerGenerete_csv_fmc {
|
|
86 |
$output = fopen($tempfile, "a");
|
87 |
|
88 |
if ( $limitstart == 0 ) {
|
|
|
|
|
|
|
89 |
fputcsv($output, $sorted_label_names_original, $csv_delimiter);
|
90 |
}
|
91 |
foreach ( $data as $record ) {
|
|
|
|
|
|
|
92 |
fputcsv($output, $record, $csv_delimiter);
|
93 |
}
|
94 |
|
3 |
/**
|
4 |
* Class FMControllerGenerete_csv_fmc
|
5 |
*/
|
6 |
+
class FMControllerGenerete_csv_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* Execute.
|
9 |
*/
|
16 |
*/
|
17 |
public function display() {
|
18 |
// Get form maker settings
|
19 |
+
$fm_settings = get_option(WDFMInstance(self::PLUGIN)->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
20 |
$csv_delimiter = isset($fm_settings['csv_delimiter']) ? $fm_settings['csv_delimiter'] : ',';
|
21 |
$form_id = (int) $_REQUEST['form_id'];
|
22 |
$limitstart = (int) $_REQUEST['limitstart'];
|
23 |
$send_header = (int) $_REQUEST['send_header'];
|
24 |
+
$params = WDW_FM_Library(self::PLUGIN)->get_submissions_to_export();
|
25 |
$data = $params[0];
|
26 |
$title = $params[1];
|
27 |
|
28 |
+
$labels_parameters = WDW_FM_Library(self::PLUGIN)->get_labels_parameters( $form_id );
|
29 |
|
30 |
$sorted_label_names_original = $labels_parameters[4];
|
31 |
$sorted_label_names_original = array_merge(array(
|
86 |
$output = fopen($tempfile, "a");
|
87 |
|
88 |
if ( $limitstart == 0 ) {
|
89 |
+
foreach ($sorted_label_names_original as $i => $rec) {
|
90 |
+
$sorted_label_names_original[$i] = ltrim($rec, '=+-@');
|
91 |
+
}
|
92 |
fputcsv($output, $sorted_label_names_original, $csv_delimiter);
|
93 |
}
|
94 |
foreach ( $data as $record ) {
|
95 |
+
foreach ($record as $i => $rec) {
|
96 |
+
$record[$i] = ltrim($rec, '=+-@');
|
97 |
+
}
|
98 |
fputcsv($output, $record, $csv_delimiter);
|
99 |
}
|
100 |
|
admin/controllers/Generete_xml.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerGenerete_xml_fmc
|
5 |
*/
|
6 |
-
class FMControllerGenerete_xml_fmc {
|
7 |
/**
|
8 |
* Execute.
|
9 |
*/
|
@@ -15,7 +15,7 @@ class FMControllerGenerete_xml_fmc {
|
|
15 |
$form_id = (int) $_REQUEST['form_id'];
|
16 |
$limitstart = (int) $_REQUEST['limitstart'];
|
17 |
$send_header = (int) $_REQUEST['send_header'];
|
18 |
-
$params =
|
19 |
$data = $params[0];
|
20 |
$title = $params[1];
|
21 |
define('PHP_TAB', "\t");
|
3 |
/**
|
4 |
* Class FMControllerGenerete_xml_fmc
|
5 |
*/
|
6 |
+
class FMControllerGenerete_xml_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* Execute.
|
9 |
*/
|
15 |
$form_id = (int) $_REQUEST['form_id'];
|
16 |
$limitstart = (int) $_REQUEST['limitstart'];
|
17 |
$send_header = (int) $_REQUEST['send_header'];
|
18 |
+
$params = WDW_FM_Library(self::PLUGIN)->get_submissions_to_export();
|
19 |
$data = $params[0];
|
20 |
$title = $params[1];
|
21 |
define('PHP_TAB', "\t");
|
admin/controllers/Licensing_fm.php
DELETED
@@ -1,26 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
/**
|
4 |
-
* Class FMControllerLicensing_fmc
|
5 |
-
*/
|
6 |
-
class FMControllerLicensing_fmc {
|
7 |
-
private $view;
|
8 |
-
public function __construct() {
|
9 |
-
require_once WDCFM()->plugin_dir . "/admin/views/Licensing_fm.php";
|
10 |
-
$this->view = new FMViewLicensing_fmc();
|
11 |
-
}
|
12 |
-
public function execute() {
|
13 |
-
$task = WDW_FMC_Library::get('task');
|
14 |
-
$id = (int) WDW_FMC_Library::get('current_id', 0);
|
15 |
-
if (method_exists($this, $task)) {
|
16 |
-
$this->$task($id);
|
17 |
-
}
|
18 |
-
else {
|
19 |
-
$this->display();
|
20 |
-
}
|
21 |
-
}
|
22 |
-
|
23 |
-
public function display() {
|
24 |
-
$this->view->display();
|
25 |
-
}
|
26 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
admin/controllers/Manage_fm.php
CHANGED
@@ -1,5 +1,5 @@
|
|
1 |
<?php
|
2 |
-
class FMControllerManage_fmc {
|
3 |
private $model;
|
4 |
private $view;
|
5 |
private $page;
|
@@ -10,35 +10,35 @@ class FMControllerManage_fmc {
|
|
10 |
private $actions = array();
|
11 |
|
12 |
function __construct() {
|
13 |
-
require_once
|
14 |
-
require_once
|
15 |
$this->model = new FMModelManage_fmc();
|
16 |
$this->view = new FMViewManage_fmc();
|
17 |
|
18 |
-
$this->page =
|
19 |
$this->page_url = add_query_arg(array(
|
20 |
'page' => $this->page,
|
21 |
-
|
22 |
), admin_url('admin.php')
|
23 |
);
|
24 |
$this->bulk_action_name = 'bulk_action';
|
25 |
|
26 |
$this->actions = array(
|
27 |
'publish' => array(
|
28 |
-
'title' => __('Publish',
|
29 |
-
$this->bulk_action_name => __('published',
|
30 |
),
|
31 |
'unpublish' => array(
|
32 |
-
'title' => __('Unpublish',
|
33 |
-
$this->bulk_action_name => __('unpublished',
|
34 |
),
|
35 |
'duplicate' => array(
|
36 |
-
'title' => __('Duplicate',
|
37 |
-
$this->bulk_action_name => __('duplicated',
|
38 |
),
|
39 |
'delete' => array(
|
40 |
-
'title' => __('Delete',
|
41 |
-
$this->bulk_action_name => __('deleted',
|
42 |
),
|
43 |
);
|
44 |
|
@@ -86,14 +86,14 @@ class FMControllerManage_fmc {
|
|
86 |
}
|
87 |
|
88 |
public function execute() {
|
89 |
-
$task =
|
90 |
-
$id = (int)
|
91 |
if ( method_exists($this, $task) ) {
|
92 |
if ( $task != 'add' && $task != 'edit' && $task != 'display' ) {
|
93 |
-
check_admin_referer(
|
94 |
}
|
95 |
$block_action = $this->bulk_action_name;
|
96 |
-
$action =
|
97 |
if ( $action != -1 ) {
|
98 |
$this->$block_action($action);
|
99 |
}
|
@@ -108,8 +108,8 @@ class FMControllerManage_fmc {
|
|
108 |
|
109 |
public function display() {
|
110 |
$params = array();
|
111 |
-
$params['order'] =
|
112 |
-
$params['orderby'] =
|
113 |
// To prevent SQL injections.
|
114 |
if ( !in_array($params['orderby'], array( 'id', 'title', 'type' )) ) {
|
115 |
$params['orderby'] = 'id';
|
@@ -138,7 +138,7 @@ class FMControllerManage_fmc {
|
|
138 |
$message = 0;
|
139 |
$successfully_updated = 0;
|
140 |
|
141 |
-
$check =
|
142 |
|
143 |
if ( $check ) {
|
144 |
foreach ( $check as $id => $item ) {
|
@@ -152,11 +152,11 @@ class FMControllerManage_fmc {
|
|
152 |
}
|
153 |
if ( $successfully_updated ) {
|
154 |
$block_action = $this->bulk_action_name;
|
155 |
-
$message = sprintf(_n('%s item successfully %s.', '%s items successfully %s.', $successfully_updated,
|
156 |
}
|
157 |
}
|
158 |
|
159 |
-
|
160 |
'page' => $this->page,
|
161 |
'task' => 'display',
|
162 |
($message === 2 ? 'message' : 'msg') => $message,
|
@@ -179,14 +179,14 @@ class FMControllerManage_fmc {
|
|
179 |
$this->model->delete_rows(array( "table" => "formmaker_sessions", "where" => "form_id = " . $id ));
|
180 |
$this->model->delete_rows(array( "table" => "formmaker_backup", "where" => "id = " . $id ));
|
181 |
$this->model->delete_rows(array( "table" => "formmaker_display_options", "where" => "form_id = " . $id ));
|
182 |
-
if (
|
183 |
$arr = explode(',', get_option('contact_form_forms'));
|
184 |
$arr = array_diff($arr, array($id));
|
185 |
$arr = implode(',', $arr);
|
186 |
update_option('contact_form_forms', $arr);
|
187 |
}
|
188 |
// To delete DB rows with form ids from add-ons.
|
189 |
-
if (
|
190 |
do_action('fm_delete_addon_init', $id);
|
191 |
}
|
192 |
$message = 3;
|
@@ -199,7 +199,7 @@ class FMControllerManage_fmc {
|
|
199 |
return $message;
|
200 |
}
|
201 |
else {
|
202 |
-
|
203 |
'page' => $this->page,
|
204 |
'task' => 'display',
|
205 |
'message' => $message,
|
@@ -228,7 +228,7 @@ class FMControllerManage_fmc {
|
|
228 |
return $message;
|
229 |
}
|
230 |
else {
|
231 |
-
|
232 |
'page' => $this->page,
|
233 |
'task' => 'display',
|
234 |
'message' => $message,
|
@@ -257,7 +257,7 @@ class FMControllerManage_fmc {
|
|
257 |
return $message;
|
258 |
}
|
259 |
else {
|
260 |
-
|
261 |
'page' => $this->page,
|
262 |
'task' => 'display',
|
263 |
'message' => $message,
|
@@ -286,7 +286,7 @@ class FMControllerManage_fmc {
|
|
286 |
unset($row['id']);
|
287 |
$inserted = $this->model->insert_data_to_db("formmaker", (array) $row);
|
288 |
$id = (int) $this->model->get_max_row('formmaker', 'id');
|
289 |
-
if (
|
290 |
update_option('contact_form_forms', ((get_option('contact_form_forms')) ? (get_option('contact_form_forms')) . ',' . $id : $id));
|
291 |
}
|
292 |
if ( $inserted !== FALSE ) {
|
@@ -298,7 +298,7 @@ class FMControllerManage_fmc {
|
|
298 |
return $message;
|
299 |
}
|
300 |
else {
|
301 |
-
|
302 |
'page' => $this->page,
|
303 |
'task' => 'display',
|
304 |
'message' => $message,
|
@@ -344,14 +344,14 @@ class FMControllerManage_fmc {
|
|
344 |
$labels['type'] = '"' . implode('","', $label_type) . '"';
|
345 |
$params['labels'] = $labels;
|
346 |
|
347 |
-
$params['page_title'] = __('Create new form',
|
348 |
$params['animation_effects'] = $this->animation_effects;
|
349 |
|
350 |
$this->view->edit($params);
|
351 |
}
|
352 |
|
353 |
public function edit($id = 0, $backup_id = 0) {
|
354 |
-
$fm_settings = get_option('fmc_settings');
|
355 |
$fm_advanced_layout = isset($fm_settings['fm_advanced_layout']) && $fm_settings['fm_advanced_layout'] == '1' ? 1 : 0;
|
356 |
if ( $id && !$fm_advanced_layout ) {
|
357 |
$fm_advanced_layout = !$this->model->get_autogen_layout($id);
|
@@ -379,7 +379,7 @@ class FMControllerManage_fmc {
|
|
379 |
$params['id'] = $id;
|
380 |
$params['row'] = $this->model->get_row_data_new($backup_id);
|
381 |
if ( empty($params['row']) ) {
|
382 |
-
|
383 |
}
|
384 |
|
385 |
// Check stripe add-on is active.
|
@@ -435,15 +435,15 @@ class FMControllerManage_fmc {
|
|
435 |
}
|
436 |
|
437 |
public function undo() {
|
438 |
-
$backup_id = (int)
|
439 |
-
$id = (int)
|
440 |
$backup_id = $this->model->get_undo_redo_id($backup_id, $id, 0);
|
441 |
$this->edit($id, $backup_id);
|
442 |
}
|
443 |
|
444 |
public function redo() {
|
445 |
-
$backup_id = (int)
|
446 |
-
$id = (int)
|
447 |
$backup_id = $this->model->get_undo_redo_id($backup_id, $id, 1);
|
448 |
$this->edit($id, $backup_id);
|
449 |
}
|
@@ -456,120 +456,122 @@ class FMControllerManage_fmc {
|
|
456 |
public function form_options( $id ) {
|
457 |
// Set params for view.
|
458 |
$params = array();
|
459 |
-
$params['id']
|
460 |
-
$params['page']
|
461 |
-
$params['page_url']
|
462 |
|
463 |
-
$params['back_url'] = add_query_arg( array
|
464 |
-
|
465 |
-
|
466 |
-
|
467 |
-
|
468 |
-
|
469 |
-
|
470 |
-
|
471 |
-
|
472 |
-
|
473 |
-
$params['row'] = $this->model->get_row_data($id);
|
474 |
-
if ( empty($params['row']) ) {
|
475 |
-
|
476 |
}
|
477 |
-
|
478 |
-
$params['themes'] = $this->model->get_theme_rows_data();
|
479 |
-
$params['default_theme'] = $this->model->get_default_theme_id();
|
480 |
-
$params['queries'] = $this->model->get_queries_rows_data($id);
|
481 |
-
$params['userGroups'] = get_editable_roles();
|
482 |
-
$params['page_title'] = '"' . $params['row']->title . '" ' .
|
483 |
-
|
484 |
$label_id = array();
|
485 |
$label_label = array();
|
|
|
486 |
$label_type = array();
|
487 |
-
$label_all = explode('#****#', $params['row']->label_order_current);
|
488 |
-
$label_all = array_slice($label_all, 0, count($label_all) - 1);
|
489 |
foreach ( $label_all as $key => $label_each ) {
|
490 |
-
$label_id_each = explode('#**id**#', $label_each);
|
491 |
-
|
492 |
-
$
|
493 |
-
array_push($
|
494 |
-
array_push($
|
|
|
495 |
}
|
496 |
-
$params['fields'] = explode('*:*id*:*type_submitter_mail*:*type*:*', $params['row']->form_fields);
|
497 |
-
$params['fields_count'] = count($params['fields']);
|
498 |
-
|
499 |
-
|
500 |
-
|
501 |
-
|
502 |
-
|
503 |
-
|
504 |
-
|
505 |
-
|
506 |
-
|
507 |
-
|
508 |
-
|
509 |
-
|
510 |
-
|
511 |
-
|
512 |
-
|
513 |
-
|
514 |
-
|
515 |
-
|
516 |
-
|
517 |
-
|
518 |
-
|
519 |
-
|
520 |
-
|
521 |
-
$params['payment_method'] = $payment_method;
|
522 |
-
$params['label_label'] = $
|
523 |
-
$params['label_type'] = $label_type;
|
524 |
-
$params['labels_for_submissions'] = $this->model->get_labels($id);
|
525 |
-
$params['payment_info'] = $this->model->is_paypal($id);
|
526 |
|
527 |
$labels_id_for_submissions = array();
|
528 |
$label_titles_for_submissions = array();
|
529 |
$labels_type_for_submissions = array();
|
530 |
-
if ( $params['labels_for_submissions'] ) {
|
531 |
$label_id_for_submissions = array();
|
532 |
$label_order_original_for_submissions = array();
|
533 |
$label_type_for_submissions = array();
|
534 |
-
if ( strpos($params['row']->label_order, 'type_paypal_') ) {
|
535 |
-
$params['row']->label_order = $params['row']->label_order . "item_total#**id**#Item Total#**label**#type_paypal_payment_total#****#total#**id**#Total#**label**#type_paypal_payment_total#****#0#**id**#Payment Status#**label**#type_paypal_payment_status#****#";
|
536 |
}
|
537 |
-
$label_all_for_submissions = explode('#****#', $params['row']->label_order);
|
538 |
-
$label_all_for_submissions = array_slice($label_all_for_submissions, 0, count($label_all_for_submissions) - 1);
|
539 |
foreach ( $label_all_for_submissions as $key => $label_each ) {
|
540 |
-
$label_id_each = explode('#**id**#', $label_each);
|
541 |
-
array_push($label_id_for_submissions, $label_id_each[0]);
|
542 |
-
$label_order_each = explode('#**label**#', $label_id_each[1]);
|
543 |
-
array_push($label_order_original_for_submissions, $label_order_each[0]);
|
544 |
-
array_push($label_type_for_submissions, $label_order_each[1]);
|
545 |
}
|
546 |
foreach ( $label_id_for_submissions as $key => $label ) {
|
547 |
-
if ( in_array($label, $params['labels_for_submissions']) ) {
|
548 |
-
array_push($labels_type_for_submissions, $label_type_for_submissions[$key]);
|
549 |
-
array_push($labels_id_for_submissions, $label);
|
550 |
-
array_push($label_titles_for_submissions, $label_order_original_for_submissions[$key]);
|
551 |
}
|
552 |
}
|
553 |
-
$params['labels_id_for_submissions'] = $labels_id_for_submissions;
|
554 |
-
$params['label_titles_for_submissions'] = $label_titles_for_submissions;
|
555 |
}
|
556 |
-
|
557 |
$stats_labels = array();
|
558 |
$stats_labels_ids = array();
|
559 |
foreach ( $labels_type_for_submissions as $key => $label_type_cur ) {
|
560 |
if ( $label_type_cur == "type_checkbox" || $label_type_cur == "type_radio" || $label_type_cur == "type_own_select" || $label_type_cur == "type_country" || $label_type_cur == "type_paypal_select" || $label_type_cur == "type_paypal_radio" || $label_type_cur == "type_paypal_checkbox" || $label_type_cur == "type_paypal_shipping" ) {
|
561 |
-
$stats_labels_ids[] = $labels_id_for_submissions[$key];
|
562 |
-
$stats_labels[] = $label_titles_for_submissions[$key];
|
563 |
}
|
564 |
}
|
565 |
-
|
566 |
-
$params['stats_labels_ids'] = $stats_labels_ids;
|
567 |
-
$params['stats_labels'] = $stats_labels;
|
568 |
-
$params['mail_ver_id'] = $this->model->get_emailverification_post_id();
|
569 |
|
570 |
-
|
|
|
|
|
571 |
|
572 |
-
$this->
|
|
|
|
|
573 |
}
|
574 |
|
575 |
/**
|
@@ -581,7 +583,7 @@ class FMControllerManage_fmc {
|
|
581 |
*/
|
582 |
private function get_addon_tabs( $params ) {
|
583 |
$addons = array('tabs' => array(), 'html' => array());
|
584 |
-
if (
|
585 |
$addons = apply_filters('fm_get_addon_init', $addons, $params);
|
586 |
}
|
587 |
return $addons;
|
@@ -593,9 +595,9 @@ class FMControllerManage_fmc {
|
|
593 |
* @param int $id
|
594 |
*/
|
595 |
public function apply_form_options( $id ) {
|
596 |
-
$fieldset_id =
|
597 |
$message = $this->save_db_form_options( $id );
|
598 |
-
|
599 |
'page' => $this->page,
|
600 |
'task' => 'form_options',
|
601 |
'current_id' => $id,
|
@@ -615,65 +617,69 @@ class FMControllerManage_fmc {
|
|
615 |
$javascript = "// Occurs before the form is loaded
|
616 |
function before_load() {
|
617 |
|
618 |
-
}
|
619 |
// Occurs just before submitting the form
|
620 |
function before_submit() {
|
621 |
// IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don't need to return any value if you don't want to stop the submission.
|
622 |
-
}
|
623 |
// Occurs just before resetting the form
|
624 |
function before_reset() {
|
625 |
|
|
|
|
|
|
|
|
|
626 |
}";
|
627 |
|
628 |
-
$published = stripslashes(
|
629 |
-
$savedb = stripslashes(
|
630 |
-
$theme = (int)
|
631 |
$theme = ($theme) ? $theme : $this->model->get_default_theme_id();
|
632 |
-
$requiredmark = stripslashes(
|
633 |
-
$sendemail = stripslashes(
|
634 |
-
$save_uploads = stripslashes(
|
635 |
-
$mail = stripslashes(
|
636 |
if ( isset($_POST['mailToAdd']) && esc_html(stripslashes($_POST['mailToAdd'])) != '' ) {
|
637 |
$mail .= esc_html(stripslashes($_POST['mailToAdd'])) . ',';
|
638 |
}
|
639 |
-
$from_mail = stripslashes(
|
640 |
-
$from_name = stripslashes(
|
641 |
-
$reply_to = stripslashes(
|
642 |
if ( $from_mail == "other" ) {
|
643 |
-
$from_mail = stripslashes(
|
644 |
}
|
645 |
if ( $reply_to == "other" ) {
|
646 |
-
$reply_to = stripslashes(
|
647 |
}
|
648 |
-
$script_mail =
|
649 |
if ( $script_mail == '' ) {
|
650 |
-
$script_mail = '
|
651 |
-
}
|
652 |
-
$mail_from_user =
|
653 |
-
$mail_from_name_user =
|
654 |
-
$reply_to_user =
|
655 |
-
$condition =
|
656 |
-
$mail_cc =
|
657 |
-
$mail_cc_user =
|
658 |
-
$mail_bcc =
|
659 |
-
$mail_bcc_user =
|
660 |
-
$mail_subject =
|
661 |
-
$mail_subject_user =
|
662 |
-
$mail_mode =
|
663 |
-
$mail_mode_user =
|
664 |
-
$mail_attachment =
|
665 |
-
$mail_attachment_user =
|
666 |
-
$script_mail_user =
|
667 |
if ( $script_mail_user == '' ) {
|
668 |
-
$script_mail_user = '
|
669 |
}
|
670 |
-
$submit_text =
|
671 |
-
$url =
|
672 |
-
$tax =
|
673 |
-
$payment_currency =
|
674 |
-
$paypal_email =
|
675 |
-
$checkout_mode =
|
676 |
-
$paypal_mode =
|
677 |
|
678 |
// TODO Seclude payment method and payment status.
|
679 |
if ( $paypal_mode == 'paypal' ) {
|
@@ -683,26 +689,26 @@ function before_reset() {
|
|
683 |
$paypal_mode = 2;
|
684 |
}
|
685 |
|
686 |
-
$javascript = stripslashes(
|
687 |
-
$user_id_wd = stripslashes(
|
688 |
-
$frontend_submit_fields = stripslashes(
|
689 |
-
$frontend_submit_stat_fields = stripslashes(
|
690 |
-
$mail_emptyfields = stripslashes(
|
691 |
-
$mail_verify = stripslashes(
|
692 |
-
$mail_verify_expiretime = stripslashes(
|
693 |
$send_to = '';
|
694 |
for ( $i = 0; $i < 20; $i++ ) {
|
695 |
-
if (
|
696 |
-
$send_to .= '*' .
|
697 |
}
|
698 |
}
|
699 |
-
if (
|
700 |
-
$submit_text_type =
|
701 |
if ( $submit_text_type == 5 ) {
|
702 |
-
$article_id =
|
703 |
}
|
704 |
else {
|
705 |
-
$article_id =
|
706 |
}
|
707 |
}
|
708 |
else {
|
@@ -777,7 +783,7 @@ function before_reset() {
|
|
777 |
'theme' => $theme,
|
778 |
), array( 'id' => $id )); //save theme in backup
|
779 |
$this->model->create_js($id);
|
780 |
-
if (
|
781 |
$save_addon = do_action('fm_save_addon_init', $id);
|
782 |
}
|
783 |
$message_id = 8;
|
@@ -797,7 +803,7 @@ function before_reset() {
|
|
797 |
|
798 |
$row = $this->model->get_row_data( $id );
|
799 |
if ( empty($row) ) {
|
800 |
-
|
801 |
}
|
802 |
$fields = explode('*:*new_field*:*', $row->form_fields);
|
803 |
$fields = array_slice($fields, 0, count($fields) - 1);
|
@@ -816,8 +822,8 @@ function before_reset() {
|
|
816 |
$params['row'] = $row;
|
817 |
$params['page'] = $this->page;
|
818 |
$params['page_url'] = $this->page_url;
|
819 |
-
$params['page_title'] = '"'. $row->title . '" ' . __('layout',
|
820 |
-
$params['back_url'] = add_query_arg( array ('page' => 'manage' .
|
821 |
$params['ids'] = $ids;
|
822 |
$params['types'] = $types;
|
823 |
$params['labels'] = $labels;
|
@@ -826,7 +832,7 @@ function before_reset() {
|
|
826 |
|
827 |
public function apply_layout( $id ) {
|
828 |
$message = $this->save_db_layout( $id );
|
829 |
-
|
830 |
}
|
831 |
|
832 |
/**
|
@@ -837,8 +843,8 @@ function before_reset() {
|
|
837 |
* @return int $id_message
|
838 |
*/
|
839 |
public function save_db_layout( $id ) {
|
840 |
-
$custom_front =
|
841 |
-
$autogen_layout =
|
842 |
|
843 |
$update = $this->model->update_data('formmaker', array(
|
844 |
'custom_front' => $custom_front,
|
@@ -853,14 +859,14 @@ function before_reset() {
|
|
853 |
}
|
854 |
|
855 |
public function display_options() {
|
856 |
-
$id = (int)
|
857 |
$params = array();
|
858 |
$params['row_form'] = $this->model->get_row_data($id);
|
859 |
if ( empty($params['row_form']) ) {
|
860 |
-
|
861 |
}
|
862 |
$params['row'] = $this->model->get_display_options($id);
|
863 |
-
$params['page_title'] = '"'. $params['row_form']->title . '" ' . __('display options',
|
864 |
$params['animation_effects'] = $this->animation_effects;
|
865 |
$params['posts_and_pages'] = $this->model->fm_posts_query();
|
866 |
$params['categories'] = $this->model->fm_categories_query();
|
@@ -870,22 +876,22 @@ function before_reset() {
|
|
870 |
$params['page'] = $this->page;
|
871 |
$params['page_url'] = $this->page_url;
|
872 |
$params['back_url'] = add_query_arg( array (
|
873 |
-
'page' => 'manage' .
|
874 |
'task' => 'edit',
|
875 |
'current_id' => $id,
|
876 |
), admin_url('admin.php')
|
877 |
);
|
878 |
|
879 |
-
$params['fieldset_id'] =
|
880 |
$this->view->display_options($params);
|
881 |
}
|
882 |
|
883 |
public function save_display_options() {
|
884 |
$message = $this->save_dis_options();
|
885 |
-
$page =
|
886 |
|
887 |
-
$current_id = (int)
|
888 |
-
|
889 |
'page' => $page,
|
890 |
'task' => 'edit',
|
891 |
'current_id' => $current_id,
|
@@ -895,10 +901,10 @@ function before_reset() {
|
|
895 |
|
896 |
public function apply_display_options() {
|
897 |
$message = $this->save_dis_options();
|
898 |
-
$page =
|
899 |
-
$fieldset_id =
|
900 |
-
$current_id = (int)
|
901 |
-
|
902 |
'page' => $page,
|
903 |
'task' => 'display_options',
|
904 |
'current_id' => $current_id,
|
@@ -912,14 +918,14 @@ function before_reset() {
|
|
912 |
* @param int $id
|
913 |
*/
|
914 |
public function remove_query( $id ) {
|
915 |
-
$fieldset_id =
|
916 |
-
$query_id =
|
917 |
$message = 2;
|
918 |
if( $this->model->delete_formmaker_query( $query_id ) ) {
|
919 |
$message = 3;
|
920 |
}
|
921 |
|
922 |
-
|
923 |
'page' => $this->page,
|
924 |
'task' => 'form_options',
|
925 |
'current_id' => $id,
|
@@ -942,30 +948,30 @@ function before_reset() {
|
|
942 |
|
943 |
public function save_dis_options() {
|
944 |
$option_data = array(
|
945 |
-
'form_id' => (int)
|
946 |
-
'scrollbox_loading_delay' => $this->set_delay_freq_positive_val(
|
947 |
-
'popover_animate_effect' =>
|
948 |
-
'popover_loading_delay' => $this->set_delay_freq_positive_val(
|
949 |
-
'popover_frequency' => $this->set_delay_freq_positive_val(
|
950 |
-
'topbar_position' =>
|
951 |
-
'topbar_remain_top' =>
|
952 |
-
'topbar_closing' =>
|
953 |
-
'topbar_hide_duration' => $this->set_delay_freq_positive_val(
|
954 |
-
'scrollbox_position' =>
|
955 |
-
'scrollbox_trigger_point' =>
|
956 |
-
'scrollbox_hide_duration' => $this->set_delay_freq_positive_val(
|
957 |
-
'scrollbox_auto_hide' =>
|
958 |
-
'hide_mobile' =>
|
959 |
-
'scrollbox_closing' =>
|
960 |
-
'scrollbox_minimize' =>
|
961 |
-
'scrollbox_minimize_text' =>
|
962 |
-
'type' =>
|
963 |
-
'display_on' => implode(',',
|
964 |
-
'posts_include' =>
|
965 |
-
'pages_include' =>
|
966 |
-
'display_on_categories' => implode(',',
|
967 |
-
'current_categories' =>
|
968 |
-
'show_for_admin' =>
|
969 |
);
|
970 |
|
971 |
$save = $this->model->replace_display_options($option_data);
|
@@ -988,8 +994,8 @@ function before_reset() {
|
|
988 |
// TODO: remove this function.
|
989 |
public function save_as_copy() {
|
990 |
$message = $this->save_db_as_copy();
|
991 |
-
$page =
|
992 |
-
|
993 |
'page' => $page,
|
994 |
'task' => 'display',
|
995 |
'message' => $message,
|
@@ -998,8 +1004,8 @@ function before_reset() {
|
|
998 |
|
999 |
public function save() {
|
1000 |
$message = $this->save_db();
|
1001 |
-
$page =
|
1002 |
-
|
1003 |
'page' => $page,
|
1004 |
'task' => 'display',
|
1005 |
'message' => $message,
|
@@ -1008,12 +1014,12 @@ function before_reset() {
|
|
1008 |
|
1009 |
public function apply() {
|
1010 |
$message = $this->save_db();
|
1011 |
-
$current_id = (int)
|
1012 |
if ( !$current_id ) {
|
1013 |
$current_id = (int) $this->model->get_max_row('formmaker', 'id');
|
1014 |
}
|
1015 |
-
$page =
|
1016 |
-
|
1017 |
'page' => $page,
|
1018 |
'task' => 'edit',
|
1019 |
'current_id' => $current_id,
|
@@ -1031,29 +1037,33 @@ function before_submit() {
|
|
1031 |
}
|
1032 |
// Occurs just before resetting the form
|
1033 |
function before_reset() {
|
|
|
|
|
|
|
|
|
1034 |
}";
|
1035 |
-
$id = (int)
|
1036 |
-
$title =
|
1037 |
-
$theme = (int)
|
1038 |
-
|
1039 |
-
$form_front =
|
1040 |
-
$sortable =
|
1041 |
-
$counter =
|
1042 |
-
$label_order =
|
1043 |
-
$pagination =
|
1044 |
-
$show_title =
|
1045 |
-
$show_numbers =
|
1046 |
-
$public_key =
|
1047 |
-
$private_key =
|
1048 |
-
$recaptcha_theme =
|
1049 |
-
$label_order_current =
|
1050 |
-
$form_fields =
|
1051 |
-
$header_title =
|
1052 |
-
$header_description =
|
1053 |
-
$header_image_url =
|
1054 |
-
$header_image_animation =
|
1055 |
-
$header_hide_image =
|
1056 |
-
$type =
|
1057 |
$scrollbox_minimize_text = $header_title ? $header_title : 'The form is minimized.';
|
1058 |
if ( $id != 0 ) {
|
1059 |
$save = $this->model->update_data('formmaker', array(
|
@@ -1082,7 +1092,7 @@ function before_reset() {
|
|
1082 |
$this->model->insert_data_to_db('formmaker', array(
|
1083 |
'title' => $title,
|
1084 |
'type' => $type,
|
1085 |
-
'mail' => '',
|
1086 |
'form_front' => $form_front,
|
1087 |
'theme' => $theme,
|
1088 |
'counter' => $counter,
|
@@ -1098,8 +1108,8 @@ function before_reset() {
|
|
1098 |
'url' => '',
|
1099 |
'article_id' => 0,
|
1100 |
'submit_text_type' => 1,
|
1101 |
-
'script_mail' => '
|
1102 |
-
'script_mail_user' => '
|
1103 |
'label_order_current' => $label_order_current,
|
1104 |
'tax' => 0,
|
1105 |
'payment_currency' => '',
|
@@ -1143,7 +1153,7 @@ function before_reset() {
|
|
1143 |
'header_hide_image' => $header_hide_image,
|
1144 |
));
|
1145 |
$id = (int) $this->model->get_max_row('formmaker', 'id');
|
1146 |
-
if (
|
1147 |
update_option('contact_form_forms', ((get_option('contact_form_forms')) ? (get_option('contact_form_forms')) . ',' . $id : $id));
|
1148 |
}
|
1149 |
$this->model->insert_data_to_db('formmaker_display_options', array(
|
@@ -1177,7 +1187,7 @@ function before_reset() {
|
|
1177 |
'views' => 0,
|
1178 |
));
|
1179 |
}
|
1180 |
-
$backup_id = (int)
|
1181 |
if ( $backup_id ) {
|
1182 |
if ( $this->model->get_backup_id($backup_id, $id) ) {
|
1183 |
$this->model->delete_rows(array(
|
@@ -1245,8 +1255,8 @@ function before_reset() {
|
|
1245 |
'url' => '',
|
1246 |
'article_id' => 0,
|
1247 |
'submit_text_type' => 1,
|
1248 |
-
'script_mail' => '
|
1249 |
-
'script_mail_user' => '
|
1250 |
'label_order_current' => $label_order_current,
|
1251 |
'tax' => 0,
|
1252 |
'payment_currency' => '',
|
@@ -1379,8 +1389,8 @@ function before_reset() {
|
|
1379 |
}
|
1380 |
|
1381 |
public function update_form_title( $id ) {
|
1382 |
-
$page =
|
1383 |
-
$form_name =
|
1384 |
|
1385 |
// check id for db
|
1386 |
if(isset($id) && $id != "") {
|
@@ -1388,7 +1398,7 @@ function before_reset() {
|
|
1388 |
$update = $this->model->update_data( "forms", array('title' => $form_name,), array('id' => $id) );
|
1389 |
if( !$update ){
|
1390 |
$message = 2;
|
1391 |
-
|
1392 |
'page' => $page,
|
1393 |
'task' => 'display',
|
1394 |
'message' => $message,
|
@@ -1398,7 +1408,7 @@ function before_reset() {
|
|
1398 |
}
|
1399 |
else { // return message Failed
|
1400 |
$message = 2;
|
1401 |
-
|
1402 |
'page' => $page,
|
1403 |
'task' => 'display',
|
1404 |
'message' => $message,
|
1 |
<?php
|
2 |
+
class FMControllerManage_fmc extends CFMAdminController {
|
3 |
private $model;
|
4 |
private $view;
|
5 |
private $page;
|
10 |
private $actions = array();
|
11 |
|
12 |
function __construct() {
|
13 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/Manage_fm.php";
|
14 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Manage_fm.php";
|
15 |
$this->model = new FMModelManage_fmc();
|
16 |
$this->view = new FMViewManage_fmc();
|
17 |
|
18 |
+
$this->page = WDW_FM_Library(self::PLUGIN)->get('page');
|
19 |
$this->page_url = add_query_arg(array(
|
20 |
'page' => $this->page,
|
21 |
+
WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce),
|
22 |
), admin_url('admin.php')
|
23 |
);
|
24 |
$this->bulk_action_name = 'bulk_action';
|
25 |
|
26 |
$this->actions = array(
|
27 |
'publish' => array(
|
28 |
+
'title' => __('Publish', WDFMInstance(self::PLUGIN)->prefix),
|
29 |
+
$this->bulk_action_name => __('published', WDFMInstance(self::PLUGIN)->prefix),
|
30 |
),
|
31 |
'unpublish' => array(
|
32 |
+
'title' => __('Unpublish', WDFMInstance(self::PLUGIN)->prefix),
|
33 |
+
$this->bulk_action_name => __('unpublished', WDFMInstance(self::PLUGIN)->prefix),
|
34 |
),
|
35 |
'duplicate' => array(
|
36 |
+
'title' => __('Duplicate', WDFMInstance(self::PLUGIN)->prefix),
|
37 |
+
$this->bulk_action_name => __('duplicated', WDFMInstance(self::PLUGIN)->prefix),
|
38 |
),
|
39 |
'delete' => array(
|
40 |
+
'title' => __('Delete', WDFMInstance(self::PLUGIN)->prefix),
|
41 |
+
$this->bulk_action_name => __('deleted', WDFMInstance(self::PLUGIN)->prefix),
|
42 |
),
|
43 |
);
|
44 |
|
86 |
}
|
87 |
|
88 |
public function execute() {
|
89 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task');
|
90 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
91 |
if ( method_exists($this, $task) ) {
|
92 |
if ( $task != 'add' && $task != 'edit' && $task != 'display' ) {
|
93 |
+
check_admin_referer(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce);
|
94 |
}
|
95 |
$block_action = $this->bulk_action_name;
|
96 |
+
$action = WDW_FM_Library(self::PLUGIN)->get( $block_action, -1 );
|
97 |
if ( $action != -1 ) {
|
98 |
$this->$block_action($action);
|
99 |
}
|
108 |
|
109 |
public function display() {
|
110 |
$params = array();
|
111 |
+
$params['order'] = WDW_FM_Library(self::PLUGIN)->get('order', 'asc');
|
112 |
+
$params['orderby'] = WDW_FM_Library(self::PLUGIN)->get('orderby', 'id');
|
113 |
// To prevent SQL injections.
|
114 |
if ( !in_array($params['orderby'], array( 'id', 'title', 'type' )) ) {
|
115 |
$params['orderby'] = 'id';
|
138 |
$message = 0;
|
139 |
$successfully_updated = 0;
|
140 |
|
141 |
+
$check = WDW_FM_Library(self::PLUGIN)->get('check', '');
|
142 |
|
143 |
if ( $check ) {
|
144 |
foreach ( $check as $id => $item ) {
|
152 |
}
|
153 |
if ( $successfully_updated ) {
|
154 |
$block_action = $this->bulk_action_name;
|
155 |
+
$message = sprintf(_n('%s item successfully %s.', '%s items successfully %s.', $successfully_updated, WDFMInstance(self::PLUGIN)->prefix), $successfully_updated, $this->actions[$task][$block_action]);
|
156 |
}
|
157 |
}
|
158 |
|
159 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
160 |
'page' => $this->page,
|
161 |
'task' => 'display',
|
162 |
($message === 2 ? 'message' : 'msg') => $message,
|
179 |
$this->model->delete_rows(array( "table" => "formmaker_sessions", "where" => "form_id = " . $id ));
|
180 |
$this->model->delete_rows(array( "table" => "formmaker_backup", "where" => "id = " . $id ));
|
181 |
$this->model->delete_rows(array( "table" => "formmaker_display_options", "where" => "form_id = " . $id ));
|
182 |
+
if (WDFMInstance(self::PLUGIN)->is_free == 2) {
|
183 |
$arr = explode(',', get_option('contact_form_forms'));
|
184 |
$arr = array_diff($arr, array($id));
|
185 |
$arr = implode(',', $arr);
|
186 |
update_option('contact_form_forms', $arr);
|
187 |
}
|
188 |
// To delete DB rows with form ids from add-ons.
|
189 |
+
if (WDFMInstance(self::PLUGIN)->is_free != 2) {
|
190 |
do_action('fm_delete_addon_init', $id);
|
191 |
}
|
192 |
$message = 3;
|
199 |
return $message;
|
200 |
}
|
201 |
else {
|
202 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
203 |
'page' => $this->page,
|
204 |
'task' => 'display',
|
205 |
'message' => $message,
|
228 |
return $message;
|
229 |
}
|
230 |
else {
|
231 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
232 |
'page' => $this->page,
|
233 |
'task' => 'display',
|
234 |
'message' => $message,
|
257 |
return $message;
|
258 |
}
|
259 |
else {
|
260 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
261 |
'page' => $this->page,
|
262 |
'task' => 'display',
|
263 |
'message' => $message,
|
286 |
unset($row['id']);
|
287 |
$inserted = $this->model->insert_data_to_db("formmaker", (array) $row);
|
288 |
$id = (int) $this->model->get_max_row('formmaker', 'id');
|
289 |
+
if (WDFMInstance(self::PLUGIN)->is_free == 2) {
|
290 |
update_option('contact_form_forms', ((get_option('contact_form_forms')) ? (get_option('contact_form_forms')) . ',' . $id : $id));
|
291 |
}
|
292 |
if ( $inserted !== FALSE ) {
|
298 |
return $message;
|
299 |
}
|
300 |
else {
|
301 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
302 |
'page' => $this->page,
|
303 |
'task' => 'display',
|
304 |
'message' => $message,
|
344 |
$labels['type'] = '"' . implode('","', $label_type) . '"';
|
345 |
$params['labels'] = $labels;
|
346 |
|
347 |
+
$params['page_title'] = __('Create new form', WDFMInstance(self::PLUGIN)->prefix);
|
348 |
$params['animation_effects'] = $this->animation_effects;
|
349 |
|
350 |
$this->view->edit($params);
|
351 |
}
|
352 |
|
353 |
public function edit($id = 0, $backup_id = 0) {
|
354 |
+
$fm_settings = get_option(WDFMInstance(self::PLUGIN)->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
355 |
$fm_advanced_layout = isset($fm_settings['fm_advanced_layout']) && $fm_settings['fm_advanced_layout'] == '1' ? 1 : 0;
|
356 |
if ( $id && !$fm_advanced_layout ) {
|
357 |
$fm_advanced_layout = !$this->model->get_autogen_layout($id);
|
379 |
$params['id'] = $id;
|
380 |
$params['row'] = $this->model->get_row_data_new($backup_id);
|
381 |
if ( empty($params['row']) ) {
|
382 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array('page' => $this->page, 'task' => 'display'), admin_url('admin.php') ) );
|
383 |
}
|
384 |
|
385 |
// Check stripe add-on is active.
|
435 |
}
|
436 |
|
437 |
public function undo() {
|
438 |
+
$backup_id = (int) WDW_FM_Library(self::PLUGIN)->get('backup_id');
|
439 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('id');
|
440 |
$backup_id = $this->model->get_undo_redo_id($backup_id, $id, 0);
|
441 |
$this->edit($id, $backup_id);
|
442 |
}
|
443 |
|
444 |
public function redo() {
|
445 |
+
$backup_id = (int) WDW_FM_Library(self::PLUGIN)->get('backup_id');
|
446 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('id');
|
447 |
$backup_id = $this->model->get_undo_redo_id($backup_id, $id, 1);
|
448 |
$this->edit($id, $backup_id);
|
449 |
}
|
456 |
public function form_options( $id ) {
|
457 |
// Set params for view.
|
458 |
$params = array();
|
459 |
+
$params[ 'id' ] = $id;
|
460 |
+
$params[ 'page' ] = $this->page;
|
461 |
+
$params[ 'page_url' ] = $this->page_url;
|
462 |
|
463 |
+
$params[ 'back_url' ] = add_query_arg( array(
|
464 |
+
'page' => 'manage' . WDFMInstance(self::PLUGIN)->menu_postfix,
|
465 |
+
'task' => 'edit',
|
466 |
+
'current_id' => $id,
|
467 |
+
|
468 |
+
), admin_url( 'admin.php' )
|
469 |
+
);
|
470 |
+
|
471 |
+
$params[ 'fieldset_id' ] = WDW_FM_Library(self::PLUGIN)->get( 'fieldset_id', 'general' );
|
472 |
+
|
473 |
+
$params[ 'row' ] = $this->model->get_row_data( $id );
|
474 |
+
if ( empty( $params[ 'row' ] ) ) {
|
475 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array( 'page' => $this->page ), admin_url( 'admin.php' ) ) );
|
476 |
}
|
477 |
+
|
478 |
+
$params[ 'themes' ] = $this->model->get_theme_rows_data();
|
479 |
+
$params[ 'default_theme' ] = $this->model->get_default_theme_id();
|
480 |
+
$params[ 'queries' ] = $this->model->get_queries_rows_data( $id );
|
481 |
+
$params[ 'userGroups' ] = get_editable_roles();
|
482 |
+
$params[ 'page_title' ] = '"' . $params[ 'row' ]->title . '" ' . __( 'options', WDFMInstance(self::PLUGIN)->prefix );
|
483 |
+
|
484 |
$label_id = array();
|
485 |
$label_label = array();
|
486 |
+
$labelIds = array();
|
487 |
$label_type = array();
|
488 |
+
$label_all = explode( '#****#', $params[ 'row' ]->label_order_current );
|
489 |
+
$label_all = array_slice( $label_all, 0, count( $label_all ) - 1 );
|
490 |
foreach ( $label_all as $key => $label_each ) {
|
491 |
+
$label_id_each = explode( '#**id**#', $label_each );
|
492 |
+
$label_order_each = explode( '#**label**#', $label_id_each[ 1 ] );
|
493 |
+
$labelIds[ $label_id_each[ 0 ] ] = array( 'type' => $label_order_each[ 1 ], 'name' => $label_order_each[ 0 ] );
|
494 |
+
array_push( $label_id, $label_id_each[ 0 ] );
|
495 |
+
array_push( $label_label, $label_order_each[ 0 ] );
|
496 |
+
array_push( $label_type, $label_order_each[ 1 ] );
|
497 |
}
|
498 |
+
$params[ 'fields' ] = explode( '*:*id*:*type_submitter_mail*:*type*:*', $params[ 'row' ]->form_fields );
|
499 |
+
$params[ 'fields_count' ] = count( $params[ 'fields' ] );
|
500 |
+
|
501 |
+
// chechk stripe addon is active.
|
502 |
+
$stripe_addon = array( 'enable' => 0 );
|
503 |
+
$addon_stripe = $this->get_stripe_addon( $id );
|
504 |
+
if ( !empty( $addon_stripe[ 'html' ] ) ) {
|
505 |
+
$stripe_addon = $addon_stripe;
|
506 |
+
}
|
507 |
+
$params[ 'stripe_addon' ] = $stripe_addon;
|
508 |
+
|
509 |
+
/*
|
510 |
+
TODO.
|
511 |
+
Remember. 0 => none, 1 => paypal, 2 => stripe
|
512 |
+
Change. rename paypal_mode name to payment_method of wp_formmaker table.
|
513 |
+
*/
|
514 |
+
$paypal_mode = $params[ 'row' ]->paypal_mode;
|
515 |
+
$payment_method = 'none';
|
516 |
+
if ( $paypal_mode == 1 ) {
|
517 |
+
$payment_method = 'paypal';
|
518 |
+
}
|
519 |
+
if ( $paypal_mode == 2 && isset( $stripe_addon[ 'stripe_enable' ] ) && $stripe_addon[ 'stripe_enable' ] == 1 ) {
|
520 |
+
$payment_method = 'stripe';
|
521 |
+
}
|
522 |
+
|
523 |
+
$params[ 'payment_method' ] = $payment_method;
|
524 |
+
$params[ 'label_label' ] = WDW_FM_Library(self::PLUGIN)->create_email_options_placeholders( $labelIds );
|
525 |
+
$params[ 'label_type' ] = $label_type;
|
526 |
+
$params[ 'labels_for_submissions' ] = $this->model->get_labels( $id );
|
527 |
+
$params[ 'payment_info' ] = $this->model->is_paypal( $id );
|
528 |
|
529 |
$labels_id_for_submissions = array();
|
530 |
$label_titles_for_submissions = array();
|
531 |
$labels_type_for_submissions = array();
|
532 |
+
if ( $params[ 'labels_for_submissions' ] ) {
|
533 |
$label_id_for_submissions = array();
|
534 |
$label_order_original_for_submissions = array();
|
535 |
$label_type_for_submissions = array();
|
536 |
+
if ( strpos( $params[ 'row' ]->label_order, 'type_paypal_' ) ) {
|
537 |
+
$params[ 'row' ]->label_order = $params[ 'row' ]->label_order . "item_total#**id**#Item Total#**label**#type_paypal_payment_total#****#total#**id**#Total#**label**#type_paypal_payment_total#****#0#**id**#Payment Status#**label**#type_paypal_payment_status#****#";
|
538 |
}
|
539 |
+
$label_all_for_submissions = explode( '#****#', $params[ 'row' ]->label_order );
|
540 |
+
$label_all_for_submissions = array_slice( $label_all_for_submissions, 0, count( $label_all_for_submissions ) - 1 );
|
541 |
foreach ( $label_all_for_submissions as $key => $label_each ) {
|
542 |
+
$label_id_each = explode( '#**id**#', $label_each );
|
543 |
+
array_push( $label_id_for_submissions, $label_id_each[ 0 ] );
|
544 |
+
$label_order_each = explode( '#**label**#', $label_id_each[ 1 ] );
|
545 |
+
array_push( $label_order_original_for_submissions, $label_order_each[ 0 ] );
|
546 |
+
array_push( $label_type_for_submissions, $label_order_each[ 1 ] );
|
547 |
}
|
548 |
foreach ( $label_id_for_submissions as $key => $label ) {
|
549 |
+
if ( in_array( $label, $params[ 'labels_for_submissions' ] ) ) {
|
550 |
+
array_push( $labels_type_for_submissions, $label_type_for_submissions[ $key ] );
|
551 |
+
array_push( $labels_id_for_submissions, $label );
|
552 |
+
array_push( $label_titles_for_submissions, $label_order_original_for_submissions[ $key ] );
|
553 |
}
|
554 |
}
|
555 |
+
$params[ 'labels_id_for_submissions' ] = $labels_id_for_submissions;
|
556 |
+
$params[ 'label_titles_for_submissions' ] = $label_titles_for_submissions;
|
557 |
}
|
558 |
+
|
559 |
$stats_labels = array();
|
560 |
$stats_labels_ids = array();
|
561 |
foreach ( $labels_type_for_submissions as $key => $label_type_cur ) {
|
562 |
if ( $label_type_cur == "type_checkbox" || $label_type_cur == "type_radio" || $label_type_cur == "type_own_select" || $label_type_cur == "type_country" || $label_type_cur == "type_paypal_select" || $label_type_cur == "type_paypal_radio" || $label_type_cur == "type_paypal_checkbox" || $label_type_cur == "type_paypal_shipping" ) {
|
563 |
+
$stats_labels_ids[] = $labels_id_for_submissions[ $key ];
|
564 |
+
$stats_labels[] = $label_titles_for_submissions[ $key ];
|
565 |
}
|
566 |
}
|
|
|
|
|
|
|
|
|
567 |
|
568 |
+
$params[ 'stats_labels_ids' ] = $stats_labels_ids;
|
569 |
+
$params[ 'stats_labels' ] = $stats_labels;
|
570 |
+
$params[ 'mail_ver_id' ] = $this->model->get_emailverification_post_id();
|
571 |
|
572 |
+
$params[ 'addons' ] = $this->get_addon_tabs( array( 'form_id' => $id ) );
|
573 |
+
|
574 |
+
$this->view->form_options( $params );
|
575 |
}
|
576 |
|
577 |
/**
|
583 |
*/
|
584 |
private function get_addon_tabs( $params ) {
|
585 |
$addons = array('tabs' => array(), 'html' => array());
|
586 |
+
if (WDFMInstance(self::PLUGIN)->is_free != 2) {
|
587 |
$addons = apply_filters('fm_get_addon_init', $addons, $params);
|
588 |
}
|
589 |
return $addons;
|
595 |
* @param int $id
|
596 |
*/
|
597 |
public function apply_form_options( $id ) {
|
598 |
+
$fieldset_id = WDW_FM_Library(self::PLUGIN)->get('fieldset_id', 'general');
|
599 |
$message = $this->save_db_form_options( $id );
|
600 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
601 |
'page' => $this->page,
|
602 |
'task' => 'form_options',
|
603 |
'current_id' => $id,
|
617 |
$javascript = "// Occurs before the form is loaded
|
618 |
function before_load() {
|
619 |
|
620 |
+
}
|
621 |
// Occurs just before submitting the form
|
622 |
function before_submit() {
|
623 |
// IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don't need to return any value if you don't want to stop the submission.
|
624 |
+
}
|
625 |
// Occurs just before resetting the form
|
626 |
function before_reset() {
|
627 |
|
628 |
+
}
|
629 |
+
// Occurs after form is submitted and reloaded
|
630 |
+
function after_submit() {
|
631 |
+
|
632 |
}";
|
633 |
|
634 |
+
$published = stripslashes(WDW_FM_Library(self::PLUGIN)->get('published', ''));
|
635 |
+
$savedb = stripslashes(WDW_FM_Library(self::PLUGIN)->get('savedb', ''));
|
636 |
+
$theme = (int) WDW_FM_Library(self::PLUGIN)->get('theme', 0);
|
637 |
$theme = ($theme) ? $theme : $this->model->get_default_theme_id();
|
638 |
+
$requiredmark = stripslashes(WDW_FM_Library(self::PLUGIN)->get('requiredmark', '*'));
|
639 |
+
$sendemail = stripslashes(WDW_FM_Library(self::PLUGIN)->get('sendemail', ''));
|
640 |
+
$save_uploads = stripslashes(WDW_FM_Library(self::PLUGIN)->get('save_uploads', ''));
|
641 |
+
$mail = stripslashes(WDW_FM_Library(self::PLUGIN)->get('mail', ''));
|
642 |
if ( isset($_POST['mailToAdd']) && esc_html(stripslashes($_POST['mailToAdd'])) != '' ) {
|
643 |
$mail .= esc_html(stripslashes($_POST['mailToAdd'])) . ',';
|
644 |
}
|
645 |
+
$from_mail = stripslashes(WDW_FM_Library(self::PLUGIN)->get('from_mail', ''));
|
646 |
+
$from_name = stripslashes(WDW_FM_Library(self::PLUGIN)->get('from_name', ''));
|
647 |
+
$reply_to = stripslashes(WDW_FM_Library(self::PLUGIN)->get('reply_to', ''));
|
648 |
if ( $from_mail == "other" ) {
|
649 |
+
$from_mail = stripslashes(WDW_FM_Library(self::PLUGIN)->get('mail_from_other', ''));
|
650 |
}
|
651 |
if ( $reply_to == "other" ) {
|
652 |
+
$reply_to = stripslashes(WDW_FM_Library(self::PLUGIN)->get('reply_to_other', ''));
|
653 |
}
|
654 |
+
$script_mail = WDW_FM_Library(self::PLUGIN)->get('script_mail', '{all}', FALSE);
|
655 |
if ( $script_mail == '' ) {
|
656 |
+
$script_mail = '{all}';
|
657 |
+
}
|
658 |
+
$mail_from_user = WDW_FM_Library(self::PLUGIN)->get('mail_from_user', '');
|
659 |
+
$mail_from_name_user = WDW_FM_Library(self::PLUGIN)->get('mail_from_name_user', '');
|
660 |
+
$reply_to_user = WDW_FM_Library(self::PLUGIN)->get('reply_to_user', '');
|
661 |
+
$condition = WDW_FM_Library(self::PLUGIN)->get('condition', '');
|
662 |
+
$mail_cc = WDW_FM_Library(self::PLUGIN)->get('mail_cc', '');
|
663 |
+
$mail_cc_user = WDW_FM_Library(self::PLUGIN)->get('mail_cc_user', '');
|
664 |
+
$mail_bcc = WDW_FM_Library(self::PLUGIN)->get('mail_bcc', '');
|
665 |
+
$mail_bcc_user = WDW_FM_Library(self::PLUGIN)->get('mail_bcc_user', '');
|
666 |
+
$mail_subject = WDW_FM_Library(self::PLUGIN)->get('mail_subject', '');
|
667 |
+
$mail_subject_user = WDW_FM_Library(self::PLUGIN)->get('mail_subject_user', '');
|
668 |
+
$mail_mode = WDW_FM_Library(self::PLUGIN)->get('mail_mode', '');
|
669 |
+
$mail_mode_user = WDW_FM_Library(self::PLUGIN)->get('mail_mode_user', '');
|
670 |
+
$mail_attachment = WDW_FM_Library(self::PLUGIN)->get('mail_attachment', '');
|
671 |
+
$mail_attachment_user = WDW_FM_Library(self::PLUGIN)->get('mail_attachment_user', '');
|
672 |
+
$script_mail_user = WDW_FM_Library(self::PLUGIN)->get('script_mail_user', '{all}', FALSE);
|
673 |
if ( $script_mail_user == '' ) {
|
674 |
+
$script_mail_user = '{all}';
|
675 |
}
|
676 |
+
$submit_text = WDW_FM_Library(self::PLUGIN)->get('submit_text', '', FALSE);
|
677 |
+
$url = WDW_FM_Library(self::PLUGIN)->get('url', '');
|
678 |
+
$tax = WDW_FM_Library(self::PLUGIN)->get('tax', 0);
|
679 |
+
$payment_currency = WDW_FM_Library(self::PLUGIN)->get('payment_currency', '');
|
680 |
+
$paypal_email = WDW_FM_Library(self::PLUGIN)->get('paypal_email', '');
|
681 |
+
$checkout_mode = WDW_FM_Library(self::PLUGIN)->get('checkout_mode', 'testmode');
|
682 |
+
$paypal_mode = WDW_FM_Library(self::PLUGIN)->get('paypal_mode', 0);
|
683 |
|
684 |
// TODO Seclude payment method and payment status.
|
685 |
if ( $paypal_mode == 'paypal' ) {
|
689 |
$paypal_mode = 2;
|
690 |
}
|
691 |
|
692 |
+
$javascript = stripslashes(WDW_FM_Library(self::PLUGIN)->get('javascript', $javascript, false));
|
693 |
+
$user_id_wd = stripslashes(WDW_FM_Library(self::PLUGIN)->get('user_id_wd', 'administrator,'));
|
694 |
+
$frontend_submit_fields = stripslashes(WDW_FM_Library(self::PLUGIN)->get('frontend_submit_fields', ''));
|
695 |
+
$frontend_submit_stat_fields = stripslashes(WDW_FM_Library(self::PLUGIN)->get('frontend_submit_stat_fields', ''));
|
696 |
+
$mail_emptyfields = stripslashes(WDW_FM_Library(self::PLUGIN)->get('mail_emptyfields', 0));
|
697 |
+
$mail_verify = stripslashes(WDW_FM_Library(self::PLUGIN)->get('mail_verify', 0));
|
698 |
+
$mail_verify_expiretime = stripslashes(WDW_FM_Library(self::PLUGIN)->get('mail_verify_expiretime', ''));
|
699 |
$send_to = '';
|
700 |
for ( $i = 0; $i < 20; $i++ ) {
|
701 |
+
if ( WDW_FM_Library(self::PLUGIN)->get('send_to' . $i, 0) ) {
|
702 |
+
$send_to .= '*' . WDW_FM_Library(self::PLUGIN)->get('send_to' . $i, 0) . '*';
|
703 |
}
|
704 |
}
|
705 |
+
if ( WDW_FM_Library(self::PLUGIN)->get('submit_text_type', 0) ) {
|
706 |
+
$submit_text_type = WDW_FM_Library(self::PLUGIN)->get('submit_text_type', 0);
|
707 |
if ( $submit_text_type == 5 ) {
|
708 |
+
$article_id = WDW_FM_Library(self::PLUGIN)->get('page_name', 0);
|
709 |
}
|
710 |
else {
|
711 |
+
$article_id = WDW_FM_Library(self::PLUGIN)->get('post_name', 0);
|
712 |
}
|
713 |
}
|
714 |
else {
|
783 |
'theme' => $theme,
|
784 |
), array( 'id' => $id )); //save theme in backup
|
785 |
$this->model->create_js($id);
|
786 |
+
if (WDFMInstance(self::PLUGIN)->is_free != 2) {
|
787 |
$save_addon = do_action('fm_save_addon_init', $id);
|
788 |
}
|
789 |
$message_id = 8;
|
803 |
|
804 |
$row = $this->model->get_row_data( $id );
|
805 |
if ( empty($row) ) {
|
806 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array('page' => $this->page, 'task' => 'display'), admin_url('admin.php') ) );
|
807 |
}
|
808 |
$fields = explode('*:*new_field*:*', $row->form_fields);
|
809 |
$fields = array_slice($fields, 0, count($fields) - 1);
|
822 |
$params['row'] = $row;
|
823 |
$params['page'] = $this->page;
|
824 |
$params['page_url'] = $this->page_url;
|
825 |
+
$params['page_title'] = '"'. $row->title . '" ' . __('layout', WDFMInstance(self::PLUGIN)->prefix);
|
826 |
+
$params['back_url'] = add_query_arg( array ('page' => 'manage' . WDFMInstance(self::PLUGIN)->menu_postfix,'task' => 'edit','current_id' => $id ), admin_url('admin.php'));
|
827 |
$params['ids'] = $ids;
|
828 |
$params['types'] = $types;
|
829 |
$params['labels'] = $labels;
|
832 |
|
833 |
public function apply_layout( $id ) {
|
834 |
$message = $this->save_db_layout( $id );
|
835 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array('page' => $this->page, 'task' => 'form_layout', 'current_id' => $id, 'message' => $message), admin_url('admin.php') ) );
|
836 |
}
|
837 |
|
838 |
/**
|
843 |
* @return int $id_message
|
844 |
*/
|
845 |
public function save_db_layout( $id ) {
|
846 |
+
$custom_front = WDW_FM_Library(self::PLUGIN)->get('custom_front', '', false);
|
847 |
+
$autogen_layout = WDW_FM_Library(self::PLUGIN)->get('autogen_layout', '');
|
848 |
|
849 |
$update = $this->model->update_data('formmaker', array(
|
850 |
'custom_front' => $custom_front,
|
859 |
}
|
860 |
|
861 |
public function display_options() {
|
862 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', $this->model->get_max_row("formmaker", "id"));
|
863 |
$params = array();
|
864 |
$params['row_form'] = $this->model->get_row_data($id);
|
865 |
if ( empty($params['row_form']) ) {
|
866 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array('page' => $this->page, 'task' => 'display'), admin_url('admin.php') ) );
|
867 |
}
|
868 |
$params['row'] = $this->model->get_display_options($id);
|
869 |
+
$params['page_title'] = '"'. $params['row_form']->title . '" ' . __('display options', WDFMInstance(self::PLUGIN)->prefix);
|
870 |
$params['animation_effects'] = $this->animation_effects;
|
871 |
$params['posts_and_pages'] = $this->model->fm_posts_query();
|
872 |
$params['categories'] = $this->model->fm_categories_query();
|
876 |
$params['page'] = $this->page;
|
877 |
$params['page_url'] = $this->page_url;
|
878 |
$params['back_url'] = add_query_arg( array (
|
879 |
+
'page' => 'manage' . WDFMInstance(self::PLUGIN)->menu_postfix,
|
880 |
'task' => 'edit',
|
881 |
'current_id' => $id,
|
882 |
), admin_url('admin.php')
|
883 |
);
|
884 |
|
885 |
+
$params['fieldset_id'] = WDW_FM_Library(self::PLUGIN)->get('fieldset_id', 'embedded');
|
886 |
$this->view->display_options($params);
|
887 |
}
|
888 |
|
889 |
public function save_display_options() {
|
890 |
$message = $this->save_dis_options();
|
891 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
892 |
|
893 |
+
$current_id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
894 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
895 |
'page' => $page,
|
896 |
'task' => 'edit',
|
897 |
'current_id' => $current_id,
|
901 |
|
902 |
public function apply_display_options() {
|
903 |
$message = $this->save_dis_options();
|
904 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
905 |
+
$fieldset_id = WDW_FM_Library(self::PLUGIN)->get('fieldset_id', 'embedded');
|
906 |
+
$current_id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
907 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
908 |
'page' => $page,
|
909 |
'task' => 'display_options',
|
910 |
'current_id' => $current_id,
|
918 |
* @param int $id
|
919 |
*/
|
920 |
public function remove_query( $id ) {
|
921 |
+
$fieldset_id = WDW_FM_Library(self::PLUGIN)->get('fieldset_id', 'general');
|
922 |
+
$query_id = WDW_FM_Library(self::PLUGIN)->get('query_id',0);
|
923 |
$message = 2;
|
924 |
if( $this->model->delete_formmaker_query( $query_id ) ) {
|
925 |
$message = 3;
|
926 |
}
|
927 |
|
928 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
929 |
'page' => $this->page,
|
930 |
'task' => 'form_options',
|
931 |
'current_id' => $id,
|
948 |
|
949 |
public function save_dis_options() {
|
950 |
$option_data = array(
|
951 |
+
'form_id' => (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0),
|
952 |
+
'scrollbox_loading_delay' => $this->set_delay_freq_positive_val( WDW_FM_Library(self::PLUGIN)->get('scrollbox_loading_delay', 0) ),
|
953 |
+
'popover_animate_effect' => WDW_FM_Library(self::PLUGIN)->get('popover_animate_effect', ''),
|
954 |
+
'popover_loading_delay' => $this->set_delay_freq_positive_val( WDW_FM_Library(self::PLUGIN)->get('popover_loading_delay', 0) ),
|
955 |
+
'popover_frequency' => $this->set_delay_freq_positive_val( WDW_FM_Library(self::PLUGIN)->get('popover_frequency', 0) ),
|
956 |
+
'topbar_position' => WDW_FM_Library(self::PLUGIN)->get('topbar_position', 1),
|
957 |
+
'topbar_remain_top' => WDW_FM_Library(self::PLUGIN)->get('topbar_remain_top', 1),
|
958 |
+
'topbar_closing' => WDW_FM_Library(self::PLUGIN)->get('topbar_closing', 1),
|
959 |
+
'topbar_hide_duration' => $this->set_delay_freq_positive_val( WDW_FM_Library(self::PLUGIN)->get('topbar_hide_duration', 0) ),
|
960 |
+
'scrollbox_position' => WDW_FM_Library(self::PLUGIN)->get('scrollbox_position', 1),
|
961 |
+
'scrollbox_trigger_point' => WDW_FM_Library(self::PLUGIN)->get('scrollbox_trigger_point', 20),
|
962 |
+
'scrollbox_hide_duration' => $this->set_delay_freq_positive_val( WDW_FM_Library(self::PLUGIN)->get('scrollbox_hide_duration', 0)),
|
963 |
+
'scrollbox_auto_hide' => WDW_FM_Library(self::PLUGIN)->get('scrollbox_auto_hide', 1),
|
964 |
+
'hide_mobile' => WDW_FM_Library(self::PLUGIN)->get('hide_mobile', 0),
|
965 |
+
'scrollbox_closing' => WDW_FM_Library(self::PLUGIN)->get('scrollbox_closing', 1),
|
966 |
+
'scrollbox_minimize' => WDW_FM_Library(self::PLUGIN)->get('scrollbox_minimize', 1),
|
967 |
+
'scrollbox_minimize_text' => WDW_FM_Library(self::PLUGIN)->get('scrollbox_minimize_text', ''),
|
968 |
+
'type' => WDW_FM_Library(self::PLUGIN)->get('form_type', 'embadded'),
|
969 |
+
'display_on' => implode(',', WDW_FM_Library(self::PLUGIN)->get('display_on', array())),
|
970 |
+
'posts_include' => WDW_FM_Library(self::PLUGIN)->get('posts_include', ''),
|
971 |
+
'pages_include' => WDW_FM_Library(self::PLUGIN)->get('pages_include', ''),
|
972 |
+
'display_on_categories' => implode(',', WDW_FM_Library(self::PLUGIN)->get('display_on_categories', array())),
|
973 |
+
'current_categories' => WDW_FM_Library(self::PLUGIN)->get('current_categories', ''),
|
974 |
+
'show_for_admin' => WDW_FM_Library(self::PLUGIN)->get('show_for_admin', 0),
|
975 |
);
|
976 |
|
977 |
$save = $this->model->replace_display_options($option_data);
|
994 |
// TODO: remove this function.
|
995 |
public function save_as_copy() {
|
996 |
$message = $this->save_db_as_copy();
|
997 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
998 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
999 |
'page' => $page,
|
1000 |
'task' => 'display',
|
1001 |
'message' => $message,
|
1004 |
|
1005 |
public function save() {
|
1006 |
$message = $this->save_db();
|
1007 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
1008 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
1009 |
'page' => $page,
|
1010 |
'task' => 'display',
|
1011 |
'message' => $message,
|
1014 |
|
1015 |
public function apply() {
|
1016 |
$message = $this->save_db();
|
1017 |
+
$current_id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
1018 |
if ( !$current_id ) {
|
1019 |
$current_id = (int) $this->model->get_max_row('formmaker', 'id');
|
1020 |
}
|
1021 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
1022 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
1023 |
'page' => $page,
|
1024 |
'task' => 'edit',
|
1025 |
'current_id' => $current_id,
|
1037 |
}
|
1038 |
// Occurs just before resetting the form
|
1039 |
function before_reset() {
|
1040 |
+
}
|
1041 |
+
// Occurs after form is submitted and reloaded
|
1042 |
+
function after_submit() {
|
1043 |
+
|
1044 |
}";
|
1045 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
1046 |
+
$title = WDW_FM_Library(self::PLUGIN)->get('title', '');
|
1047 |
+
$theme = (int) WDW_FM_Library(self::PLUGIN)->get('theme', 0);
|
1048 |
+
$theme = ($theme) ? $theme : $this->model->get_default_theme_id();
|
1049 |
+
$form_front = WDW_FM_Library(self::PLUGIN)->get('form_front', '', false);
|
1050 |
+
$sortable = WDW_FM_Library(self::PLUGIN)->get('sortable', 0);
|
1051 |
+
$counter = WDW_FM_Library(self::PLUGIN)->get('counter', 0);
|
1052 |
+
$label_order = WDW_FM_Library(self::PLUGIN)->get('label_order', '');
|
1053 |
+
$pagination = WDW_FM_Library(self::PLUGIN)->get('pagination', '');
|
1054 |
+
$show_title = WDW_FM_Library(self::PLUGIN)->get('show_title', '');
|
1055 |
+
$show_numbers = WDW_FM_Library(self::PLUGIN)->get('show_numbers', '');
|
1056 |
+
$public_key = WDW_FM_Library(self::PLUGIN)->get('public_key', '');
|
1057 |
+
$private_key = WDW_FM_Library(self::PLUGIN)->get('private_key', '');
|
1058 |
+
$recaptcha_theme = WDW_FM_Library(self::PLUGIN)->get('recaptcha_theme', '');
|
1059 |
+
$label_order_current = WDW_FM_Library(self::PLUGIN)->get('label_order_current', '');
|
1060 |
+
$form_fields = WDW_FM_Library(self::PLUGIN)->get('form_fields', '', false);
|
1061 |
+
$header_title = WDW_FM_Library(self::PLUGIN)->get('header_title', '');
|
1062 |
+
$header_description = WDW_FM_Library(self::PLUGIN)->get('header_description', '', FALSE);
|
1063 |
+
$header_image_url = WDW_FM_Library(self::PLUGIN)->get('header_image_url', '');
|
1064 |
+
$header_image_animation = WDW_FM_Library(self::PLUGIN)->get('header_image_animation', '');
|
1065 |
+
$header_hide_image = WDW_FM_Library(self::PLUGIN)->get('header_hide_image', 0);
|
1066 |
+
$type = WDW_FM_Library(self::PLUGIN)->get('form_type', 'embedded');
|
1067 |
$scrollbox_minimize_text = $header_title ? $header_title : 'The form is minimized.';
|
1068 |
if ( $id != 0 ) {
|
1069 |
$save = $this->model->update_data('formmaker', array(
|
1092 |
$this->model->insert_data_to_db('formmaker', array(
|
1093 |
'title' => $title,
|
1094 |
'type' => $type,
|
1095 |
+
'mail' => '{adminemail}',
|
1096 |
'form_front' => $form_front,
|
1097 |
'theme' => $theme,
|
1098 |
'counter' => $counter,
|
1108 |
'url' => '',
|
1109 |
'article_id' => 0,
|
1110 |
'submit_text_type' => 1,
|
1111 |
+
'script_mail' => '{all}',
|
1112 |
+
'script_mail_user' => '{all}',
|
1113 |
'label_order_current' => $label_order_current,
|
1114 |
'tax' => 0,
|
1115 |
'payment_currency' => '',
|
1153 |
'header_hide_image' => $header_hide_image,
|
1154 |
));
|
1155 |
$id = (int) $this->model->get_max_row('formmaker', 'id');
|
1156 |
+
if (WDFMInstance(self::PLUGIN)->is_free == 2) {
|
1157 |
update_option('contact_form_forms', ((get_option('contact_form_forms')) ? (get_option('contact_form_forms')) . ',' . $id : $id));
|
1158 |
}
|
1159 |
$this->model->insert_data_to_db('formmaker_display_options', array(
|
1187 |
'views' => 0,
|
1188 |
));
|
1189 |
}
|
1190 |
+
$backup_id = (int) WDW_FM_Library(self::PLUGIN)->get('backup_id', '');
|
1191 |
if ( $backup_id ) {
|
1192 |
if ( $this->model->get_backup_id($backup_id, $id) ) {
|
1193 |
$this->model->delete_rows(array(
|
1255 |
'url' => '',
|
1256 |
'article_id' => 0,
|
1257 |
'submit_text_type' => 1,
|
1258 |
+
'script_mail' => '{all}',
|
1259 |
+
'script_mail_user' => '{all}',
|
1260 |
'label_order_current' => $label_order_current,
|
1261 |
'tax' => 0,
|
1262 |
'payment_currency' => '',
|
1389 |
}
|
1390 |
|
1391 |
public function update_form_title( $id ) {
|
1392 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
1393 |
+
$form_name = WDW_FM_Library(self::PLUGIN)->get('form_name', '');
|
1394 |
|
1395 |
// check id for db
|
1396 |
if(isset($id) && $id != "") {
|
1398 |
$update = $this->model->update_data( "forms", array('title' => $form_name,), array('id' => $id) );
|
1399 |
if( !$update ){
|
1400 |
$message = 2;
|
1401 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
1402 |
'page' => $page,
|
1403 |
'task' => 'display',
|
1404 |
'message' => $message,
|
1408 |
}
|
1409 |
else { // return message Failed
|
1410 |
$message = 2;
|
1411 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
1412 |
'page' => $page,
|
1413 |
'task' => 'display',
|
1414 |
'message' => $message,
|
admin/controllers/Options_fm.php
CHANGED
@@ -3,22 +3,22 @@
|
|
3 |
/**
|
4 |
* Class FMControllerOptions_fmc
|
5 |
*/
|
6 |
-
class FMControllerOptions_fmc {
|
7 |
private $model;
|
8 |
private $view;
|
9 |
|
10 |
public function __construct() {
|
11 |
-
require_once
|
12 |
$this->model = new FMModelOptions_fmc();
|
13 |
-
require_once
|
14 |
$this->view = new FMViewOptions_fmc();
|
15 |
}
|
16 |
|
17 |
public function execute() {
|
18 |
-
$task =
|
19 |
-
$id = (int)
|
20 |
if ( method_exists($this, $task) ) {
|
21 |
-
check_admin_referer(
|
22 |
$this->$task($id);
|
23 |
}
|
24 |
else {
|
@@ -27,14 +27,14 @@ class FMControllerOptions_fmc {
|
|
27 |
}
|
28 |
|
29 |
public function display() {
|
30 |
-
$fm_settings = get_option('fmc_settings');
|
31 |
$this->view->display($fm_settings);
|
32 |
}
|
33 |
|
34 |
public function save() {
|
35 |
$message = $this->model->save_db();
|
36 |
-
$page =
|
37 |
-
|
38 |
'page' => $page,
|
39 |
'task' => 'display',
|
40 |
'message' => $message,
|
3 |
/**
|
4 |
* Class FMControllerOptions_fmc
|
5 |
*/
|
6 |
+
class FMControllerOptions_fmc extends CFMAdminController {
|
7 |
private $model;
|
8 |
private $view;
|
9 |
|
10 |
public function __construct() {
|
11 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/Options_fm.php";
|
12 |
$this->model = new FMModelOptions_fmc();
|
13 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Options_fm.php";
|
14 |
$this->view = new FMViewOptions_fmc();
|
15 |
}
|
16 |
|
17 |
public function execute() {
|
18 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task');
|
19 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
20 |
if ( method_exists($this, $task) ) {
|
21 |
+
check_admin_referer(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce);
|
22 |
$this->$task($id);
|
23 |
}
|
24 |
else {
|
27 |
}
|
28 |
|
29 |
public function display() {
|
30 |
+
$fm_settings = get_option(WDFMInstance(self::PLUGIN)->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
31 |
$this->view->display($fm_settings);
|
32 |
}
|
33 |
|
34 |
public function save() {
|
35 |
$message = $this->model->save_db();
|
36 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
37 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
38 |
'page' => $page,
|
39 |
'task' => 'display',
|
40 |
'message' => $message,
|
admin/controllers/Paypal_info.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
class FMControllerPaypal_info {
|
4 |
/**
|
5 |
* @var $model
|
6 |
*/
|
@@ -22,12 +22,12 @@ class FMControllerPaypal_info {
|
|
22 |
*/
|
23 |
public function display() {
|
24 |
// Load FMModelPaypal_info class.
|
25 |
-
require_once
|
26 |
$this->model = new FMModelPaypal_info();
|
27 |
// Load FMViewPaypal_info class.
|
28 |
-
require_once
|
29 |
$this->view = new FMViewPaypal_info();
|
30 |
-
$id =
|
31 |
// Get form session by id.
|
32 |
$row = $this->model->get_form_session($id);
|
33 |
// Set params for view.
|
1 |
<?php
|
2 |
|
3 |
+
class FMControllerPaypal_info extends CFMAdminController {
|
4 |
/**
|
5 |
* @var $model
|
6 |
*/
|
22 |
*/
|
23 |
public function display() {
|
24 |
// Load FMModelPaypal_info class.
|
25 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/FMPaypalInfo.php";
|
26 |
$this->model = new FMModelPaypal_info();
|
27 |
// Load FMViewPaypal_info class.
|
28 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMPaypalInfo.php";
|
29 |
$this->view = new FMViewPaypal_info();
|
30 |
+
$id = WDW_FM_Library(self::PLUGIN)->get('id', 0);
|
31 |
// Get form session by id.
|
32 |
$row = $this->model->get_form_session($id);
|
33 |
// Set params for view.
|
admin/controllers/Pricing_fm.php
ADDED
@@ -0,0 +1,54 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Class FMControllerPricing_fmc
|
4 |
+
*/
|
5 |
+
class FMControllerPricing_fmc extends CFMAdminController {
|
6 |
+
/**
|
7 |
+
* @var $model
|
8 |
+
*/
|
9 |
+
private $model;
|
10 |
+
/**
|
11 |
+
* @var $view
|
12 |
+
*/
|
13 |
+
private $view;
|
14 |
+
/**
|
15 |
+
* @var string $page
|
16 |
+
*/
|
17 |
+
private $page;
|
18 |
+
|
19 |
+
public function __construct() {
|
20 |
+
$this->page = WDW_FM_Library(self::PLUGIN)->get('page');
|
21 |
+
$this->page_url = add_query_arg( array (
|
22 |
+
'page' => $this->page,
|
23 |
+
WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce),
|
24 |
+
), admin_url('admin.php')
|
25 |
+
);
|
26 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Pricing_fm.php";
|
27 |
+
$this->view = new FMViewpricing_fmc();
|
28 |
+
}
|
29 |
+
|
30 |
+
/**
|
31 |
+
* Execute.
|
32 |
+
*/
|
33 |
+
public function execute() {
|
34 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task');
|
35 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
36 |
+
if (method_exists($this, $task)) {
|
37 |
+
$this->$task($id);
|
38 |
+
}
|
39 |
+
else {
|
40 |
+
$this->display();
|
41 |
+
}
|
42 |
+
}
|
43 |
+
|
44 |
+
/**
|
45 |
+
* Display.
|
46 |
+
*/
|
47 |
+
public function display() {
|
48 |
+
// Set params for view.
|
49 |
+
$params = array();
|
50 |
+
$params['page'] = $this->page;
|
51 |
+
$params['page_url'] = $this->page_url;
|
52 |
+
$this->view->display( $params );
|
53 |
+
}
|
54 |
+
}
|
admin/controllers/Product_option.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerProduct_option
|
5 |
*/
|
6 |
-
class FMControllerProduct_option {
|
7 |
/**
|
8 |
* @var $view
|
9 |
*/
|
@@ -21,11 +21,11 @@ class FMControllerProduct_option {
|
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewProduct_option class.
|
24 |
-
require_once
|
25 |
$this->view = new FMViewProduct_option();
|
26 |
-
$field_id =
|
27 |
-
$property_id =
|
28 |
-
$url_for_ajax =
|
29 |
// Set params for view.
|
30 |
$params = array();
|
31 |
$params['field_id'] = $field_id;
|
3 |
/**
|
4 |
* Class FMControllerProduct_option
|
5 |
*/
|
6 |
+
class FMControllerProduct_option extends CFMAdminController {
|
7 |
/**
|
8 |
* @var $view
|
9 |
*/
|
21 |
*/
|
22 |
public function display() {
|
23 |
// Load FMViewProduct_option class.
|
24 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMProductOption.php";
|
25 |
$this->view = new FMViewProduct_option();
|
26 |
+
$field_id = WDW_FM_Library(self::PLUGIN)->get('field_id', 0);
|
27 |
+
$property_id = WDW_FM_Library(self::PLUGIN)->get('property_id', '-1');
|
28 |
+
$url_for_ajax = WDW_FM_Library(self::PLUGIN)->get('url_for_ajax', '');
|
29 |
// Set params for view.
|
30 |
$params = array();
|
31 |
$params['field_id'] = $field_id;
|
admin/controllers/Select_data_from_db.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerSelect_data_from_db_fmc
|
5 |
*/
|
6 |
-
class FMControllerSelect_data_from_db_fmc {
|
7 |
/**
|
8 |
* @var $model
|
9 |
*/
|
@@ -15,10 +15,10 @@ class FMControllerSelect_data_from_db_fmc {
|
|
15 |
|
16 |
public function __construct() {
|
17 |
// Load FMModelSelect_data_from_db class.
|
18 |
-
require_once
|
19 |
$this->model = new FMModelSelect_data_from_db_fmc();
|
20 |
// Load FMViewSelect_data_from_db class.
|
21 |
-
require_once
|
22 |
$this->view = new FMViewSelect_data_from_db_fmc();
|
23 |
}
|
24 |
|
@@ -26,12 +26,12 @@ class FMControllerSelect_data_from_db_fmc {
|
|
26 |
* Execute.
|
27 |
*/
|
28 |
public function execute() {
|
29 |
-
$task =
|
30 |
-
$id =
|
31 |
-
$form_id =
|
32 |
-
$field_id =
|
33 |
-
$value_disabled =
|
34 |
-
$field_type =
|
35 |
if ( $task && method_exists($this, $task) ) {
|
36 |
$this->$task($form_id, $field_type = "");
|
37 |
}
|
3 |
/**
|
4 |
* Class FMControllerSelect_data_from_db_fmc
|
5 |
*/
|
6 |
+
class FMControllerSelect_data_from_db_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* @var $model
|
9 |
*/
|
15 |
|
16 |
public function __construct() {
|
17 |
// Load FMModelSelect_data_from_db class.
|
18 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/FMSelectDataFromDb.php";
|
19 |
$this->model = new FMModelSelect_data_from_db_fmc();
|
20 |
// Load FMViewSelect_data_from_db class.
|
21 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMSelectDataFromDb.php";
|
22 |
$this->view = new FMViewSelect_data_from_db_fmc();
|
23 |
}
|
24 |
|
26 |
* Execute.
|
27 |
*/
|
28 |
public function execute() {
|
29 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task', 0);
|
30 |
+
$id = WDW_FM_Library(self::PLUGIN)->get('id', 0);
|
31 |
+
$form_id = WDW_FM_Library(self::PLUGIN)->get('form_id', 0);
|
32 |
+
$field_id = WDW_FM_Library(self::PLUGIN)->get('field_id', 0);
|
33 |
+
$value_disabled = WDW_FM_Library(self::PLUGIN)->get('value_disabled', 0);
|
34 |
+
$field_type = WDW_FM_Library(self::PLUGIN)->get('field_type', '');
|
35 |
if ( $task && method_exists($this, $task) ) {
|
36 |
$this->$task($form_id, $field_type = "");
|
37 |
}
|
admin/controllers/Show_matrix.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
class FMControllerShow_matrix_fmc {
|
4 |
/**
|
5 |
* @var $view
|
6 |
*/
|
@@ -18,7 +18,7 @@ class FMControllerShow_matrix_fmc {
|
|
18 |
*/
|
19 |
public function display() {
|
20 |
// Load FMViewShow_matrix class.
|
21 |
-
require_once
|
22 |
$this->view = new FMViewShow_matrix_fmc();
|
23 |
// Set params for view.
|
24 |
$params = array();
|
1 |
<?php
|
2 |
|
3 |
+
class FMControllerShow_matrix_fmc extends CFMAdminController {
|
4 |
/**
|
5 |
* @var $view
|
6 |
*/
|
18 |
*/
|
19 |
public function display() {
|
20 |
// Load FMViewShow_matrix class.
|
21 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/FMShowMatrix.php";
|
22 |
$this->view = new FMViewShow_matrix_fmc();
|
23 |
// Set params for view.
|
24 |
$params = array();
|
admin/controllers/Submissions_fm.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/**
|
3 |
* Class FMControllerSubmissions_fmc
|
4 |
*/
|
5 |
-
class FMControllerSubmissions_fmc {
|
6 |
/**
|
7 |
* @var $model
|
8 |
*/
|
@@ -34,32 +34,32 @@ class FMControllerSubmissions_fmc {
|
|
34 |
|
35 |
public function __construct() {
|
36 |
// Load FMModelSubmissions_fm class.
|
37 |
-
require_once
|
38 |
$this->model = new FMModelSubmissions_fmc();
|
39 |
// Load FMViewSubmissions_fm class.
|
40 |
-
require_once
|
41 |
$this->view = new FMViewSubmissions_fmc($this->model);
|
42 |
|
43 |
-
$this->page =
|
44 |
$this->page_url = add_query_arg( array (
|
45 |
'page' => $this->page,
|
46 |
-
|
47 |
), admin_url('admin.php')
|
48 |
);
|
49 |
|
50 |
$this->bulk_action_name = 'bulk_action';
|
51 |
$this->actions = array(
|
52 |
'block_ip' => array(
|
53 |
-
'title' => __('Block IPs',
|
54 |
-
$this->bulk_action_name => __('Blocked',
|
55 |
),
|
56 |
'unblock_ip' => array(
|
57 |
-
'title' => __('Unblock IPs',
|
58 |
-
$this->bulk_action_name => __('Unblocked',
|
59 |
),
|
60 |
'delete' => array(
|
61 |
-
'title' => __('Delete',
|
62 |
-
$this->bulk_action_name => __('Deleted',
|
63 |
),
|
64 |
);
|
65 |
|
@@ -78,14 +78,14 @@ class FMControllerSubmissions_fmc {
|
|
78 |
* Execute.
|
79 |
*/
|
80 |
public function execute() {
|
81 |
-
$task =
|
82 |
-
$id = (int)
|
83 |
if ( method_exists($this, $task) ) {
|
84 |
if ( $task != 'display' ) {
|
85 |
-
check_admin_referer(
|
86 |
}
|
87 |
$block_action = $this->bulk_action_name;
|
88 |
-
$action =
|
89 |
if ( $action != -1 ) {
|
90 |
$this->$block_action($action);
|
91 |
}
|
@@ -104,8 +104,8 @@ class FMControllerSubmissions_fmc {
|
|
104 |
* @param $task
|
105 |
*/
|
106 |
public function bulk_action($task) {
|
107 |
-
$form_id =
|
108 |
-
$check =
|
109 |
|
110 |
$message = 0;
|
111 |
$successfully_updated = 0;
|
@@ -122,10 +122,10 @@ class FMControllerSubmissions_fmc {
|
|
122 |
}
|
123 |
if ( $successfully_updated ) {
|
124 |
$block_action = $this->bulk_action_name;
|
125 |
-
$message = sprintf(_n('%s item successfully %s.', '%s items successfully %s.', $successfully_updated,
|
126 |
}
|
127 |
}
|
128 |
-
|
129 |
}
|
130 |
|
131 |
/**
|
@@ -138,7 +138,7 @@ class FMControllerSubmissions_fmc {
|
|
138 |
$params['id'] = $id;
|
139 |
$params['page'] = $this->page;
|
140 |
$params['page_url'] = $this->page_url;
|
141 |
-
$params['page_title'] = __('Submissions',
|
142 |
$params['forms'] = $this->model->get_forms();
|
143 |
|
144 |
$this->view->forms($params);
|
@@ -154,13 +154,13 @@ class FMControllerSubmissions_fmc {
|
|
154 |
$params['id'] = $id;
|
155 |
$params['page'] = $this->page;
|
156 |
$params['page_url'] = $this->page_url;
|
157 |
-
$params['page_title'] = __('Submissions',
|
158 |
$params['actions'] = $this->actions;
|
159 |
|
160 |
// Set pagination params.
|
161 |
$params['pagination_url'] = add_query_arg( array( 'task' => 'display', 'current_id' => $id ), $this->page_url );
|
162 |
$params['page_per_num'] = $this->page_per_num;
|
163 |
-
$page = (int)
|
164 |
$page_num = $page ? ($page - 1) * $params['page_per_num'] : 0;
|
165 |
|
166 |
$params['forms'] = $this->model->get_forms();
|
@@ -228,9 +228,9 @@ class FMControllerSubmissions_fmc {
|
|
228 |
*/
|
229 |
public function show_stats( $id = 0 ) {
|
230 |
ob_clean();
|
231 |
-
$key = (int)
|
232 |
|
233 |
-
$page = (int)
|
234 |
$page_num = $page ? ($page - 1) * $this->page_per_num : 0;
|
235 |
|
236 |
$labels_parameters = $this->model->get_labels_parameters( $id, $page_num, $this->page_per_num);
|
@@ -277,10 +277,10 @@ class FMControllerSubmissions_fmc {
|
|
277 |
* @param int $id
|
278 |
*/
|
279 |
public function edit( $id=0 ) {
|
280 |
-
$form_id =
|
281 |
$data = $this->model->get_data_of_group_id( $id );
|
282 |
if ( empty($data[0]) ) {
|
283 |
-
|
284 |
}
|
285 |
|
286 |
$labels_id = '';
|
@@ -321,7 +321,7 @@ class FMControllerSubmissions_fmc {
|
|
321 |
* @param int $id
|
322 |
*/
|
323 |
public function save( $id = 0 ) {
|
324 |
-
$form_id =
|
325 |
$this->save_db( $id, $form_id );
|
326 |
}
|
327 |
|
@@ -450,7 +450,7 @@ class FMControllerSubmissions_fmc {
|
|
450 |
'message' => $message,
|
451 |
);
|
452 |
|
453 |
-
|
454 |
}
|
455 |
|
456 |
/**
|
@@ -462,7 +462,7 @@ class FMControllerSubmissions_fmc {
|
|
462 |
* @return int
|
463 |
*/
|
464 |
public function delete( $id, $bulk = FALSE ) {
|
465 |
-
$form_id = (int)
|
466 |
$delete = $this->model->delete_row($id);
|
467 |
$message = 2;
|
468 |
if ( $delete ) {
|
@@ -473,7 +473,7 @@ class FMControllerSubmissions_fmc {
|
|
473 |
return $message;
|
474 |
}
|
475 |
|
476 |
-
|
477 |
'page' => $this->page,
|
478 |
'task' => 'display',
|
479 |
'current_id'=> $form_id,
|
@@ -492,7 +492,7 @@ class FMControllerSubmissions_fmc {
|
|
492 |
public function block_ip( $id, $bulk = FALSE ) {
|
493 |
global $wpdb;
|
494 |
|
495 |
-
$form_id = (int)
|
496 |
$q = $wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'formmaker_submits WHERE group_id ="%d"', $id);
|
497 |
$row = $wpdb->get_row($q);
|
498 |
$message = 2;
|
@@ -510,7 +510,7 @@ class FMControllerSubmissions_fmc {
|
|
510 |
return $message;
|
511 |
}
|
512 |
|
513 |
-
|
514 |
'page' => $this->page,
|
515 |
'task' => 'display',
|
516 |
'current_id'=> $form_id,
|
@@ -529,7 +529,7 @@ class FMControllerSubmissions_fmc {
|
|
529 |
public function unblock_ip( $id, $bulk = FALSE ) {
|
530 |
global $wpdb;
|
531 |
|
532 |
-
$form_id = (int)
|
533 |
$q = $wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'formmaker_submits WHERE group_id ="%d"', $id);
|
534 |
$row = $wpdb->get_row($q);
|
535 |
$message = 2;
|
@@ -547,7 +547,7 @@ class FMControllerSubmissions_fmc {
|
|
547 |
return $message;
|
548 |
}
|
549 |
|
550 |
-
|
551 |
'page' => $this->page,
|
552 |
'task' => 'display',
|
553 |
'current_id'=> $form_id,
|
2 |
/**
|
3 |
* Class FMControllerSubmissions_fmc
|
4 |
*/
|
5 |
+
class FMControllerSubmissions_fmc extends CFMAdminController {
|
6 |
/**
|
7 |
* @var $model
|
8 |
*/
|
34 |
|
35 |
public function __construct() {
|
36 |
// Load FMModelSubmissions_fm class.
|
37 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/Submissions_fm.php";
|
38 |
$this->model = new FMModelSubmissions_fmc();
|
39 |
// Load FMViewSubmissions_fm class.
|
40 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Submissions_fm.php";
|
41 |
$this->view = new FMViewSubmissions_fmc($this->model);
|
42 |
|
43 |
+
$this->page = WDW_FM_Library(self::PLUGIN)->get('page');
|
44 |
$this->page_url = add_query_arg( array (
|
45 |
'page' => $this->page,
|
46 |
+
WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce),
|
47 |
), admin_url('admin.php')
|
48 |
);
|
49 |
|
50 |
$this->bulk_action_name = 'bulk_action';
|
51 |
$this->actions = array(
|
52 |
'block_ip' => array(
|
53 |
+
'title' => __('Block IPs', WDFMInstance(self::PLUGIN)->prefix),
|
54 |
+
$this->bulk_action_name => __('Blocked', WDFMInstance(self::PLUGIN)->prefix),
|
55 |
),
|
56 |
'unblock_ip' => array(
|
57 |
+
'title' => __('Unblock IPs', WDFMInstance(self::PLUGIN)->prefix),
|
58 |
+
$this->bulk_action_name => __('Unblocked', WDFMInstance(self::PLUGIN)->prefix),
|
59 |
),
|
60 |
'delete' => array(
|
61 |
+
'title' => __('Delete', WDFMInstance(self::PLUGIN)->prefix),
|
62 |
+
$this->bulk_action_name => __('Deleted', WDFMInstance(self::PLUGIN)->prefix),
|
63 |
),
|
64 |
);
|
65 |
|
78 |
* Execute.
|
79 |
*/
|
80 |
public function execute() {
|
81 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task');
|
82 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
83 |
if ( method_exists($this, $task) ) {
|
84 |
if ( $task != 'display' ) {
|
85 |
+
check_admin_referer(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce);
|
86 |
}
|
87 |
$block_action = $this->bulk_action_name;
|
88 |
+
$action = WDW_FM_Library(self::PLUGIN)->get( $block_action , -1 );
|
89 |
if ( $action != -1 ) {
|
90 |
$this->$block_action($action);
|
91 |
}
|
104 |
* @param $task
|
105 |
*/
|
106 |
public function bulk_action($task) {
|
107 |
+
$form_id = WDW_FM_Library(self::PLUGIN)->get('form_id', 0);
|
108 |
+
$check = WDW_FM_Library(self::PLUGIN)->get('check', '');
|
109 |
|
110 |
$message = 0;
|
111 |
$successfully_updated = 0;
|
122 |
}
|
123 |
if ( $successfully_updated ) {
|
124 |
$block_action = $this->bulk_action_name;
|
125 |
+
$message = sprintf(_n('%s item successfully %s.', '%s items successfully %s.', $successfully_updated, WDFMInstance(self::PLUGIN)->prefix), $successfully_updated, $this->actions[$task][$block_action]);
|
126 |
}
|
127 |
}
|
128 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array('page' => $this->page, 'task' => 'display', 'current_id' => $form_id, ($message === 2 ? 'message' : 'msg') => $message), admin_url('admin.php') ) );
|
129 |
}
|
130 |
|
131 |
/**
|
138 |
$params['id'] = $id;
|
139 |
$params['page'] = $this->page;
|
140 |
$params['page_url'] = $this->page_url;
|
141 |
+
$params['page_title'] = __('Submissions', WDFMInstance(self::PLUGIN)->prefix);
|
142 |
$params['forms'] = $this->model->get_forms();
|
143 |
|
144 |
$this->view->forms($params);
|
154 |
$params['id'] = $id;
|
155 |
$params['page'] = $this->page;
|
156 |
$params['page_url'] = $this->page_url;
|
157 |
+
$params['page_title'] = __('Submissions', WDFMInstance(self::PLUGIN)->prefix);
|
158 |
$params['actions'] = $this->actions;
|
159 |
|
160 |
// Set pagination params.
|
161 |
$params['pagination_url'] = add_query_arg( array( 'task' => 'display', 'current_id' => $id ), $this->page_url );
|
162 |
$params['page_per_num'] = $this->page_per_num;
|
163 |
+
$page = (int) WDW_FM_Library(self::PLUGIN)->get('paged', 1);
|
164 |
$page_num = $page ? ($page - 1) * $params['page_per_num'] : 0;
|
165 |
|
166 |
$params['forms'] = $this->model->get_forms();
|
228 |
*/
|
229 |
public function show_stats( $id = 0 ) {
|
230 |
ob_clean();
|
231 |
+
$key = (int) WDW_FM_Library(self::PLUGIN)->get('sorted_label_key', '');
|
232 |
|
233 |
+
$page = (int) WDW_FM_Library(self::PLUGIN)->get('paged', 1);
|
234 |
$page_num = $page ? ($page - 1) * $this->page_per_num : 0;
|
235 |
|
236 |
$labels_parameters = $this->model->get_labels_parameters( $id, $page_num, $this->page_per_num);
|
277 |
* @param int $id
|
278 |
*/
|
279 |
public function edit( $id=0 ) {
|
280 |
+
$form_id = WDW_FM_Library(self::PLUGIN)->get('form_id', 0);
|
281 |
$data = $this->model->get_data_of_group_id( $id );
|
282 |
if ( empty($data[0]) ) {
|
283 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array('page' => $this->page, 'task' => 'display', 'current_id' => $id ), admin_url('admin.php') ) );
|
284 |
}
|
285 |
|
286 |
$labels_id = '';
|
321 |
* @param int $id
|
322 |
*/
|
323 |
public function save( $id = 0 ) {
|
324 |
+
$form_id = WDW_FM_Library(self::PLUGIN)->get('form_id', 0);
|
325 |
$this->save_db( $id, $form_id );
|
326 |
}
|
327 |
|
450 |
'message' => $message,
|
451 |
);
|
452 |
|
453 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg( $args, admin_url('admin.php')) );
|
454 |
}
|
455 |
|
456 |
/**
|
462 |
* @return int
|
463 |
*/
|
464 |
public function delete( $id, $bulk = FALSE ) {
|
465 |
+
$form_id = (int) WDW_FM_Library(self::PLUGIN)->get('form_id', 0);
|
466 |
$delete = $this->model->delete_row($id);
|
467 |
$message = 2;
|
468 |
if ( $delete ) {
|
473 |
return $message;
|
474 |
}
|
475 |
|
476 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
477 |
'page' => $this->page,
|
478 |
'task' => 'display',
|
479 |
'current_id'=> $form_id,
|
492 |
public function block_ip( $id, $bulk = FALSE ) {
|
493 |
global $wpdb;
|
494 |
|
495 |
+
$form_id = (int) WDW_FM_Library(self::PLUGIN)->get('form_id', 0);
|
496 |
$q = $wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'formmaker_submits WHERE group_id ="%d"', $id);
|
497 |
$row = $wpdb->get_row($q);
|
498 |
$message = 2;
|
510 |
return $message;
|
511 |
}
|
512 |
|
513 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg( array(
|
514 |
'page' => $this->page,
|
515 |
'task' => 'display',
|
516 |
'current_id'=> $form_id,
|
529 |
public function unblock_ip( $id, $bulk = FALSE ) {
|
530 |
global $wpdb;
|
531 |
|
532 |
+
$form_id = (int) WDW_FM_Library(self::PLUGIN)->get('form_id', 0);
|
533 |
$q = $wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'formmaker_submits WHERE group_id ="%d"', $id);
|
534 |
$row = $wpdb->get_row($q);
|
535 |
$message = 2;
|
547 |
return $message;
|
548 |
}
|
549 |
|
550 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg( array(
|
551 |
'page' => $this->page,
|
552 |
'task' => 'display',
|
553 |
'current_id'=> $form_id,
|
admin/controllers/Themes_fm.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMControllerThemes_fmc
|
5 |
*/
|
6 |
-
class FMControllerThemes_fmc {
|
7 |
/**
|
8 |
* @var $model
|
9 |
*/
|
@@ -30,21 +30,21 @@ class FMControllerThemes_fmc {
|
|
30 |
private $actions = array();
|
31 |
|
32 |
public function __construct() {
|
33 |
-
require_once
|
34 |
$this->model = new FMModelThemes_fmc();
|
35 |
-
require_once
|
36 |
$this->view = new FMViewThemes_fmc();
|
37 |
-
$this->page =
|
38 |
$this->bulk_action_name = 'bulk_action';
|
39 |
|
40 |
$this->actions = array(
|
41 |
'duplicate' => array(
|
42 |
-
'title' => __('Duplicate',
|
43 |
-
$this->bulk_action_name => __('duplicated',
|
44 |
),
|
45 |
'delete' => array(
|
46 |
-
'title' => __('Delete',
|
47 |
-
$this->bulk_action_name => __('deleted',
|
48 |
),
|
49 |
);
|
50 |
}
|
@@ -53,14 +53,14 @@ class FMControllerThemes_fmc {
|
|
53 |
* Execute.
|
54 |
*/
|
55 |
public function execute() {
|
56 |
-
$task =
|
57 |
-
$id = (int)
|
58 |
if ( method_exists($this, $task) ) {
|
59 |
if ( $task != 'add' && $task != 'edit' && $task != 'display' ) {
|
60 |
-
check_admin_referer(
|
61 |
}
|
62 |
$block_action = $this->bulk_action_name;
|
63 |
-
$action =
|
64 |
if ( $action != -1 ) {
|
65 |
$this->$block_action($action);
|
66 |
}
|
@@ -80,20 +80,20 @@ class FMControllerThemes_fmc {
|
|
80 |
// Set params for view.
|
81 |
$params = array();
|
82 |
$params['page'] = $this->page;
|
83 |
-
$params['page_title'] = __('Themes',
|
84 |
$params['actions'] = $this->actions;
|
85 |
-
$params['order'] =
|
86 |
-
$params['orderby'] =
|
87 |
// To prevent SQL injections.
|
88 |
$params['order'] = ($params['order'] == 'desc') ? 'desc' : 'asc';
|
89 |
if ( !in_array($params['orderby'], array( 'title', 'default' )) ) {
|
90 |
$params['orderby'] = 'default';
|
91 |
}
|
92 |
$params['items_per_page'] = $this->items_per_page;
|
93 |
-
$page = (int)
|
94 |
$page_num = $page ? ($page - 1) * $params['items_per_page'] : 0;
|
95 |
$params['page_num'] = $page_num;
|
96 |
-
$params['search'] =
|
97 |
$params['total'] = $this->model->total();
|
98 |
$params['rows_data'] = $this->model->get_rows_data($params);
|
99 |
$this->view->display($params);
|
@@ -108,7 +108,7 @@ class FMControllerThemes_fmc {
|
|
108 |
$message = 0;
|
109 |
$successfully_updated = 0;
|
110 |
|
111 |
-
$check =
|
112 |
|
113 |
if ( $check ) {
|
114 |
foreach ( $check as $form_id => $item ) {
|
@@ -122,11 +122,11 @@ class FMControllerThemes_fmc {
|
|
122 |
}
|
123 |
if ( $successfully_updated ) {
|
124 |
$block_action = $this->bulk_action_name;
|
125 |
-
$message = sprintf(_n('%s item successfully %s.', '%s items successfully %s.', $successfully_updated,
|
126 |
}
|
127 |
}
|
128 |
|
129 |
-
|
130 |
'page' => $this->page,
|
131 |
'task' => 'display',
|
132 |
($message === 2 ? 'message' : 'msg') => $message,
|
@@ -163,7 +163,7 @@ class FMControllerThemes_fmc {
|
|
163 |
if ( $bulk ) {
|
164 |
return $message;
|
165 |
}
|
166 |
-
|
167 |
}
|
168 |
|
169 |
/**
|
@@ -195,7 +195,7 @@ class FMControllerThemes_fmc {
|
|
195 |
return $message;
|
196 |
}
|
197 |
else {
|
198 |
-
|
199 |
'page' => $this->page,
|
200 |
'task' => 'display',
|
201 |
'message' => $message,
|
@@ -214,23 +214,23 @@ class FMControllerThemes_fmc {
|
|
214 |
$params['row'] = $this->model->get_row_data($params['id'], FALSE);
|
215 |
|
216 |
if ( $id != 0 && empty($params['row']) ) {
|
217 |
-
|
218 |
}
|
219 |
$params['page_title'] = $params['row']->title;
|
220 |
$params['param_values'] = $params['row']->css;
|
221 |
$params['tabs'] = array(
|
222 |
-
'global' => __('Global Parameters',
|
223 |
-
'header' => __('Header',
|
224 |
-
'content' => __('Content',
|
225 |
-
'input_select' => __('Inputbox',
|
226 |
-
'choices' => __('Choices',
|
227 |
-
'subscribe' => __('General Buttons',
|
228 |
-
'paigination' => __('Pagination',
|
229 |
-
'buttons' => __('Buttons',
|
230 |
-
'close_button' => __('Close(Minimize) Button',
|
231 |
-
'minimize' => __('Minimize Text',
|
232 |
-
'other' => __('Other',
|
233 |
-
'custom_css' => __('Custom CSS',
|
234 |
);
|
235 |
$border_types = array(
|
236 |
'' => '',
|
@@ -249,10 +249,10 @@ class FMControllerThemes_fmc {
|
|
249 |
);
|
250 |
$borders = array(
|
251 |
'' => '',
|
252 |
-
'top' => __('Top',
|
253 |
-
'right' => __('Right',
|
254 |
-
'bottom' => __('Bottom',
|
255 |
-
'left' => __('Left',
|
256 |
);
|
257 |
$position_types = array(
|
258 |
'' => '',
|
@@ -269,7 +269,7 @@ class FMControllerThemes_fmc {
|
|
269 |
'lighter' => 'Lighter',
|
270 |
'initial' => 'Initial',
|
271 |
);
|
272 |
-
$aligns = array( '' => '', 'left' => __('Left',
|
273 |
$basic_fonts = array(
|
274 |
'' => '',
|
275 |
'arial' => 'Arial',
|
@@ -292,7 +292,7 @@ class FMControllerThemes_fmc {
|
|
292 |
'initial' => 'initial',
|
293 |
'inherit' => 'inherit',
|
294 |
);
|
295 |
-
$google_fonts =
|
296 |
$font_families = $basic_fonts + $google_fonts;
|
297 |
$params['fonts'] = implode("|", str_replace(' ', '+', $google_fonts));
|
298 |
$params['all_params'] = $this->all_params($params['param_values'], $borders, $border_types, $font_weights, $position_types, $aligns, $bg_repeats, $font_families);
|
@@ -312,7 +312,7 @@ class FMControllerThemes_fmc {
|
|
312 |
'after' => '',
|
313 |
),
|
314 |
array(
|
315 |
-
'label' => __('Font Family',
|
316 |
'name' => 'GPFontFamily',
|
317 |
'type' => 'select',
|
318 |
'options' => $font_families,
|
@@ -321,7 +321,7 @@ class FMControllerThemes_fmc {
|
|
321 |
'after' => '',
|
322 |
),
|
323 |
array(
|
324 |
-
'label' => __('Width',
|
325 |
'name' => 'AGPWidth',
|
326 |
'type' => 'text',
|
327 |
'class' => '',
|
@@ -329,7 +329,7 @@ class FMControllerThemes_fmc {
|
|
329 |
'after' => '%',
|
330 |
),
|
331 |
array(
|
332 |
-
'label' => __('Width (for scrollbox, popup form types)',
|
333 |
'name' => 'AGPSPWidth',
|
334 |
'type' => 'text',
|
335 |
'class' => '',
|
@@ -337,25 +337,25 @@ class FMControllerThemes_fmc {
|
|
337 |
'after' => '%',
|
338 |
),
|
339 |
array(
|
340 |
-
'label' => __('Padding',
|
341 |
'name' => 'AGPPadding',
|
342 |
'type' => 'text',
|
343 |
'class' => '',
|
344 |
-
'placeholder' => __('e.g. 3px 5px or 3% 5%',
|
345 |
'value' => isset($param_values->AGPPadding) ? $param_values->AGPPadding : '',
|
346 |
'after' => '',
|
347 |
),
|
348 |
array(
|
349 |
-
'label' => __('Margin',
|
350 |
'name' => 'AGPMargin',
|
351 |
'type' => 'text',
|
352 |
'class' => '',
|
353 |
'value' => isset($param_values->AGPMargin) ? $param_values->AGPMargin : '',
|
354 |
-
'placeholder' => __('e.g. 5px 10px or 5% 10%',
|
355 |
'after' => '',
|
356 |
),
|
357 |
array(
|
358 |
-
'label' => __('Border',
|
359 |
'name' => 'AGPBorder',
|
360 |
'type' => 'checkbox',
|
361 |
'options' => $borders,
|
@@ -363,16 +363,16 @@ class FMControllerThemes_fmc {
|
|
363 |
'after' => '',
|
364 |
),
|
365 |
array(
|
366 |
-
'label' => __('Border Color',
|
367 |
'name' => 'AGPBorderColor',
|
368 |
'type' => 'text',
|
369 |
'class' => 'color',
|
370 |
-
'placeholder' => __('e.g.',
|
371 |
'value' => isset($param_values->AGPBorderColor) ? $param_values->AGPBorderColor : '',
|
372 |
'after' => '',
|
373 |
),
|
374 |
array(
|
375 |
-
'label' => __('Border Type',
|
376 |
'name' => 'AGPBorderType',
|
377 |
'type' => 'select',
|
378 |
'options' => $border_types,
|
@@ -381,7 +381,7 @@ class FMControllerThemes_fmc {
|
|
381 |
'after' => '',
|
382 |
),
|
383 |
array(
|
384 |
-
'label' => __('Border Width',
|
385 |
'name' => 'AGPBorderWidth',
|
386 |
'type' => 'text',
|
387 |
'class' => '',
|
@@ -389,7 +389,7 @@ class FMControllerThemes_fmc {
|
|
389 |
'after' => 'px',
|
390 |
),
|
391 |
array(
|
392 |
-
'label' => __('Border Radius',
|
393 |
'name' => 'AGPBorderRadius',
|
394 |
'type' => 'text',
|
395 |
'class' => '',
|
@@ -397,25 +397,25 @@ class FMControllerThemes_fmc {
|
|
397 |
'after' => 'px',
|
398 |
),
|
399 |
array(
|
400 |
-
'label' => __('Box Shadow',
|
401 |
'name' => 'AGPBoxShadow',
|
402 |
'type' => 'text',
|
403 |
'class' => '',
|
404 |
'value' => isset($param_values->AGPBoxShadow) ? $param_values->AGPBoxShadow : '',
|
405 |
-
'placeholder' => __('e.g.',
|
406 |
'after' => '</div>',
|
407 |
),
|
408 |
),
|
409 |
'header' => array(
|
410 |
array(
|
411 |
-
'label' => __('General Parameters',
|
412 |
'type' => 'panel',
|
413 |
'class' => 'col-md-12',
|
414 |
'label_class' => 'fm-mini-title',
|
415 |
'after' => '<br/>',
|
416 |
),
|
417 |
array(
|
418 |
-
'label' => __('Alignment',
|
419 |
'name' => 'HPAlign',
|
420 |
'type' => 'select',
|
421 |
'options' => $borders,
|
@@ -424,16 +424,16 @@ class FMControllerThemes_fmc {
|
|
424 |
'after' => '',
|
425 |
),
|
426 |
array(
|
427 |
-
'label' => __('Background Color',
|
428 |
'name' => 'HPBGColor',
|
429 |
'type' => 'text',
|
430 |
'class' => 'color',
|
431 |
-
'placeholder' => __('e.g.',
|
432 |
'value' => isset($param_values->HPBGColor) ? $param_values->HPBGColor : '',
|
433 |
'after' => '',
|
434 |
),
|
435 |
array(
|
436 |
-
'label' => __('Width',
|
437 |
'name' => 'HPWidth',
|
438 |
'type' => 'text',
|
439 |
'class' => '',
|
@@ -441,7 +441,7 @@ class FMControllerThemes_fmc {
|
|
441 |
'after' => '%',
|
442 |
),
|
443 |
array(
|
444 |
-
'label' => __('Width (for topbar form type)',
|
445 |
'name' => 'HTPWidth',
|
446 |
'type' => 'text',
|
447 |
'class' => '',
|
@@ -449,25 +449,25 @@ class FMControllerThemes_fmc {
|
|
449 |
'after' => '%',
|
450 |
),
|
451 |
array(
|
452 |
-
'label' => __('Padding',
|
453 |
'name' => 'HPPadding',
|
454 |
'type' => 'text',
|
455 |
'class' => '',
|
456 |
-
'placeholder' => __('e.g.',
|
457 |
'value' => isset($param_values->HPPadding) ? $param_values->HPPadding : '',
|
458 |
'after' => '',
|
459 |
),
|
460 |
array(
|
461 |
-
'label' => __('Margin',
|
462 |
'name' => 'HPMargin',
|
463 |
'type' => 'text',
|
464 |
'class' => '',
|
465 |
'value' => isset($param_values->HPMargin) ? $param_values->HPMargin : '',
|
466 |
-
'placeholder' => __('e.g.',
|
467 |
'after' => '',
|
468 |
),
|
469 |
array(
|
470 |
-
'label' => __('Text Align',
|
471 |
'name' => 'HPTextAlign',
|
472 |
'type' => 'select',
|
473 |
'options' => $aligns,
|
@@ -476,7 +476,7 @@ class FMControllerThemes_fmc {
|
|
476 |
'after' => '',
|
477 |
),
|
478 |
array(
|
479 |
-
'label' => __('Border',
|
480 |
'name' => 'HPBorder',
|
481 |
'type' => 'checkbox',
|
482 |
'options' => $borders,
|
@@ -484,16 +484,16 @@ class FMControllerThemes_fmc {
|
|
484 |
'after' => '',
|
485 |
),
|
486 |
array(
|
487 |
-
'label' => __('Border Color',
|
488 |
'name' => 'HPBorderColor',
|
489 |
'type' => 'text',
|
490 |
'class' => 'color',
|
491 |
-
'placeholder' => __('e.g.',
|
492 |
'value' => isset($param_values->HPBorderColor) ? $param_values->HPBorderColor : '',
|
493 |
'after' => '',
|
494 |
),
|
495 |
array(
|
496 |
-
'label' => __('Border Type',
|
497 |
'name' => 'HPBorderType',
|
498 |
'type' => 'select',
|
499 |
'options' => $border_types,
|
@@ -502,7 +502,7 @@ class FMControllerThemes_fmc {
|
|
502 |
'after' => '',
|
503 |
),
|
504 |
array(
|
505 |
-
'label' => __('Border Width',
|
506 |
'name' => 'HPBorderWidth',
|
507 |
'type' => 'text',
|
508 |
'class' => '',
|
@@ -510,7 +510,7 @@ class FMControllerThemes_fmc {
|
|
510 |
'after' => 'px',
|
511 |
),
|
512 |
array(
|
513 |
-
'label' => __('Border Radius',
|
514 |
'name' => 'HPBorderRadius',
|
515 |
'type' => 'text',
|
516 |
'class' => '',
|
@@ -518,14 +518,14 @@ class FMControllerThemes_fmc {
|
|
518 |
'after' => 'px</div>',
|
519 |
),
|
520 |
array(
|
521 |
-
'label' => __('Title Parameters',
|
522 |
'type' => 'panel',
|
523 |
'class' => 'col-md-12',
|
524 |
'label_class' => 'fm-mini-title',
|
525 |
'after' => '<br/>',
|
526 |
),
|
527 |
array(
|
528 |
-
'label' => __('Font Size',
|
529 |
'name' => 'HTPFontSize',
|
530 |
'type' => 'text',
|
531 |
'class' => '',
|
@@ -533,7 +533,7 @@ class FMControllerThemes_fmc {
|
|
533 |
'after' => 'px',
|
534 |
),
|
535 |
array(
|
536 |
-
'label' => __('Font Weight',
|
537 |
'name' => 'HTPWeight',
|
538 |
'type' => 'select',
|
539 |
'options' => $font_weights,
|
@@ -542,22 +542,22 @@ class FMControllerThemes_fmc {
|
|
542 |
'after' => '',
|
543 |
),
|
544 |
array(
|
545 |
-
'label' => __('Color',
|
546 |
'name' => 'HTPColor',
|
547 |
'type' => 'text',
|
548 |
'class' => 'color',
|
549 |
-
'placeholder' => __('e.g.',
|
550 |
'value' => isset($param_values->HTPColor) ? $param_values->HTPColor : '',
|
551 |
'after' => '',
|
552 |
),
|
553 |
array(
|
554 |
-
'label' => __('Description Parameters',
|
555 |
'type' => 'label',
|
556 |
'class' => 'fm-mini-title',
|
557 |
'after' => '<br/>',
|
558 |
),
|
559 |
array(
|
560 |
-
'label' => __('Font Size',
|
561 |
'name' => 'HDPFontSize',
|
562 |
'type' => 'text',
|
563 |
'class' => '',
|
@@ -565,22 +565,22 @@ class FMControllerThemes_fmc {
|
|
565 |
'after' => 'px',
|
566 |
),
|
567 |
array(
|
568 |
-
'label' => __('Color',
|
569 |
'name' => 'HDPColor',
|
570 |
'type' => 'text',
|
571 |
'class' => 'color',
|
572 |
-
'placeholder' => __('e.g.',
|
573 |
'value' => isset($param_values->HDPColor) ? $param_values->HDPColor : '',
|
574 |
'after' => '',
|
575 |
),
|
576 |
array(
|
577 |
-
'label' => __('Image Parameters',
|
578 |
'type' => 'label',
|
579 |
'class' => 'fm-mini-title',
|
580 |
'after' => '<br/>',
|
581 |
),
|
582 |
array(
|
583 |
-
'label' => __('Alignment',
|
584 |
'name' => 'HIPAlign',
|
585 |
'type' => 'select',
|
586 |
'options' => $borders,
|
@@ -589,7 +589,7 @@ class FMControllerThemes_fmc {
|
|
589 |
'after' => '',
|
590 |
),
|
591 |
array(
|
592 |
-
'label' => __('Width',
|
593 |
'name' => 'HIPWidth',
|
594 |
'type' => 'text',
|
595 |
'class' => '',
|
@@ -597,7 +597,7 @@ class FMControllerThemes_fmc {
|
|
597 |
'after' => 'px',
|
598 |
),
|
599 |
array(
|
600 |
-
'label' => __('Height',
|
601 |
'name' => 'HIPHeight',
|
602 |
'type' => 'text',
|
603 |
'class' => '',
|
@@ -607,23 +607,23 @@ class FMControllerThemes_fmc {
|
|
607 |
),
|
608 |
'content' => array(
|
609 |
array(
|
610 |
-
'label' => __('General Parameters',
|
611 |
'type' => 'panel',
|
612 |
'class' => 'col-md-12',
|
613 |
'label_class' => 'fm-mini-title',
|
614 |
'after' => '<br/>',
|
615 |
),
|
616 |
array(
|
617 |
-
'label' => __('Background Color',
|
618 |
'name' => 'GPBGColor',
|
619 |
'type' => 'text',
|
620 |
'class' => 'color',
|
621 |
-
'placeholder' => __('e.g.',
|
622 |
'value' => isset($param_values->GPBGColor) ? $param_values->GPBGColor : '',
|
623 |
'after' => '',
|
624 |
),
|
625 |
array(
|
626 |
-
'label' => __('Font Size',
|
627 |
'name' => 'GPFontSize',
|
628 |
'type' => 'text',
|
629 |
'class' => '',
|
@@ -631,7 +631,7 @@ class FMControllerThemes_fmc {
|
|
631 |
'after' => 'px',
|
632 |
),
|
633 |
array(
|
634 |
-
'label' => __('Font Weight',
|
635 |
'name' => 'GPFontWeight',
|
636 |
'type' => 'select',
|
637 |
'options' => $font_weights,
|
@@ -640,7 +640,7 @@ class FMControllerThemes_fmc {
|
|
640 |
'after' => '',
|
641 |
),
|
642 |
array(
|
643 |
-
'label' => __('Width',
|
644 |
'name' => 'GPWidth',
|
645 |
'type' => 'text',
|
646 |
'class' => '',
|
@@ -648,7 +648,7 @@ class FMControllerThemes_fmc {
|
|
648 |
'after' => '%',
|
649 |
),
|
650 |
array(
|
651 |
-
'label' => __('Width (for topbar form type)',
|
652 |
'name' => 'GTPWidth',
|
653 |
'type' => 'text',
|
654 |
'class' => '',
|
@@ -656,7 +656,7 @@ class FMControllerThemes_fmc {
|
|
656 |
'after' => '%',
|
657 |
),
|
658 |
array(
|
659 |
-
'label' => __('Alignment',
|
660 |
'name' => 'GPAlign',
|
661 |
'type' => 'select',
|
662 |
'options' => $aligns,
|
@@ -665,16 +665,16 @@ class FMControllerThemes_fmc {
|
|
665 |
'after' => '',
|
666 |
),
|
667 |
array(
|
668 |
-
'label' => __('Background URL',
|
669 |
'name' => 'GPBackground',
|
670 |
'type' => 'text',
|
671 |
'class' => '',
|
672 |
-
// 'placeholder' => __('e.g. http:// or https://',
|
673 |
'value' => isset($param_values->GPBackground) ? $param_values->GPBackground : '',
|
674 |
'after' => '',
|
675 |
),
|
676 |
array(
|
677 |
-
'label' => __('Background Repeat',
|
678 |
'name' => 'GPBackgroundRepeat',
|
679 |
'type' => 'select',
|
680 |
'options' => $bg_repeats,
|
@@ -683,12 +683,12 @@ class FMControllerThemes_fmc {
|
|
683 |
'after' => '',
|
684 |
),
|
685 |
array(
|
686 |
-
'label' => __('Background Position',
|
687 |
'name1' => 'GPBGPosition1',
|
688 |
'name2' => 'GPBGPosition2',
|
689 |
'type' => '2text',
|
690 |
'class' => 'fm-2text',
|
691 |
-
'placeholder' => __('e.g.',
|
692 |
'value1' => isset($param_values->GPBGPosition1) ? $param_values->GPBGPosition1 : '',
|
693 |
'value2' => isset($param_values->GPBGPosition2) ? $param_values->GPBGPosition2 : '',
|
694 |
'before1' => '',
|
@@ -696,12 +696,12 @@ class FMControllerThemes_fmc {
|
|
696 |
'after' => '',
|
697 |
),
|
698 |
array(
|
699 |
-
'label' => __('Background Size',
|
700 |
'name1' => 'GPBGSize1',
|
701 |
'name2' => 'GPBGSize2',
|
702 |
'type' => '2text',
|
703 |
'class' => 'fm-2text',
|
704 |
-
'placeholder' => __('e.g.',
|
705 |
'value1' => isset($param_values->GPBGSize1) ? $param_values->GPBGSize1 : '',
|
706 |
'value2' => isset($param_values->GPBGSize2) ? $param_values->GPBGSize2 : '',
|
707 |
'before1' => '',
|
@@ -709,7 +709,7 @@ class FMControllerThemes_fmc {
|
|
709 |
'after' => '',
|
710 |
),
|
711 |
array(
|
712 |
-
'label' => __('Color',
|
713 |
'name' => 'GPColor',
|
714 |
'type' => 'text',
|
715 |
'class' => 'color',
|
@@ -717,25 +717,25 @@ class FMControllerThemes_fmc {
|
|
717 |
'after' => '',
|
718 |
),
|
719 |
array(
|
720 |
-
'label' => __('Padding',
|
721 |
'name' => 'GPPadding',
|
722 |
'type' => 'text',
|
723 |
'class' => '',
|
724 |
-
'placeholder' => __('e.g.',
|
725 |
'value' => isset($param_values->GPPadding) ? $param_values->GPPadding : '',
|
726 |
'after' => '',
|
727 |
),
|
728 |
array(
|
729 |
-
'label' => __('Margin',
|
730 |
'name' => 'GPMargin',
|
731 |
'type' => 'text',
|
732 |
'class' => '',
|
733 |
'value' => isset($param_values->GPMargin) ? $param_values->GPMargin : '',
|
734 |
-
'placeholder' => __('e.g.',
|
735 |
'after' => '',
|
736 |
),
|
737 |
array(
|
738 |
-
'label' => __('Border',
|
739 |
'name' => 'GPBorder',
|
740 |
'type' => 'checkbox',
|
741 |
'options' => $borders,
|
@@ -743,7 +743,7 @@ class FMControllerThemes_fmc {
|
|
743 |
'after' => '',
|
744 |
),
|
745 |
array(
|
746 |
-
'label' => __('Border Color',
|
747 |
'name' => 'GPBorderColor',
|
748 |
'type' => 'text',
|
749 |
'class' => 'color',
|
@@ -751,7 +751,7 @@ class FMControllerThemes_fmc {
|
|
751 |
'after' => '',
|
752 |
),
|
753 |
array(
|
754 |
-
'label' => __('Border Type',
|
755 |
'name' => 'GPBorderType',
|
756 |
'type' => 'select',
|
757 |
'options' => $border_types,
|
@@ -760,7 +760,7 @@ class FMControllerThemes_fmc {
|
|
760 |
'after' => '',
|
761 |
),
|
762 |
array(
|
763 |
-
'label' => __('Border Width',
|
764 |
'name' => 'GPBorderWidth',
|
765 |
'type' => 'text',
|
766 |
'class' => '',
|
@@ -768,7 +768,7 @@ class FMControllerThemes_fmc {
|
|
768 |
'after' => 'px',
|
769 |
),
|
770 |
array(
|
771 |
-
'label' => __('Border Radius',
|
772 |
'name' => 'GPBorderRadius',
|
773 |
'type' => 'text',
|
774 |
'class' => '',
|
@@ -776,14 +776,14 @@ class FMControllerThemes_fmc {
|
|
776 |
'after' => 'px</div>',
|
777 |
),
|
778 |
array(
|
779 |
-
'label' => __('Mini labels (name, phone, address, checkbox, radio) Parameters',
|
780 |
'type' => 'panel',
|
781 |
'class' => 'col-md-12',
|
782 |
'label_class' => 'fm-mini-title',
|
783 |
'after' => '<br/>',
|
784 |
),
|
785 |
array(
|
786 |
-
'label' => __('Font Size',
|
787 |
'name' => 'GPMLFontSize',
|
788 |
'type' => 'text',
|
789 |
'class' => '',
|
@@ -791,7 +791,7 @@ class FMControllerThemes_fmc {
|
|
791 |
'after' => 'px',
|
792 |
),
|
793 |
array(
|
794 |
-
'label' => __('Font Weight',
|
795 |
'name' => 'GPMLFontWeight',
|
796 |
'type' => 'select',
|
797 |
'options' => $font_weights,
|
@@ -800,97 +800,97 @@ class FMControllerThemes_fmc {
|
|
800 |
'after' => '',
|
801 |
),
|
802 |
array(
|
803 |
-
'label' => __('Color',
|
804 |
'name' => 'GPMLColor',
|
805 |
'type' => 'text',
|
806 |
'class' => 'color',
|
807 |
-
'placeholder' => __('e.g.',
|
808 |
'value' => isset($param_values->GPMLColor) ? $param_values->GPMLColor : '',
|
809 |
'after' => '',
|
810 |
),
|
811 |
array(
|
812 |
-
'label' => __('Padding',
|
813 |
'name' => 'GPMLPadding',
|
814 |
'type' => 'text',
|
815 |
'class' => '',
|
816 |
-
'placeholder' => __('e.g.',
|
817 |
'value' => isset($param_values->GPMLPadding) ? $param_values->GPMLPadding : '',
|
818 |
'after' => '',
|
819 |
),
|
820 |
array(
|
821 |
-
'label' => __('Margin',
|
822 |
'name' => 'GPMLMargin',
|
823 |
'type' => 'text',
|
824 |
'class' => '',
|
825 |
-
'placeholder' => __('e.g.',
|
826 |
'value' => isset($param_values->GPMLMargin) ? $param_values->GPMLMargin : '',
|
827 |
'after' => '',
|
828 |
),
|
829 |
array(
|
830 |
-
'label' => __('Section Parameters',
|
831 |
'type' => 'label',
|
832 |
'class' => 'fm-mini-title',
|
833 |
'after' => '<br/>',
|
834 |
),
|
835 |
array(
|
836 |
-
'label' => __('Background Color',
|
837 |
'name' => 'SEPBGColor',
|
838 |
'type' => 'text',
|
839 |
'class' => 'color',
|
840 |
-
'placeholder' => __('e.g.',
|
841 |
'value' => isset($param_values->SEPBGColor) ? $param_values->SEPBGColor : '',
|
842 |
'after' => '',
|
843 |
),
|
844 |
array(
|
845 |
-
'label' => __('Padding',
|
846 |
'name' => 'SEPPadding',
|
847 |
'type' => 'text',
|
848 |
'class' => '',
|
849 |
-
'placeholder' => __('e.g.',
|
850 |
'value' => isset($param_values->SEPPadding) ? $param_values->SEPPadding : '',
|
851 |
'after' => '',
|
852 |
),
|
853 |
array(
|
854 |
-
'label' => __('Margin',
|
855 |
'name' => 'SEPMargin',
|
856 |
'type' => 'text',
|
857 |
'class' => '',
|
858 |
-
'placeholder' => __('e.g.',
|
859 |
'value' => isset($param_values->SEPMargin) ? $param_values->SEPMargin : '',
|
860 |
'after' => '',
|
861 |
),
|
862 |
array(
|
863 |
-
'label' => __('Section Column Parameters',
|
864 |
'type' => 'label',
|
865 |
'class' => 'fm-mini-title',
|
866 |
'after' => '<br/>',
|
867 |
),
|
868 |
array(
|
869 |
-
'label' => __('Padding',
|
870 |
'name' => 'COPPadding',
|
871 |
'type' => 'text',
|
872 |
'class' => '',
|
873 |
-
'placeholder' => __('e.g.',
|
874 |
'value' => isset($param_values->COPPadding) ? $param_values->COPPadding : '',
|
875 |
'after' => '',
|
876 |
),
|
877 |
array(
|
878 |
-
'label' => __('Margin',
|
879 |
'name' => 'COPMargin',
|
880 |
'type' => 'text',
|
881 |
'class' => '',
|
882 |
-
'placeholder' => __('e.g.',
|
883 |
'value' => isset($param_values->COPMargin) ? $param_values->COPMargin : '',
|
884 |
'after' => '',
|
885 |
),
|
886 |
array(
|
887 |
-
'label' => __('Footer Parameters',
|
888 |
'type' => 'label',
|
889 |
'class' => 'fm-mini-title',
|
890 |
'after' => '<br/>',
|
891 |
),
|
892 |
array(
|
893 |
-
'label' => __('Width',
|
894 |
'name' => 'FPWidth',
|
895 |
'type' => 'text',
|
896 |
'class' => '',
|
@@ -898,20 +898,20 @@ class FMControllerThemes_fmc {
|
|
898 |
'after' => '%',
|
899 |
),
|
900 |
array(
|
901 |
-
'label' => __('Padding',
|
902 |
'name' => 'FPPadding',
|
903 |
'type' => 'text',
|
904 |
'class' => '',
|
905 |
-
'placeholder' => __('e.g.',
|
906 |
'value' => isset($param_values->FPPadding) ? $param_values->FPPadding : '',
|
907 |
'after' => '',
|
908 |
),
|
909 |
array(
|
910 |
-
'label' => __('Margin',
|
911 |
'name' => 'FPMargin',
|
912 |
'type' => 'text',
|
913 |
'class' => '',
|
914 |
-
'placeholder' => __('e.g.',
|
915 |
'value' => isset($param_values->FPMargin) ? $param_values->FPMargin : '',
|
916 |
'after' => '</div>',
|
917 |
),
|
@@ -925,7 +925,7 @@ class FMControllerThemes_fmc {
|
|
925 |
'after' => '',
|
926 |
),
|
927 |
array(
|
928 |
-
'label' => __('Height',
|
929 |
'name' => 'IPHeight',
|
930 |
'type' => 'text',
|
931 |
'class' => '',
|
@@ -933,7 +933,7 @@ class FMControllerThemes_fmc {
|
|
933 |
'after' => 'px',
|
934 |
),
|
935 |
array(
|
936 |
-
'label' => __('Font Size',
|
937 |
'name' => 'IPFontSize',
|
938 |
'type' => 'text',
|
939 |
'class' => '',
|
@@ -941,7 +941,7 @@ class FMControllerThemes_fmc {
|
|
941 |
'after' => 'px',
|
942 |
),
|
943 |
array(
|
944 |
-
'label' => __('Font Weight',
|
945 |
'name' => 'IPFontWeight',
|
946 |
'type' => 'select',
|
947 |
'options' => $font_weights,
|
@@ -950,43 +950,43 @@ class FMControllerThemes_fmc {
|
|
950 |
'after' => '',
|
951 |
),
|
952 |
array(
|
953 |
-
'label' => __('Background Color',
|
954 |
'name' => 'IPBGColor',
|
955 |
'type' => 'text',
|
956 |
'class' => 'color',
|
957 |
-
'placeholder' => __('e.g.',
|
958 |
'value' => isset($param_values->IPBGColor) ? $param_values->IPBGColor : '',
|
959 |
'after' => '',
|
960 |
),
|
961 |
array(
|
962 |
-
'label' => __('Color',
|
963 |
'name' => 'IPColor',
|
964 |
'type' => 'text',
|
965 |
'class' => 'color',
|
966 |
-
'placeholder' => __('e.g.',
|
967 |
'value' => isset($param_values->IPColor) ? $param_values->IPColor : '',
|
968 |
'after' => '',
|
969 |
),
|
970 |
array(
|
971 |
-
'label' => __('Padding',
|
972 |
'name' => 'IPPadding',
|
973 |
'type' => 'text',
|
974 |
'class' => '',
|
975 |
-
'placeholder' => __('e.g.',
|
976 |
'value' => isset($param_values->IPPadding) ? $param_values->IPPadding : '',
|
977 |
'after' => '',
|
978 |
),
|
979 |
array(
|
980 |
-
'label' => __('Margin',
|
981 |
'name' => 'IPMargin',
|
982 |
'type' => 'text',
|
983 |
'class' => '',
|
984 |
-
'placeholder' => __('e.g.',
|
985 |
'value' => isset($param_values->IPMargin) ? $param_values->IPMargin : '',
|
986 |
'after' => '',
|
987 |
),
|
988 |
array(
|
989 |
-
'label' => __('Border',
|
990 |
'name' => 'IPBorder',
|
991 |
'type' => 'checkbox',
|
992 |
'options' => $borders,
|
@@ -994,16 +994,16 @@ class FMControllerThemes_fmc {
|
|
994 |
'after' => '',
|
995 |
),
|
996 |
array(
|
997 |
-
'label' => __('Border Color',
|
998 |
'name' => 'IPBorderColor',
|
999 |
'type' => 'text',
|
1000 |
'class' => 'color',
|
1001 |
-
'placeholder' => __('e.g.',
|
1002 |
'value' => isset($param_values->IPBorderColor) ? $param_values->IPBorderColor : '',
|
1003 |
'after' => '',
|
1004 |
),
|
1005 |
array(
|
1006 |
-
'label' => __('Border Type',
|
1007 |
'name' => 'IPBorderType',
|
1008 |
'type' => 'select',
|
1009 |
'options' => $border_types,
|
@@ -1012,7 +1012,7 @@ class FMControllerThemes_fmc {
|
|
1012 |
'after' => '',
|
1013 |
),
|
1014 |
array(
|
1015 |
-
'label' => __('Border Width',
|
1016 |
'name' => 'IPBorderWidth',
|
1017 |
'type' => 'text',
|
1018 |
'class' => '',
|
@@ -1020,7 +1020,7 @@ class FMControllerThemes_fmc {
|
|
1020 |
'after' => 'px',
|
1021 |
),
|
1022 |
array(
|
1023 |
-
'label' => __('Border Radius',
|
1024 |
'name' => 'IPBorderRadius',
|
1025 |
'type' => 'text',
|
1026 |
'class' => '',
|
@@ -1028,41 +1028,41 @@ class FMControllerThemes_fmc {
|
|
1028 |
'after' => 'px',
|
1029 |
),
|
1030 |
array(
|
1031 |
-
'label' => __('Box Shadow',
|
1032 |
'name' => 'IPBoxShadow',
|
1033 |
'type' => 'text',
|
1034 |
'class' => '',
|
1035 |
'value' => isset($param_values->IPBoxShadow) ? $param_values->IPBoxShadow : '',
|
1036 |
-
'placeholder' => __('e.g.',
|
1037 |
'after' => '</div>',
|
1038 |
),
|
1039 |
array(
|
1040 |
-
'label' => __('Dropdown additional',
|
1041 |
'type' => 'panel',
|
1042 |
'class' => 'col-md-12',
|
1043 |
'label_class' => 'fm-mini-title',
|
1044 |
'after' => '<br/>',
|
1045 |
),
|
1046 |
array(
|
1047 |
-
'label' => __('Appearance',
|
1048 |
'name' => 'SBPAppearance',
|
1049 |
'type' => 'text',
|
1050 |
'class' => '',
|
1051 |
-
'placeholder' => __('e.g.',
|
1052 |
'value' => isset($param_values->SBPAppearance) ? $param_values->SBPAppearance : '',
|
1053 |
'after' => '',
|
1054 |
),
|
1055 |
array(
|
1056 |
-
'label' => __('Background URL',
|
1057 |
'name' => 'SBPBackground',
|
1058 |
'type' => 'text',
|
1059 |
'class' => '',
|
1060 |
-
// 'placeholder' => __('e.g. http:// or https://',
|
1061 |
'value' => isset($param_values->SBPBackground) ? $param_values->SBPBackground : '',
|
1062 |
'after' => '',
|
1063 |
),
|
1064 |
array(
|
1065 |
-
'label' => __('Background Repeat',
|
1066 |
'name' => 'SBPBGRepeat',
|
1067 |
'type' => 'select',
|
1068 |
'options' => $bg_repeats,
|
@@ -1079,23 +1079,23 @@ class FMControllerThemes_fmc {
|
|
1079 |
),
|
1080 |
'choices' => array(
|
1081 |
array(
|
1082 |
-
'label' => __('Single Choice',
|
1083 |
'type' => 'panel',
|
1084 |
'class' => 'col-md-12',
|
1085 |
'label_class' => 'fm-mini-title',
|
1086 |
'after' => '<br/>',
|
1087 |
),
|
1088 |
array(
|
1089 |
-
'label' => __('Background Color',
|
1090 |
'name' => 'SCPBGColor',
|
1091 |
'type' => 'text',
|
1092 |
'class' => 'color',
|
1093 |
-
'placeholder' => __('e.g.',
|
1094 |
'value' => isset($param_values->SCPBGColor) ? $param_values->SCPBGColor : '',
|
1095 |
'after' => '',
|
1096 |
),
|
1097 |
array(
|
1098 |
-
'label' => __('Width',
|
1099 |
'name' => 'SCPWidth',
|
1100 |
'type' => 'text',
|
1101 |
'class' => '',
|
@@ -1103,7 +1103,7 @@ class FMControllerThemes_fmc {
|
|
1103 |
'after' => 'px',
|
1104 |
),
|
1105 |
array(
|
1106 |
-
'label' => __('Height',
|
1107 |
'name' => 'SCPHeight',
|
1108 |
'type' => 'text',
|
1109 |
'class' => '',
|
@@ -1111,16 +1111,16 @@ class FMControllerThemes_fmc {
|
|
1111 |
'after' => 'px',
|
1112 |
),
|
1113 |
array(
|
1114 |
-
'label' => __('Margin',
|
1115 |
'name' => 'SCPMargin',
|
1116 |
'type' => 'text',
|
1117 |
'class' => '5px',
|
1118 |
-
'placeholder' => __('e.g.',
|
1119 |
'value' => isset($param_values->SCPMargin) ? $param_values->SCPMargin : '',
|
1120 |
'after' => '',
|
1121 |
),
|
1122 |
array(
|
1123 |
-
'label' => __('Border',
|
1124 |
'name' => 'SCPBorder',
|
1125 |
'type' => 'checkbox',
|
1126 |
'options' => $borders,
|
@@ -1128,16 +1128,16 @@ class FMControllerThemes_fmc {
|
|
1128 |
'after' => '',
|
1129 |
),
|
1130 |
array(
|
1131 |
-
'label' => __('Border Color',
|
1132 |
'name' => 'SCPBorderColor',
|
1133 |
'type' => 'text',
|
1134 |
'class' => 'color',
|
1135 |
-
'placeholder' => __('e.g.',
|
1136 |
'value' => isset($param_values->SCPBorderColor) ? $param_values->SCPBorderColor : '',
|
1137 |
'after' => '',
|
1138 |
),
|
1139 |
array(
|
1140 |
-
'label' => __('Border Type',
|
1141 |
'name' => 'SCPBorderType',
|
1142 |
'type' => 'select',
|
1143 |
'options' => $border_types,
|
@@ -1146,7 +1146,7 @@ class FMControllerThemes_fmc {
|
|
1146 |
'after' => '',
|
1147 |
),
|
1148 |
array(
|
1149 |
-
'label' => __('Border Width',
|
1150 |
'name' => 'SCPBorderWidth',
|
1151 |
'type' => 'text',
|
1152 |
'class' => '',
|
@@ -1154,7 +1154,7 @@ class FMControllerThemes_fmc {
|
|
1154 |
'after' => 'px',
|
1155 |
),
|
1156 |
array(
|
1157 |
-
'label' => __('Border Radius',
|
1158 |
'name' => 'SCPBorderRadius',
|
1159 |
'type' => 'text',
|
1160 |
'class' => '',
|
@@ -1162,31 +1162,31 @@ class FMControllerThemes_fmc {
|
|
1162 |
'after' => 'px',
|
1163 |
),
|
1164 |
array(
|
1165 |
-
'label' => __('Box Shadow',
|
1166 |
'name' => 'SCPBoxShadow',
|
1167 |
'type' => 'text',
|
1168 |
'class' => '',
|
1169 |
-
'placeholder' => __('e.g.',
|
1170 |
'value' => isset($param_values->SCPBoxShadow) ? $param_values->SCPBoxShadow : '',
|
1171 |
'after' => '',
|
1172 |
),
|
1173 |
array(
|
1174 |
-
'label' => __('Checked Parameters',
|
1175 |
'type' => 'label',
|
1176 |
'class' => 'fm-mini-title',
|
1177 |
'after' => '<br/>',
|
1178 |
),
|
1179 |
array(
|
1180 |
-
'label' => __('Background Color',
|
1181 |
'name' => 'SCCPBGColor',
|
1182 |
'type' => 'text',
|
1183 |
'class' => 'color',
|
1184 |
-
'placeholder' => __('e.g.',
|
1185 |
'value' => isset($param_values->SCCPBGColor) ? $param_values->SCCPBGColor : '',
|
1186 |
'after' => '',
|
1187 |
),
|
1188 |
array(
|
1189 |
-
'label' => __('Width',
|
1190 |
'name' => 'SCCPWidth',
|
1191 |
'type' => 'text',
|
1192 |
'class' => '',
|
@@ -1194,7 +1194,7 @@ class FMControllerThemes_fmc {
|
|
1194 |
'after' => 'px',
|
1195 |
),
|
1196 |
array(
|
1197 |
-
'label' => __('Height',
|
1198 |
'name' => 'SCCPHeight',
|
1199 |
'type' => 'text',
|
1200 |
'class' => '',
|
@@ -1202,16 +1202,16 @@ class FMControllerThemes_fmc {
|
|
1202 |
'after' => 'px',
|
1203 |
),
|
1204 |
array(
|
1205 |
-
'label' => __('Margin',
|
1206 |
'name' => 'SCCPMargin',
|
1207 |
'type' => 'text',
|
1208 |
'class' => '',
|
1209 |
-
'placeholder' => __('e.g.',
|
1210 |
'value' => isset($param_values->SCCPMargin) ? $param_values->SCCPMargin : '',
|
1211 |
'after' => '',
|
1212 |
),
|
1213 |
array(
|
1214 |
-
'label' => __('Border Radius',
|
1215 |
'name' => 'SCCPBorderRadius',
|
1216 |
'type' => 'text',
|
1217 |
'class' => '',
|
@@ -1219,23 +1219,23 @@ class FMControllerThemes_fmc {
|
|
1219 |
'after' => 'px</div>',
|
1220 |
),
|
1221 |
array(
|
1222 |
-
'label' => __('Multiple Choice',
|
1223 |
'type' => 'panel',
|
1224 |
'class' => 'col-md-12',
|
1225 |
'label_class' => 'fm-mini-title',
|
1226 |
'after' => '<br/>',
|
1227 |
),
|
1228 |
array(
|
1229 |
-
'label' => __('Background Color',
|
1230 |
'name' => 'MCPBGColor',
|
1231 |
'type' => 'text',
|
1232 |
'class' => 'color',
|
1233 |
-
'placeholder' => __('e.g.',
|
1234 |
'value' => isset($param_values->MCPBGColor) ? $param_values->MCPBGColor : '',
|
1235 |
'after' => '',
|
1236 |
),
|
1237 |
array(
|
1238 |
-
'label' => __('Width',
|
1239 |
'name' => 'MCPWidth',
|
1240 |
'type' => 'text',
|
1241 |
'class' => '',
|
@@ -1243,7 +1243,7 @@ class FMControllerThemes_fmc {
|
|
1243 |
'after' => 'px',
|
1244 |
),
|
1245 |
array(
|
1246 |
-
'label' => __('Height',
|
1247 |
'name' => 'MCPHeight',
|
1248 |
'type' => 'text',
|
1249 |
'class' => '',
|
@@ -1251,16 +1251,16 @@ class FMControllerThemes_fmc {
|
|
1251 |
'after' => 'px',
|
1252 |
),
|
1253 |
array(
|
1254 |
-
'label' => __('Margin',
|
1255 |
'name' => 'MCPMargin',
|
1256 |
'type' => 'text',
|
1257 |
'class' => '5px',
|
1258 |
-
'placeholder' => __('e.g.',
|
1259 |
'value' => isset($param_values->MCPMargin) ? $param_values->MCPMargin : '',
|
1260 |
'after' => '',
|
1261 |
),
|
1262 |
array(
|
1263 |
-
'label' => __('Border',
|
1264 |
'name' => 'MCPBorder',
|
1265 |
'type' => 'checkbox',
|
1266 |
'options' => $borders,
|
@@ -1268,16 +1268,16 @@ class FMControllerThemes_fmc {
|
|
1268 |
'after' => '',
|
1269 |
),
|
1270 |
array(
|
1271 |
-
'label' => __('Border Color',
|
1272 |
'name' => 'MCPBorderColor',
|
1273 |
'type' => 'text',
|
1274 |
'class' => 'color',
|
1275 |
-
'placeholder' => __('e.g.',
|
1276 |
'value' => isset($param_values->MCPBorderColor) ? $param_values->MCPBorderColor : '',
|
1277 |
'after' => '',
|
1278 |
),
|
1279 |
array(
|
1280 |
-
'label' => __('Border Type',
|
1281 |
'name' => 'MCPBorderType',
|
1282 |
'type' => 'select',
|
1283 |
'options' => $border_types,
|
@@ -1286,7 +1286,7 @@ class FMControllerThemes_fmc {
|
|
1286 |
'after' => '',
|
1287 |
),
|
1288 |
array(
|
1289 |
-
'label' => __('Border Width',
|
1290 |
'name' => 'MCPBorderWidth',
|
1291 |
'type' => 'text',
|
1292 |
'class' => '',
|
@@ -1295,7 +1295,7 @@ class FMControllerThemes_fmc {
|
|
1295 |
),
|
1296 |
|
1297 |
array(
|
1298 |
-
'label' => __('Border Radius',
|
1299 |
'name' => 'MCPBorderRadius',
|
1300 |
'type' => 'text',
|
1301 |
'class' => '',
|
@@ -1303,40 +1303,40 @@ class FMControllerThemes_fmc {
|
|
1303 |
'after' => 'px',
|
1304 |
),
|
1305 |
array(
|
1306 |
-
'label' => __('Box Shadow',
|
1307 |
'name' => 'MCPBoxShadow',
|
1308 |
'type' => 'text',
|
1309 |
'class' => '',
|
1310 |
-
'placeholder' => __('e.g.',
|
1311 |
'value' => isset($param_values->MCPBoxShadow) ? $param_values->MCPBoxShadow : '',
|
1312 |
'after' => '',
|
1313 |
),
|
1314 |
array(
|
1315 |
-
'label' => __('Checked Parameters',
|
1316 |
'type' => 'label',
|
1317 |
'class' => 'fm-mini-title',
|
1318 |
'after' => '<br/>',
|
1319 |
),
|
1320 |
array(
|
1321 |
-
'label' => __('Background Color',
|
1322 |
'name' => 'MCCPBGColor',
|
1323 |
'type' => 'text',
|
1324 |
'class' => 'color',
|
1325 |
-
'placeholder' => __('e.g.',
|
1326 |
'value' => isset($param_values->MCCPBGColor) ? $param_values->MCCPBGColor : '',
|
1327 |
'after' => '',
|
1328 |
),
|
1329 |
array(
|
1330 |
-
'label' => __('Background URL',
|
1331 |
'name' => 'MCCPBackground',
|
1332 |
'type' => 'text',
|
1333 |
'class' => '',
|
1334 |
-
// 'placeholder' => __('e.g. http:// or https://',
|
1335 |
'value' => isset($param_values->MCCPBackground) ? $param_values->MCCPBackground : '',
|
1336 |
'after' => '',
|
1337 |
),
|
1338 |
array(
|
1339 |
-
'label' => __('Background Repeat',
|
1340 |
'name' => 'MCCPBGRepeat',
|
1341 |
'type' => 'select',
|
1342 |
'options' => $bg_repeats,
|
@@ -1345,12 +1345,12 @@ class FMControllerThemes_fmc {
|
|
1345 |
'after' => '',
|
1346 |
),
|
1347 |
array(
|
1348 |
-
'label' => __('Background Position',
|
1349 |
'name1' => 'MCCPBGPos1',
|
1350 |
'name2' => 'MCCPBGPos2',
|
1351 |
'type' => '2text',
|
1352 |
'class' => 'fm-2text',
|
1353 |
-
'placeholder' => __('e.g.',
|
1354 |
'value1' => isset($param_values->MCCPBGPos1) ? $param_values->MCCPBGPos1 : '',
|
1355 |
'value2' => isset($param_values->MCCPBGPos2) ? $param_values->MCCPBGPos2 : '',
|
1356 |
'before1' => '',
|
@@ -1358,7 +1358,7 @@ class FMControllerThemes_fmc {
|
|
1358 |
'after' => '',
|
1359 |
),
|
1360 |
array(
|
1361 |
-
'label' => __('Width',
|
1362 |
'name' => 'MCCPWidth',
|
1363 |
'type' => 'text',
|
1364 |
'class' => '',
|
@@ -1366,7 +1366,7 @@ class FMControllerThemes_fmc {
|
|
1366 |
'after' => 'px',
|
1367 |
),
|
1368 |
array(
|
1369 |
-
'label' => __('Height',
|
1370 |
'name' => 'MCCPHeight',
|
1371 |
'type' => 'text',
|
1372 |
'class' => '',
|
@@ -1374,16 +1374,16 @@ class FMControllerThemes_fmc {
|
|
1374 |
'after' => 'px',
|
1375 |
),
|
1376 |
array(
|
1377 |
-
'label' => __('Margin',
|
1378 |
'name' => 'MCCPMargin',
|
1379 |
'type' => 'text',
|
1380 |
'class' => '',
|
1381 |
-
'placeholder' => __('e.g.',
|
1382 |
'value' => isset($param_values->MCCPMargin) ? $param_values->MCCPMargin : '',
|
1383 |
'after' => '',
|
1384 |
),
|
1385 |
array(
|
1386 |
-
'label' => __('Border Radius',
|
1387 |
'name' => 'MCCPBorderRadius',
|
1388 |
'type' => 'text',
|
1389 |
'class' => '',
|
@@ -1393,14 +1393,14 @@ class FMControllerThemes_fmc {
|
|
1393 |
),
|
1394 |
'subscribe' => array(
|
1395 |
array(
|
1396 |
-
'label' => __('Global Parameters',
|
1397 |
'type' => 'panel',
|
1398 |
'class' => 'col-md-12',
|
1399 |
'label_class' => 'fm-mini-title',
|
1400 |
'after' => '<br/>',
|
1401 |
),
|
1402 |
array(
|
1403 |
-
'label' => __('Alignment',
|
1404 |
'name' => 'SPAlign',
|
1405 |
'type' => 'select',
|
1406 |
'options' => $aligns,
|
@@ -1409,23 +1409,23 @@ class FMControllerThemes_fmc {
|
|
1409 |
'after' => '</div>',
|
1410 |
),
|
1411 |
array(
|
1412 |
-
'label' => __('Submit',
|
1413 |
'type' => 'panel',
|
1414 |
'class' => 'col-md-12',
|
1415 |
'label_class' => 'fm-mini-title',
|
1416 |
'after' => '<br/>',
|
1417 |
),
|
1418 |
array(
|
1419 |
-
'label' => __('Background Color',
|
1420 |
'name' => 'SPBGColor',
|
1421 |
'type' => 'text',
|
1422 |
'class' => 'color',
|
1423 |
-
'placeholder' => __('e.g.',
|
1424 |
'value' => isset($param_values->SPBGColor) ? $param_values->SPBGColor : '',
|
1425 |
'after' => '',
|
1426 |
),
|
1427 |
array(
|
1428 |
-
'label' => __('Width',
|
1429 |
'name' => 'SPWidth',
|
1430 |
'type' => 'text',
|
1431 |
'class' => '',
|
@@ -1433,7 +1433,7 @@ class FMControllerThemes_fmc {
|
|
1433 |
'after' => 'px',
|
1434 |
),
|
1435 |
array(
|
1436 |
-
'label' => __('Height',
|
1437 |
'name' => 'SPHeight',
|
1438 |
'type' => 'text',
|
1439 |
'class' => '',
|
@@ -1441,7 +1441,7 @@ class FMControllerThemes_fmc {
|
|
1441 |
'after' => 'px',
|
1442 |
),
|
1443 |
array(
|
1444 |
-
'label' => __('Font Size',
|
1445 |
'name' => 'SPFontSize',
|
1446 |
'type' => 'text',
|
1447 |
'class' => '',
|
@@ -1449,7 +1449,7 @@ class FMControllerThemes_fmc {
|
|
1449 |
'after' => 'px',
|
1450 |
),
|
1451 |
array(
|
1452 |
-
'label' => __('Font Weight',
|
1453 |
'name' => 'SPFontWeight',
|
1454 |
'type' => 'select',
|
1455 |
'options' => $font_weights,
|
@@ -1458,34 +1458,34 @@ class FMControllerThemes_fmc {
|
|
1458 |
'after' => '',
|
1459 |
),
|
1460 |
array(
|
1461 |
-
'label' => __('Color',
|
1462 |
'name' => 'SPColor',
|
1463 |
'type' => 'text',
|
1464 |
'class' => 'color',
|
1465 |
-
'placeholder' => __('e.g.',
|
1466 |
'value' => isset($param_values->SPColor) ? $param_values->SPColor : '',
|
1467 |
'after' => '',
|
1468 |
),
|
1469 |
array(
|
1470 |
-
'label' => __('Padding',
|
1471 |
'name' => 'SPPadding',
|
1472 |
'type' => 'text',
|
1473 |
'class' => '',
|
1474 |
-
'placeholder' => __('e.g.',
|
1475 |
'value' => isset($param_values->SPPadding) ? $param_values->SPPadding : '',
|
1476 |
'after' => '',
|
1477 |
),
|
1478 |
array(
|
1479 |
-
'label' => __('Margin',
|
1480 |
'name' => 'SPMargin',
|
1481 |
'type' => 'text',
|
1482 |
'class' => '',
|
1483 |
-
'placeholder' => __('e.g.',
|
1484 |
'value' => isset($param_values->SPMargin) ? $param_values->SPMargin : '',
|
1485 |
'after' => '',
|
1486 |
),
|
1487 |
array(
|
1488 |
-
'label' => __('Border',
|
1489 |
'name' => 'SPBorder',
|
1490 |
'type' => 'checkbox',
|
1491 |
'options' => $borders,
|
@@ -1493,16 +1493,16 @@ class FMControllerThemes_fmc {
|
|
1493 |
'after' => '',
|
1494 |
),
|
1495 |
array(
|
1496 |
-
'label' => __('Border Color',
|
1497 |
'name' => 'SPBorderColor',
|
1498 |
'type' => 'text',
|
1499 |
'class' => 'color',
|
1500 |
-
'placeholder' => __('e.g.',
|
1501 |
'value' => isset($param_values->SPBorderColor) ? $param_values->SPBorderColor : '',
|
1502 |
'after' => '',
|
1503 |
),
|
1504 |
array(
|
1505 |
-
'label' => __('Border Type',
|
1506 |
'name' => 'SPBorderType',
|
1507 |
'type' => 'select',
|
1508 |
'options' => $border_types,
|
@@ -1511,7 +1511,7 @@ class FMControllerThemes_fmc {
|
|
1511 |
'after' => '',
|
1512 |
),
|
1513 |
array(
|
1514 |
-
'label' => __('Border Width',
|
1515 |
'name' => 'SPBorderWidth',
|
1516 |
'type' => 'text',
|
1517 |
'class' => '',
|
@@ -1519,7 +1519,7 @@ class FMControllerThemes_fmc {
|
|
1519 |
'after' => 'px',
|
1520 |
),
|
1521 |
array(
|
1522 |
-
'label' => __('Border Radius',
|
1523 |
'name' => 'SPBorderRadius',
|
1524 |
'type' => 'text',
|
1525 |
'class' => '',
|
@@ -1527,40 +1527,40 @@ class FMControllerThemes_fmc {
|
|
1527 |
'after' => 'px',
|
1528 |
),
|
1529 |
array(
|
1530 |
-
'label' => __('Box Shadow',
|
1531 |
'name' => 'SPBoxShadow',
|
1532 |
'type' => 'text',
|
1533 |
'class' => '',
|
1534 |
-
'placeholder' => __('e.g.',
|
1535 |
'value' => isset($param_values->SPBoxShadow) ? $param_values->SPBoxShadow : '',
|
1536 |
'after' => '',
|
1537 |
),
|
1538 |
array(
|
1539 |
-
'label' => __('Hover Parameters',
|
1540 |
'type' => 'label',
|
1541 |
'class' => 'fm-mini-title',
|
1542 |
'after' => '<br/>',
|
1543 |
),
|
1544 |
array(
|
1545 |
-
'label' => __('Background Color',
|
1546 |
'name' => 'SHPBGColor',
|
1547 |
'type' => 'text',
|
1548 |
'class' => 'color',
|
1549 |
-
'placeholder' => __('e.g.',
|
1550 |
'value' => isset($param_values->SHPBGColor) ? $param_values->SHPBGColor : '',
|
1551 |
'after' => '',
|
1552 |
),
|
1553 |
array(
|
1554 |
-
'label' => __('Color',
|
1555 |
'name' => 'SHPColor',
|
1556 |
'type' => 'text',
|
1557 |
'class' => 'color',
|
1558 |
-
'placeholder' => __('e.g.',
|
1559 |
'value' => isset($param_values->SHPColor) ? $param_values->SHPColor : '',
|
1560 |
'after' => '',
|
1561 |
),
|
1562 |
array(
|
1563 |
-
'label' => __('Border',
|
1564 |
'name' => 'SHPBorder',
|
1565 |
'type' => 'checkbox',
|
1566 |
'options' => $borders,
|
@@ -1568,16 +1568,16 @@ class FMControllerThemes_fmc {
|
|
1568 |
'after' => '',
|
1569 |
),
|
1570 |
array(
|
1571 |
-
'label' => __('Border Color',
|
1572 |
'name' => 'SHPBorderColor',
|
1573 |
'type' => 'text',
|
1574 |
'class' => 'color',
|
1575 |
-
'placeholder' => __('e.g.',
|
1576 |
'value' => isset($param_values->SHPBorderColor) ? $param_values->SHPBorderColor : '',
|
1577 |
'after' => '',
|
1578 |
),
|
1579 |
array(
|
1580 |
-
'label' => __('Border Type',
|
1581 |
'name' => 'SHPBorderType',
|
1582 |
'type' => 'select',
|
1583 |
'options' => $border_types,
|
@@ -1586,7 +1586,7 @@ class FMControllerThemes_fmc {
|
|
1586 |
'after' => '',
|
1587 |
),
|
1588 |
array(
|
1589 |
-
'label' => __('Border Width',
|
1590 |
'name' => 'SHPBorderWidth',
|
1591 |
'type' => 'text',
|
1592 |
'class' => '',
|
@@ -1594,23 +1594,23 @@ class FMControllerThemes_fmc {
|
|
1594 |
'after' => 'px</div>',
|
1595 |
),
|
1596 |
array(
|
1597 |
-
'label' => __('Reset',
|
1598 |
'type' => 'panel',
|
1599 |
'class' => 'col-md-12',
|
1600 |
'label_class' => 'fm-mini-title',
|
1601 |
'after' => '<br/>',
|
1602 |
),
|
1603 |
array(
|
1604 |
-
'label' => __('Background Color',
|
1605 |
'name' => 'BPBGColor',
|
1606 |
'type' => 'text',
|
1607 |
'class' => 'color',
|
1608 |
-
'placeholder' => __('e.g.',
|
1609 |
'value' => isset($param_values->BPBGColor) ? $param_values->BPBGColor : '',
|
1610 |
'after' => '',
|
1611 |
),
|
1612 |
array(
|
1613 |
-
'label' => __('Width',
|
1614 |
'name' => 'BPWidth',
|
1615 |
'type' => 'text',
|
1616 |
'class' => '',
|
@@ -1618,7 +1618,7 @@ class FMControllerThemes_fmc {
|
|
1618 |
'after' => 'px',
|
1619 |
),
|
1620 |
array(
|
1621 |
-
'label' => __('Height',
|
1622 |
'name' => 'BPHeight',
|
1623 |
'type' => 'text',
|
1624 |
'class' => '',
|
@@ -1626,7 +1626,7 @@ class FMControllerThemes_fmc {
|
|
1626 |
'after' => 'px',
|
1627 |
),
|
1628 |
array(
|
1629 |
-
'label' => __('Font Size',
|
1630 |
'name' => 'BPFontSize',
|
1631 |
'type' => 'text',
|
1632 |
'class' => '',
|
@@ -1634,7 +1634,7 @@ class FMControllerThemes_fmc {
|
|
1634 |
'after' => 'px',
|
1635 |
),
|
1636 |
array(
|
1637 |
-
'label' => __('Font Weight',
|
1638 |
'name' => 'BPFontWeight',
|
1639 |
'type' => 'select',
|
1640 |
'options' => $font_weights,
|
@@ -1643,34 +1643,34 @@ class FMControllerThemes_fmc {
|
|
1643 |
'after' => '',
|
1644 |
),
|
1645 |
array(
|
1646 |
-
'label' => __('Color',
|
1647 |
'name' => 'BPColor',
|
1648 |
'type' => 'text',
|
1649 |
'class' => 'color',
|
1650 |
-
'placeholder' => __('e.g.',
|
1651 |
'value' => isset($param_values->BPColor) ? $param_values->BPColor : '',
|
1652 |
'after' => '',
|
1653 |
),
|
1654 |
array(
|
1655 |
-
'label' => __('Padding',
|
1656 |
'name' => 'BPPadding',
|
1657 |
'type' => 'text',
|
1658 |
'class' => '',
|
1659 |
-
'placeholder' => __('e.g.',
|
1660 |
'value' => isset($param_values->BPPadding) ? $param_values->BPPadding : '',
|
1661 |
'after' => '',
|
1662 |
),
|
1663 |
array(
|
1664 |
-
'label' => __('Margin',
|
1665 |
'name' => 'BPMargin',
|
1666 |
'type' => 'text',
|
1667 |
'class' => '',
|
1668 |
-
'placeholder' => __('e.g.',
|
1669 |
'value' => isset($param_values->BPMargin) ? $param_values->BPMargin : '',
|
1670 |
'after' => '',
|
1671 |
),
|
1672 |
array(
|
1673 |
-
'label' => __('Border',
|
1674 |
'name' => 'BPBorder',
|
1675 |
'type' => 'checkbox',
|
1676 |
'options' => $borders,
|
@@ -1678,16 +1678,16 @@ class FMControllerThemes_fmc {
|
|
1678 |
'after' => '',
|
1679 |
),
|
1680 |
array(
|
1681 |
-
'label' => __('Border Color',
|
1682 |
'name' => 'BPBorderColor',
|
1683 |
'type' => 'text',
|
1684 |
'class' => 'color',
|
1685 |
-
'placeholder' => __('e.g.',
|
1686 |
'value' => isset($param_values->BPBorderColor) ? $param_values->BPBorderColor : '',
|
1687 |
'after' => '',
|
1688 |
),
|
1689 |
array(
|
1690 |
-
'label' => __('Border Type',
|
1691 |
'name' => 'BPBorderType',
|
1692 |
'type' => 'select',
|
1693 |
'options' => $border_types,
|
@@ -1696,7 +1696,7 @@ class FMControllerThemes_fmc {
|
|
1696 |
'after' => '',
|
1697 |
),
|
1698 |
array(
|
1699 |
-
'label' => __('Border Width',
|
1700 |
'name' => 'BPBorderWidth',
|
1701 |
'type' => 'text',
|
1702 |
'class' => '',
|
@@ -1704,7 +1704,7 @@ class FMControllerThemes_fmc {
|
|
1704 |
'after' => 'px',
|
1705 |
),
|
1706 |
array(
|
1707 |
-
'label' => __('Border Radius',
|
1708 |
'name' => 'BPBorderRadius',
|
1709 |
'type' => 'text',
|
1710 |
'class' => '',
|
@@ -1712,40 +1712,40 @@ class FMControllerThemes_fmc {
|
|
1712 |
'after' => 'px',
|
1713 |
),
|
1714 |
array(
|
1715 |
-
'label' => __('Box Shadow',
|
1716 |
'name' => 'BPBoxShadow',
|
1717 |
'type' => 'text',
|
1718 |
'class' => '',
|
1719 |
-
'placeholder' => __('e.g.',
|
1720 |
'value' => isset($param_values->BPBoxShadow) ? $param_values->BPBoxShadow : '',
|
1721 |
'after' => '',
|
1722 |
),
|
1723 |
array(
|
1724 |
-
'label' => __('Hover Parameters',
|
1725 |
'type' => 'label',
|
1726 |
'class' => 'fm-mini-title',
|
1727 |
'after' => '<br/>',
|
1728 |
),
|
1729 |
array(
|
1730 |
-
'label' => __('Background Color',
|
1731 |
'name' => 'BHPBGColor',
|
1732 |
'type' => 'text',
|
1733 |
'class' => 'color',
|
1734 |
-
'placeholder' => __('e.g.',
|
1735 |
'value' => isset($param_values->BHPBGColor) ? $param_values->BHPBGColor : '',
|
1736 |
'after' => '',
|
1737 |
),
|
1738 |
array(
|
1739 |
-
'label' => __('Color',
|
1740 |
'name' => 'BHPColor',
|
1741 |
'type' => 'text',
|
1742 |
'class' => 'color',
|
1743 |
-
'placeholder' => __('e.g.',
|
1744 |
'value' => isset($param_values->BHPColor) ? $param_values->BHPColor : '',
|
1745 |
'after' => '',
|
1746 |
),
|
1747 |
array(
|
1748 |
-
'label' => __('Border',
|
1749 |
'name' => 'BHPBorder',
|
1750 |
'type' => 'checkbox',
|
1751 |
'options' => $borders,
|
@@ -1753,16 +1753,16 @@ class FMControllerThemes_fmc {
|
|
1753 |
'after' => '',
|
1754 |
),
|
1755 |
array(
|
1756 |
-
'label' => __('Border Color',
|
1757 |
'name' => 'BHPBorderColor',
|
1758 |
'type' => 'text',
|
1759 |
'class' => 'color',
|
1760 |
-
'placeholder' => __('e.g.',
|
1761 |
'value' => isset($param_values->BHPBorderColor) ? $param_values->BHPBorderColor : '',
|
1762 |
'after' => '',
|
1763 |
),
|
1764 |
array(
|
1765 |
-
'label' => __('Border Type',
|
1766 |
'name' => 'BHPBorderType',
|
1767 |
'type' => 'select',
|
1768 |
'options' => $border_types,
|
@@ -1771,7 +1771,7 @@ class FMControllerThemes_fmc {
|
|
1771 |
'after' => '',
|
1772 |
),
|
1773 |
array(
|
1774 |
-
'label' => __('Border Width',
|
1775 |
'name' => 'BHPBorderWidth',
|
1776 |
'type' => 'text',
|
1777 |
'class' => '',
|
@@ -1781,23 +1781,23 @@ class FMControllerThemes_fmc {
|
|
1781 |
),
|
1782 |
'paigination' => array(
|
1783 |
array(
|
1784 |
-
'label' => __('Active',
|
1785 |
'type' => 'panel',
|
1786 |
'class' => 'col-md-12',
|
1787 |
'label_class' => 'fm-mini-title',
|
1788 |
'after' => '',
|
1789 |
),
|
1790 |
array(
|
1791 |
-
'label' => __('Background Color',
|
1792 |
'name' => 'PSAPBGColor',
|
1793 |
'type' => 'text',
|
1794 |
'class' => 'color',
|
1795 |
-
'placeholder' => __('e.g.',
|
1796 |
'value' => isset($param_values->PSAPBGColor) ? $param_values->PSAPBGColor : '',
|
1797 |
'after' => '',
|
1798 |
),
|
1799 |
array(
|
1800 |
-
'label' => __('Font Size',
|
1801 |
'name' => 'PSAPFontSize',
|
1802 |
'type' => 'text',
|
1803 |
'class' => '',
|
@@ -1805,7 +1805,7 @@ class FMControllerThemes_fmc {
|
|
1805 |
'after' => 'px',
|
1806 |
),
|
1807 |
array(
|
1808 |
-
'label' => __('Font Weight',
|
1809 |
'name' => 'PSAPFontWeight',
|
1810 |
'type' => 'select',
|
1811 |
'options' => $font_weights,
|
@@ -1814,16 +1814,16 @@ class FMControllerThemes_fmc {
|
|
1814 |
'after' => '',
|
1815 |
),
|
1816 |
array(
|
1817 |
-
'label' => __('Color',
|
1818 |
'name' => 'PSAPColor',
|
1819 |
'type' => 'text',
|
1820 |
'class' => 'color',
|
1821 |
-
'placeholder' => __('e.g.',
|
1822 |
'value' => isset($param_values->PSAPColor) ? $param_values->PSAPColor : '',
|
1823 |
'after' => '',
|
1824 |
),
|
1825 |
array(
|
1826 |
-
'label' => __('Height',
|
1827 |
'name' => 'PSAPHeight',
|
1828 |
'type' => 'text',
|
1829 |
'class' => '',
|
@@ -1831,7 +1831,7 @@ class FMControllerThemes_fmc {
|
|
1831 |
'after' => 'px',
|
1832 |
),
|
1833 |
array(
|
1834 |
-
'label' => __('Line Height',
|
1835 |
'name' => 'PSAPLineHeight',
|
1836 |
'type' => 'text',
|
1837 |
'class' => '',
|
@@ -1839,25 +1839,25 @@ class FMControllerThemes_fmc {
|
|
1839 |
'after' => 'px',
|
1840 |
),
|
1841 |
array(
|
1842 |
-
'label' => __('Padding',
|
1843 |
'name' => 'PSAPPadding',
|
1844 |
'type' => 'text',
|
1845 |
'class' => '',
|
1846 |
-
'placeholder' => __('e.g.',
|
1847 |
'value' => isset($param_values->PSAPPadding) ? $param_values->PSAPPadding : '',
|
1848 |
'after' => '',
|
1849 |
),
|
1850 |
array(
|
1851 |
-
'label' => __('Margin',
|
1852 |
'name' => 'PSAPMargin',
|
1853 |
'type' => 'text',
|
1854 |
'class' => '',
|
1855 |
-
'placeholder' => __('e.g.',
|
1856 |
'value' => isset($param_values->PSAPMargin) ? $param_values->PSAPMargin : '',
|
1857 |
'after' => '',
|
1858 |
),
|
1859 |
array(
|
1860 |
-
'label' => __('Border',
|
1861 |
'name' => 'PSAPBorder',
|
1862 |
'type' => 'checkbox',
|
1863 |
'options' => $borders,
|
@@ -1865,16 +1865,16 @@ class FMControllerThemes_fmc {
|
|
1865 |
'after' => '',
|
1866 |
),
|
1867 |
array(
|
1868 |
-
'label' => __('Border Color',
|
1869 |
'name' => 'PSAPBorderColor',
|
1870 |
'type' => 'text',
|
1871 |
'class' => 'color',
|
1872 |
-
'placeholder' => __('e.g.',
|
1873 |
'value' => isset($param_values->PSAPBorderColor) ? $param_values->PSAPBorderColor : '',
|
1874 |
'after' => '',
|
1875 |
),
|
1876 |
array(
|
1877 |
-
'label' => __('Border Type',
|
1878 |
'name' => 'PSAPBorderType',
|
1879 |
'type' => 'select',
|
1880 |
'options' => $border_types,
|
@@ -1883,7 +1883,7 @@ class FMControllerThemes_fmc {
|
|
1883 |
'after' => '',
|
1884 |
),
|
1885 |
array(
|
1886 |
-
'label' => __('Border Width',
|
1887 |
'name' => 'PSAPBorderWidth',
|
1888 |
'type' => 'text',
|
1889 |
'class' => '',
|
@@ -1891,7 +1891,7 @@ class FMControllerThemes_fmc {
|
|
1891 |
'after' => 'px',
|
1892 |
),
|
1893 |
array(
|
1894 |
-
'label' => __('Border Radius',
|
1895 |
'name' => 'PSAPBorderRadius',
|
1896 |
'type' => 'text',
|
1897 |
'class' => '',
|
@@ -1899,23 +1899,23 @@ class FMControllerThemes_fmc {
|
|
1899 |
'after' => 'px</div>',
|
1900 |
),
|
1901 |
array(
|
1902 |
-
'label' => __('Inactive',
|
1903 |
'type' => 'panel',
|
1904 |
'class' => 'col-md-12',
|
1905 |
'label_class' => 'fm-mini-title',
|
1906 |
'after' => '',
|
1907 |
),
|
1908 |
array(
|
1909 |
-
'label' => __('Background Color',
|
1910 |
'name' => 'PSDPBGColor',
|
1911 |
'type' => 'text',
|
1912 |
'class' => 'color',
|
1913 |
-
'placeholder' => __('e.g.',
|
1914 |
'value' => isset($param_values->PSDPBGColor) ? $param_values->PSDPBGColor : '',
|
1915 |
'after' => '',
|
1916 |
),
|
1917 |
array(
|
1918 |
-
'label' => __('Font Size',
|
1919 |
'name' => 'PSDPFontSize',
|
1920 |
'type' => 'text',
|
1921 |
'class' => '',
|
@@ -1923,7 +1923,7 @@ class FMControllerThemes_fmc {
|
|
1923 |
'after' => 'px',
|
1924 |
),
|
1925 |
array(
|
1926 |
-
'label' => __('Font Weight',
|
1927 |
'name' => 'PSDPFontWeight',
|
1928 |
'type' => 'select',
|
1929 |
'options' => $font_weights,
|
@@ -1932,16 +1932,16 @@ class FMControllerThemes_fmc {
|
|
1932 |
'after' => '',
|
1933 |
),
|
1934 |
array(
|
1935 |
-
'label' => __('Color',
|
1936 |
'name' => 'PSDPColor',
|
1937 |
'type' => 'text',
|
1938 |
'class' => 'color',
|
1939 |
-
'placeholder' => __('e.g.',
|
1940 |
'value' => isset($param_values->PSDPColor) ? $param_values->PSDPColor : '',
|
1941 |
'after' => '',
|
1942 |
),
|
1943 |
array(
|
1944 |
-
'label' => __('Height',
|
1945 |
'name' => 'PSDPHeight',
|
1946 |
'type' => 'text',
|
1947 |
'class' => '',
|
@@ -1949,7 +1949,7 @@ class FMControllerThemes_fmc {
|
|
1949 |
'after' => 'px',
|
1950 |
),
|
1951 |
array(
|
1952 |
-
'label' => __('Line Height',
|
1953 |
'name' => 'PSDPLineHeight',
|
1954 |
'type' => 'text',
|
1955 |
'class' => '',
|
@@ -1957,25 +1957,25 @@ class FMControllerThemes_fmc {
|
|
1957 |
'after' => 'px',
|
1958 |
),
|
1959 |
array(
|
1960 |
-
'label' => __('Padding',
|
1961 |
'name' => 'PSDPPadding',
|
1962 |
'type' => 'text',
|
1963 |
'class' => '',
|
1964 |
-
'placeholder' => __('e.g.',
|
1965 |
'value' => isset($param_values->PSDPPadding) ? $param_values->PSDPPadding : '',
|
1966 |
'after' => '',
|
1967 |
),
|
1968 |
array(
|
1969 |
-
'label' => __('Margin',
|
1970 |
'name' => 'PSDPMargin',
|
1971 |
'type' => 'text',
|
1972 |
'class' => '',
|
1973 |
-
'placeholder' => __('e.g.',
|
1974 |
'value' => isset($param_values->PSDPMargin) ? $param_values->PSDPMargin : '',
|
1975 |
'after' => '',
|
1976 |
),
|
1977 |
array(
|
1978 |
-
'label' => __('Border',
|
1979 |
'name' => 'PSDPBorder',
|
1980 |
'type' => 'checkbox',
|
1981 |
'options' => $borders,
|
@@ -1983,16 +1983,16 @@ class FMControllerThemes_fmc {
|
|
1983 |
'after' => '',
|
1984 |
),
|
1985 |
array(
|
1986 |
-
'label' => __('Border Color',
|
1987 |
'name' => 'PSDPBorderColor',
|
1988 |
'type' => 'text',
|
1989 |
'class' => 'color',
|
1990 |
-
'placeholder' => __('e.g.',
|
1991 |
'value' => isset($param_values->PSDPBorderColor) ? $param_values->PSDPBorderColor : '',
|
1992 |
'after' => '',
|
1993 |
),
|
1994 |
array(
|
1995 |
-
'label' => __('Border Type',
|
1996 |
'name' => 'PSDPBorderType',
|
1997 |
'type' => 'select',
|
1998 |
'options' => $border_types,
|
@@ -2001,7 +2001,7 @@ class FMControllerThemes_fmc {
|
|
2001 |
'after' => '',
|
2002 |
),
|
2003 |
array(
|
2004 |
-
'label' => __('Border Width',
|
2005 |
'name' => 'PSDPBorderWidth',
|
2006 |
'type' => 'text',
|
2007 |
'class' => '',
|
@@ -2009,7 +2009,7 @@ class FMControllerThemes_fmc {
|
|
2009 |
'after' => 'px',
|
2010 |
),
|
2011 |
array(
|
2012 |
-
'label' => __('Border Radius',
|
2013 |
'name' => 'PSDPBorderRadius',
|
2014 |
'type' => 'text',
|
2015 |
'class' => '',
|
@@ -2017,14 +2017,14 @@ class FMControllerThemes_fmc {
|
|
2017 |
'after' => 'px</div>',
|
2018 |
),
|
2019 |
array(
|
2020 |
-
'label' => __('Steps',
|
2021 |
'type' => 'panel',
|
2022 |
'class' => 'col-md-12',
|
2023 |
'label_class' => 'fm-mini-title',
|
2024 |
'after' => '',
|
2025 |
),
|
2026 |
array(
|
2027 |
-
'label' => __('Alignment',
|
2028 |
'name' => 'PSAPAlign',
|
2029 |
'type' => 'select',
|
2030 |
'options' => $aligns,
|
@@ -2033,7 +2033,7 @@ class FMControllerThemes_fmc {
|
|
2033 |
'after' => '',
|
2034 |
),
|
2035 |
array(
|
2036 |
-
'label' => __('Width',
|
2037 |
'name' => 'PSAPWidth',
|
2038 |
'type' => 'text',
|
2039 |
'class' => '',
|
@@ -2041,32 +2041,32 @@ class FMControllerThemes_fmc {
|
|
2041 |
'after' => 'px</div>',
|
2042 |
),
|
2043 |
array(
|
2044 |
-
'label' => __('Percentage',
|
2045 |
'type' => 'panel',
|
2046 |
'class' => 'col-md-12',
|
2047 |
'label_class' => 'fm-mini-title',
|
2048 |
'after' => '',
|
2049 |
),
|
2050 |
array(
|
2051 |
-
'label' => __('Width',
|
2052 |
'name' => 'PPAPWidth',
|
2053 |
'type' => 'text',
|
2054 |
'class' => '',
|
2055 |
-
'placeholder' => __('e.g.',
|
2056 |
'value' => isset($param_values->PPAPWidth) ? $param_values->PPAPWidth : '',
|
2057 |
'after' => '</div>',
|
2058 |
),
|
2059 |
),
|
2060 |
'buttons' => array(
|
2061 |
array(
|
2062 |
-
'label' => __('Global Parameters',
|
2063 |
'type' => 'panel',
|
2064 |
'class' => 'col-md-12',
|
2065 |
'label_class' => 'fm-mini-title',
|
2066 |
'after' => '<br/>',
|
2067 |
),
|
2068 |
array(
|
2069 |
-
'label' => __('Font Size',
|
2070 |
'name' => 'BPFontSize',
|
2071 |
'type' => 'text',
|
2072 |
'class' => '',
|
@@ -2074,7 +2074,7 @@ class FMControllerThemes_fmc {
|
|
2074 |
'after' => 'px',
|
2075 |
),
|
2076 |
array(
|
2077 |
-
'label' => __('Font Weight',
|
2078 |
'name' => 'BPFontWeight',
|
2079 |
'type' => 'select',
|
2080 |
'options' => $font_weights,
|
@@ -2083,23 +2083,23 @@ class FMControllerThemes_fmc {
|
|
2083 |
'after' => '</div>',
|
2084 |
),
|
2085 |
array(
|
2086 |
-
'label' => __('Next Button Parameters',
|
2087 |
'type' => 'panel',
|
2088 |
'class' => 'col-md-12',
|
2089 |
'label_class' => 'fm-mini-title',
|
2090 |
'after' => '<br/>',
|
2091 |
),
|
2092 |
array(
|
2093 |
-
'label' => __('Background Color',
|
2094 |
'name' => 'NBPBGColor',
|
2095 |
'type' => 'text',
|
2096 |
'class' => 'color',
|
2097 |
-
'placeholder' => __('e.g.',
|
2098 |
'value' => isset($param_values->NBPBGColor) ? $param_values->NBPBGColor : '',
|
2099 |
'after' => '',
|
2100 |
),
|
2101 |
array(
|
2102 |
-
'label' => __('Width',
|
2103 |
'name' => 'NBPWidth',
|
2104 |
'type' => 'text',
|
2105 |
'class' => '',
|
@@ -2107,7 +2107,7 @@ class FMControllerThemes_fmc {
|
|
2107 |
'after' => 'px',
|
2108 |
),
|
2109 |
array(
|
2110 |
-
'label' => __('Height',
|
2111 |
'name' => 'NBPHeight',
|
2112 |
'type' => 'text',
|
2113 |
'class' => '',
|
@@ -2115,7 +2115,7 @@ class FMControllerThemes_fmc {
|
|
2115 |
'after' => 'px',
|
2116 |
),
|
2117 |
array(
|
2118 |
-
'label' => __('Line Height',
|
2119 |
'name' => 'NBPLineHeight',
|
2120 |
'type' => 'text',
|
2121 |
'class' => '',
|
@@ -2123,34 +2123,34 @@ class FMControllerThemes_fmc {
|
|
2123 |
'after' => 'px',
|
2124 |
),
|
2125 |
array(
|
2126 |
-
'label' => __('Color',
|
2127 |
'name' => 'NBPColor',
|
2128 |
'type' => 'text',
|
2129 |
'class' => 'color',
|
2130 |
-
'placeholder' => __('e.g.',
|
2131 |
'value' => isset($param_values->NBPColor) ? $param_values->NBPColor : '',
|
2132 |
'after' => '',
|
2133 |
),
|
2134 |
array(
|
2135 |
-
'label' => __('Padding',
|
2136 |
'name' => 'NBPPadding',
|
2137 |
'type' => 'text',
|
2138 |
'class' => '',
|
2139 |
-
'placeholder' => __('e.g.',
|
2140 |
'value' => isset($param_values->NBPPadding) ? $param_values->NBPPadding : '',
|
2141 |
'after' => '',
|
2142 |
),
|
2143 |
array(
|
2144 |
-
'label' => __('Margin',
|
2145 |
'name' => 'NBPMargin',
|
2146 |
'type' => 'text',
|
2147 |
'class' => '',
|
2148 |
-
'placeholder' => __('e.g.',
|
2149 |
'value' => isset($param_values->NBPMargin) ? $param_values->NBPMargin : '',
|
2150 |
'after' => '',
|
2151 |
),
|
2152 |
array(
|
2153 |
-
'label' => __('Border',
|
2154 |
'name' => 'NBPBorder',
|
2155 |
'type' => 'checkbox',
|
2156 |
'options' => $borders,
|
@@ -2158,16 +2158,16 @@ class FMControllerThemes_fmc {
|
|
2158 |
'after' => '',
|
2159 |
),
|
2160 |
array(
|
2161 |
-
'label' => __('Border Color',
|
2162 |
'name' => 'NBPBorderColor',
|
2163 |
'type' => 'text',
|
2164 |
'class' => 'color',
|
2165 |
-
'placeholder' => __('e.g.',
|
2166 |
'value' => isset($param_values->NBPBorderColor) ? $param_values->NBPBorderColor : '',
|
2167 |
'after' => '',
|
2168 |
),
|
2169 |
array(
|
2170 |
-
'label' => __('Border Type',
|
2171 |
'name' => 'NBPBorderType',
|
2172 |
'type' => 'select',
|
2173 |
'options' => $border_types,
|
@@ -2176,7 +2176,7 @@ class FMControllerThemes_fmc {
|
|
2176 |
'after' => '',
|
2177 |
),
|
2178 |
array(
|
2179 |
-
'label' => __('Border Width',
|
2180 |
'name' => 'NBPBorderWidth',
|
2181 |
'type' => 'text',
|
2182 |
'class' => '',
|
@@ -2184,7 +2184,7 @@ class FMControllerThemes_fmc {
|
|
2184 |
'after' => 'px',
|
2185 |
),
|
2186 |
array(
|
2187 |
-
'label' => __('Border Radius',
|
2188 |
'name' => 'NBPBorderRadius',
|
2189 |
'type' => 'text',
|
2190 |
'class' => '',
|
@@ -2192,40 +2192,40 @@ class FMControllerThemes_fmc {
|
|
2192 |
'after' => 'px',
|
2193 |
),
|
2194 |
array(
|
2195 |
-
'label' => __('Box Shadow',
|
2196 |
'name' => 'NBPBoxShadow',
|
2197 |
'type' => 'text',
|
2198 |
'class' => '',
|
2199 |
-
'placeholder' => __('e.g.',
|
2200 |
'value' => isset($param_values->NBPBoxShadow) ? $param_values->NBPBoxShadow : '',
|
2201 |
'after' => '',
|
2202 |
),
|
2203 |
array(
|
2204 |
-
'label' => __('Hover Parameters',
|
2205 |
'type' => 'label',
|
2206 |
'class' => 'fm-mini-title',
|
2207 |
'after' => '<br/>',
|
2208 |
),
|
2209 |
array(
|
2210 |
-
'label' => __('Background Color',
|
2211 |
'name' => 'NBHPBGColor',
|
2212 |
'type' => 'text',
|
2213 |
'class' => 'color',
|
2214 |
-
'placeholder' => __('e.g.',
|
2215 |
'value' => isset($param_values->NBHPBGColor) ? $param_values->NBHPBGColor : '',
|
2216 |
'after' => '',
|
2217 |
),
|
2218 |
array(
|
2219 |
-
'label' => __('Color',
|
2220 |
'name' => 'NBHPColor',
|
2221 |
'type' => 'text',
|
2222 |
'class' => 'color',
|
2223 |
-
'placeholder' => __('e.g.',
|
2224 |
'value' => isset($param_values->NBHPColor) ? $param_values->NBHPColor : '',
|
2225 |
'after' => '',
|
2226 |
),
|
2227 |
array(
|
2228 |
-
'label' => __('Border',
|
2229 |
'name' => 'NBHPBorder',
|
2230 |
'type' => 'checkbox',
|
2231 |
'options' => $borders,
|
@@ -2233,16 +2233,16 @@ class FMControllerThemes_fmc {
|
|
2233 |
'after' => '',
|
2234 |
),
|
2235 |
array(
|
2236 |
-
'label' => __('Border Color',
|
2237 |
'name' => 'NBHPBorderColor',
|
2238 |
'type' => 'text',
|
2239 |
'class' => 'color',
|
2240 |
-
'placeholder' => __('e.g.',
|
2241 |
'value' => isset($param_values->NBHPBorderColor) ? $param_values->NBHPBorderColor : '',
|
2242 |
'after' => '',
|
2243 |
),
|
2244 |
array(
|
2245 |
-
'label' => __('Border Type',
|
2246 |
'name' => 'NBHPBorderType',
|
2247 |
'type' => 'select',
|
2248 |
'options' => $border_types,
|
@@ -2251,7 +2251,7 @@ class FMControllerThemes_fmc {
|
|
2251 |
'after' => '',
|
2252 |
),
|
2253 |
array(
|
2254 |
-
'label' => __('Border Width',
|
2255 |
'name' => 'NBHPBorderWidth',
|
2256 |
'type' => 'text',
|
2257 |
'class' => '',
|
@@ -2259,23 +2259,23 @@ class FMControllerThemes_fmc {
|
|
2259 |
'after' => 'px</div>',
|
2260 |
),
|
2261 |
array(
|
2262 |
-
'label' => __('Previous Button Parameters',
|
2263 |
'type' => 'panel',
|
2264 |
'class' => 'col-md-12',
|
2265 |
'label_class' => 'fm-mini-title',
|
2266 |
'after' => '<br/>',
|
2267 |
),
|
2268 |
array(
|
2269 |
-
'label' => __('Background Color',
|
2270 |
'name' => 'PBPBGColor',
|
2271 |
'type' => 'text',
|
2272 |
'class' => 'color',
|
2273 |
-
'placeholder' => __('e.g.',
|
2274 |
'value' => isset($param_values->PBPBGColor) ? $param_values->PBPBGColor : '',
|
2275 |
'after' => '',
|
2276 |
),
|
2277 |
array(
|
2278 |
-
'label' => __('Width',
|
2279 |
'name' => 'PBPWidth',
|
2280 |
'type' => 'text',
|
2281 |
'class' => '',
|
@@ -2283,7 +2283,7 @@ class FMControllerThemes_fmc {
|
|
2283 |
'after' => 'px',
|
2284 |
),
|
2285 |
array(
|
2286 |
-
'label' => __('Height',
|
2287 |
'name' => 'PBPHeight',
|
2288 |
'type' => 'text',
|
2289 |
'class' => '',
|
@@ -2291,7 +2291,7 @@ class FMControllerThemes_fmc {
|
|
2291 |
'after' => 'px',
|
2292 |
),
|
2293 |
array(
|
2294 |
-
'label' => __('Line Height',
|
2295 |
'name' => 'PBPLineHeight',
|
2296 |
'type' => 'text',
|
2297 |
'class' => '',
|
@@ -2299,34 +2299,34 @@ class FMControllerThemes_fmc {
|
|
2299 |
'after' => 'px',
|
2300 |
),
|
2301 |
array(
|
2302 |
-
'label' => __('Color',
|
2303 |
'name' => 'PBPColor',
|
2304 |
'type' => 'text',
|
2305 |
'class' => 'color',
|
2306 |
-
'placeholder' => __('e.g.',
|
2307 |
'value' => isset($param_values->PBPColor) ? $param_values->PBPColor : '',
|
2308 |
'after' => '',
|
2309 |
),
|
2310 |
array(
|
2311 |
-
'label' => __('Padding',
|
2312 |
'name' => 'PBPPadding',
|
2313 |
'type' => 'text',
|
2314 |
'class' => '',
|
2315 |
-
'placeholder' => __('e.g.',
|
2316 |
'value' => isset($param_values->PBPPadding) ? $param_values->PBPPadding : '',
|
2317 |
'after' => '',
|
2318 |
),
|
2319 |
array(
|
2320 |
-
'label' => __('Margin',
|
2321 |
'name' => 'PBPMargin',
|
2322 |
'type' => 'text',
|
2323 |
'class' => '',
|
2324 |
-
'placeholder' => __('e.g.',
|
2325 |
'value' => isset($param_values->PBPMargin) ? $param_values->PBPMargin : '',
|
2326 |
'after' => '',
|
2327 |
),
|
2328 |
array(
|
2329 |
-
'label' => __('Border',
|
2330 |
'name' => 'PBPBorder',
|
2331 |
'type' => 'checkbox',
|
2332 |
'options' => $borders,
|
@@ -2334,16 +2334,16 @@ class FMControllerThemes_fmc {
|
|
2334 |
'after' => '',
|
2335 |
),
|
2336 |
array(
|
2337 |
-
'label' => __('Border Color',
|
2338 |
'name' => 'PBPBorderColor',
|
2339 |
'type' => 'text',
|
2340 |
'class' => 'color',
|
2341 |
-
'placeholder' => __('e.g.',
|
2342 |
'value' => isset($param_values->PBPBorderColor) ? $param_values->PBPBorderColor : '',
|
2343 |
'after' => '',
|
2344 |
),
|
2345 |
array(
|
2346 |
-
'label' => __('Border Type',
|
2347 |
'name' => 'PBPBorderType',
|
2348 |
'type' => 'select',
|
2349 |
'options' => $border_types,
|
@@ -2352,7 +2352,7 @@ class FMControllerThemes_fmc {
|
|
2352 |
'after' => '',
|
2353 |
),
|
2354 |
array(
|
2355 |
-
'label' => __('Border Width',
|
2356 |
'name' => 'PBPBorderWidth',
|
2357 |
'type' => 'text',
|
2358 |
'class' => '',
|
@@ -2360,7 +2360,7 @@ class FMControllerThemes_fmc {
|
|
2360 |
'after' => 'px',
|
2361 |
),
|
2362 |
array(
|
2363 |
-
'label' => __('Border Radius',
|
2364 |
'name' => 'PBPBorderRadius',
|
2365 |
'type' => 'text',
|
2366 |
'class' => '',
|
@@ -2368,40 +2368,40 @@ class FMControllerThemes_fmc {
|
|
2368 |
'after' => 'px',
|
2369 |
),
|
2370 |
array(
|
2371 |
-
'label' => __('Box Shadow',
|
2372 |
'name' => 'PBPBoxShadow',
|
2373 |
'type' => 'text',
|
2374 |
'class' => '',
|
2375 |
-
'placeholder' => __('e.g.',
|
2376 |
'value' => isset($param_values->PBPBoxShadow) ? $param_values->PBPBoxShadow : '',
|
2377 |
'after' => '',
|
2378 |
),
|
2379 |
array(
|
2380 |
-
'label' => __('Hover Parameters',
|
2381 |
'type' => 'label',
|
2382 |
'class' => 'fm-mini-title',
|
2383 |
'after' => '<br/>',
|
2384 |
),
|
2385 |
array(
|
2386 |
-
'label' => __('Background Color',
|
2387 |
'name' => 'PBHPBGColor',
|
2388 |
'type' => 'text',
|
2389 |
'class' => 'color',
|
2390 |
-
'placeholder' => __('e.g.',
|
2391 |
'value' => isset($param_values->PBHPBGColor) ? $param_values->PBHPBGColor : '',
|
2392 |
'after' => '',
|
2393 |
),
|
2394 |
array(
|
2395 |
-
'label' => __('Color',
|
2396 |
'name' => 'PBHPColor',
|
2397 |
'type' => 'text',
|
2398 |
'class' => 'color',
|
2399 |
-
'placeholder' => __('e.g.',
|
2400 |
'value' => isset($param_values->PBHPColor) ? $param_values->PBHPColor : '',
|
2401 |
'after' => '',
|
2402 |
),
|
2403 |
array(
|
2404 |
-
'label' => __('Border',
|
2405 |
'name' => 'PBHPBorder',
|
2406 |
'type' => 'checkbox',
|
2407 |
'options' => $borders,
|
@@ -2409,16 +2409,16 @@ class FMControllerThemes_fmc {
|
|
2409 |
'after' => '',
|
2410 |
),
|
2411 |
array(
|
2412 |
-
'label' => __('Border Color',
|
2413 |
'name' => 'PBHPBorderColor',
|
2414 |
'type' => 'text',
|
2415 |
'class' => 'color',
|
2416 |
-
'placeholder' => __('e.g.',
|
2417 |
'value' => isset($param_values->PBHPBorderColor) ? $param_values->PBHPBorderColor : '',
|
2418 |
'after' => '',
|
2419 |
),
|
2420 |
array(
|
2421 |
-
'label' => __('Border Type',
|
2422 |
'name' => 'PBHPBorderType',
|
2423 |
'type' => 'select',
|
2424 |
'options' => $border_types,
|
@@ -2427,7 +2427,7 @@ class FMControllerThemes_fmc {
|
|
2427 |
'after' => '',
|
2428 |
),
|
2429 |
array(
|
2430 |
-
'label' => __('Border Width',
|
2431 |
'name' => 'PBHPBorderWidth',
|
2432 |
'type' => 'text',
|
2433 |
'class' => '',
|
@@ -2444,7 +2444,7 @@ class FMControllerThemes_fmc {
|
|
2444 |
'after' => '',
|
2445 |
),
|
2446 |
array(
|
2447 |
-
'label' => __('Position',
|
2448 |
'name' => 'CBPPosition',
|
2449 |
'type' => 'select',
|
2450 |
'options' => $position_types,
|
@@ -2453,52 +2453,52 @@ class FMControllerThemes_fmc {
|
|
2453 |
'after' => '',
|
2454 |
),
|
2455 |
array(
|
2456 |
-
'label' => __('Top',
|
2457 |
'name' => 'CBPTop',
|
2458 |
'type' => 'text',
|
2459 |
'class' => '',
|
2460 |
-
'placeholder' => __('e.g.',
|
2461 |
'value' => isset($param_values->CBPTop) ? $param_values->CBPTop : '',
|
2462 |
'after' => '',
|
2463 |
),
|
2464 |
array(
|
2465 |
-
'label' => __('Right',
|
2466 |
'name' => 'CBPRight',
|
2467 |
'type' => 'text',
|
2468 |
'class' => '',
|
2469 |
-
'placeholder' => __('e.g.',
|
2470 |
'value' => isset($param_values->CBPRight) ? $param_values->CBPRight : '',
|
2471 |
'after' => '',
|
2472 |
),
|
2473 |
array(
|
2474 |
-
'label' => __('Bottom',
|
2475 |
'name' => 'CBPBottom',
|
2476 |
'type' => 'text',
|
2477 |
'class' => '',
|
2478 |
-
'placeholder' => __('e.g.',
|
2479 |
'value' => isset($param_values->CBPBottom) ? $param_values->CBPBottom : '',
|
2480 |
'after' => '',
|
2481 |
),
|
2482 |
array(
|
2483 |
-
'label' => __('Left',
|
2484 |
'name' => 'CBPLeft',
|
2485 |
'type' => 'text',
|
2486 |
'class' => '',
|
2487 |
-
'placeholder' => __('e.g.',
|
2488 |
'value' => isset($param_values->CBPLeft) ? $param_values->CBPLeft : '',
|
2489 |
'after' => '',
|
2490 |
),
|
2491 |
array(
|
2492 |
-
'label' => __('Background Color',
|
2493 |
'name' => 'CBPBGColor',
|
2494 |
'type' => 'text',
|
2495 |
'class' => 'color',
|
2496 |
-
'placeholder' => __('e.g.',
|
2497 |
'value' => isset($param_values->CBPBGColor) ? $param_values->CBPBGColor : '',
|
2498 |
'after' => '',
|
2499 |
),
|
2500 |
array(
|
2501 |
-
'label' => __('Font Size',
|
2502 |
'name' => 'CBPFontSize',
|
2503 |
'type' => 'text',
|
2504 |
'class' => '13',
|
@@ -2506,7 +2506,7 @@ class FMControllerThemes_fmc {
|
|
2506 |
'after' => 'px',
|
2507 |
),
|
2508 |
array(
|
2509 |
-
'label' => __('Font Weight',
|
2510 |
'name' => 'CBPFontWeight',
|
2511 |
'type' => 'select',
|
2512 |
'options' => $font_weights,
|
@@ -2515,34 +2515,34 @@ class FMControllerThemes_fmc {
|
|
2515 |
'after' => '',
|
2516 |
),
|
2517 |
array(
|
2518 |
-
'label' => __('Color',
|
2519 |
'name' => 'CBPColor',
|
2520 |
'type' => 'text',
|
2521 |
'class' => 'color',
|
2522 |
-
'placeholder' => __('e.g.',
|
2523 |
'value' => isset($param_values->CBPColor) ? $param_values->CBPColor : '',
|
2524 |
'after' => '',
|
2525 |
),
|
2526 |
array(
|
2527 |
-
'label' => __('Padding',
|
2528 |
'name' => 'CBPPadding',
|
2529 |
'type' => 'text',
|
2530 |
'class' => '',
|
2531 |
-
'placeholder' => __('e.g.',
|
2532 |
'value' => isset($param_values->CBPPadding) ? $param_values->CBPPadding : '',
|
2533 |
'after' => '',
|
2534 |
),
|
2535 |
array(
|
2536 |
-
'label' => __('Margin',
|
2537 |
'name' => 'CBPMargin',
|
2538 |
'type' => 'text',
|
2539 |
'class' => '',
|
2540 |
-
'placeholder' => __('e.g.',
|
2541 |
'value' => isset($param_values->CBPMargin) ? $param_values->CBPMargin : '',
|
2542 |
'after' => '',
|
2543 |
),
|
2544 |
array(
|
2545 |
-
'label' => __('Border',
|
2546 |
'name' => 'CBPBorder',
|
2547 |
'type' => 'checkbox',
|
2548 |
'options' => $borders,
|
@@ -2550,16 +2550,16 @@ class FMControllerThemes_fmc {
|
|
2550 |
'after' => '',
|
2551 |
),
|
2552 |
array(
|
2553 |
-
'label' => __('Border Color',
|
2554 |
'name' => 'CBPBorderColor',
|
2555 |
'type' => 'text',
|
2556 |
'class' => 'color',
|
2557 |
-
'placeholder' => __('e.g.',
|
2558 |
'value' => isset($param_values->CBPBorderColor) ? $param_values->CBPBorderColor : '',
|
2559 |
'after' => '',
|
2560 |
),
|
2561 |
array(
|
2562 |
-
'label' => __('Border Type',
|
2563 |
'name' => 'CBPBorderType',
|
2564 |
'type' => 'select',
|
2565 |
'options' => $border_types,
|
@@ -2568,7 +2568,7 @@ class FMControllerThemes_fmc {
|
|
2568 |
'after' => '',
|
2569 |
),
|
2570 |
array(
|
2571 |
-
'label' => __('Border Width',
|
2572 |
'name' => 'CBPBorderWidth',
|
2573 |
'type' => 'text',
|
2574 |
'class' => '',
|
@@ -2576,7 +2576,7 @@ class FMControllerThemes_fmc {
|
|
2576 |
'after' => 'px',
|
2577 |
),
|
2578 |
array(
|
2579 |
-
'label' => __('Border Radius',
|
2580 |
'name' => 'CBPBorderRadius',
|
2581 |
'type' => 'text',
|
2582 |
'class' => '',
|
@@ -2584,31 +2584,31 @@ class FMControllerThemes_fmc {
|
|
2584 |
'after' => 'px',
|
2585 |
),
|
2586 |
array(
|
2587 |
-
'label' => __('Hover Parameters',
|
2588 |
'type' => 'label',
|
2589 |
'class' => 'fm-mini-title',
|
2590 |
'after' => '<br/>',
|
2591 |
),
|
2592 |
array(
|
2593 |
-
'label' => __('Background Color',
|
2594 |
'name' => 'CBHPBGColor',
|
2595 |
'type' => 'text',
|
2596 |
'class' => 'color',
|
2597 |
-
'placeholder' => __('e.g.',
|
2598 |
'value' => isset($param_values->CBHPBGColor) ? $param_values->CBHPBGColor : '',
|
2599 |
'after' => '',
|
2600 |
),
|
2601 |
array(
|
2602 |
-
'label' => __('Color',
|
2603 |
'name' => 'CBHPColor',
|
2604 |
'type' => 'text',
|
2605 |
'class' => 'color',
|
2606 |
-
'placeholder' => __('e.g.',
|
2607 |
'value' => isset($param_values->CBHPColor) ? $param_values->CBHPColor : '',
|
2608 |
'after' => '',
|
2609 |
),
|
2610 |
array(
|
2611 |
-
'label' => __('Border',
|
2612 |
'name' => 'CBHPBorder',
|
2613 |
'type' => 'checkbox',
|
2614 |
'options' => $borders,
|
@@ -2616,16 +2616,16 @@ class FMControllerThemes_fmc {
|
|
2616 |
'after' => '',
|
2617 |
),
|
2618 |
array(
|
2619 |
-
'label' => __('Border Color',
|
2620 |
'name' => 'CBHPBorderColor',
|
2621 |
'type' => 'text',
|
2622 |
'class' => 'color',
|
2623 |
-
'placeholder' => __('e.g.',
|
2624 |
'value' => isset($param_values->CBHPBorderColor) ? $param_values->CBHPBorderColor : '',
|
2625 |
'after' => '',
|
2626 |
),
|
2627 |
array(
|
2628 |
-
'label' => __('Border Type',
|
2629 |
'name' => 'CBHPBorderType',
|
2630 |
'type' => 'select',
|
2631 |
'options' => $border_types,
|
@@ -2634,7 +2634,7 @@ class FMControllerThemes_fmc {
|
|
2634 |
'after' => '',
|
2635 |
),
|
2636 |
array(
|
2637 |
-
'label' => __('Border Width',
|
2638 |
'name' => 'CBHPBorderWidth',
|
2639 |
'type' => 'text',
|
2640 |
'class' => '',
|
@@ -2651,16 +2651,16 @@ class FMControllerThemes_fmc {
|
|
2651 |
'after' => '',
|
2652 |
),
|
2653 |
array(
|
2654 |
-
'label' => __('Background Color',
|
2655 |
'name' => 'MBPBGColor',
|
2656 |
'type' => 'text',
|
2657 |
'class' => 'color',
|
2658 |
-
'placeholder' => __('e.g.',
|
2659 |
'value' => isset($param_values->MBPBGColor) ? $param_values->MBPBGColor : '',
|
2660 |
'after' => '',
|
2661 |
),
|
2662 |
array(
|
2663 |
-
'label' => __('Font Size',
|
2664 |
'name' => 'MBPFontSize',
|
2665 |
'type' => 'text',
|
2666 |
'class' => '13',
|
@@ -2668,7 +2668,7 @@ class FMControllerThemes_fmc {
|
|
2668 |
'after' => 'px',
|
2669 |
),
|
2670 |
array(
|
2671 |
-
'label' => __('Font Weight',
|
2672 |
'name' => 'MBPFontWeight',
|
2673 |
'type' => 'select',
|
2674 |
'options' => $font_weights,
|
@@ -2677,16 +2677,16 @@ class FMControllerThemes_fmc {
|
|
2677 |
'after' => '',
|
2678 |
),
|
2679 |
array(
|
2680 |
-
'label' => __('Color',
|
2681 |
'name' => 'MBPColor',
|
2682 |
'type' => 'text',
|
2683 |
'class' => 'color',
|
2684 |
-
'placeholder' => __('e.g.',
|
2685 |
'value' => isset($param_values->MBPColor) ? $param_values->MBPColor : '',
|
2686 |
'after' => '',
|
2687 |
),
|
2688 |
array(
|
2689 |
-
'label' => __('Text Align',
|
2690 |
'name' => 'MBPTextAlign',
|
2691 |
'type' => 'select',
|
2692 |
'options' => $aligns,
|
@@ -2695,25 +2695,25 @@ class FMControllerThemes_fmc {
|
|
2695 |
'after' => '',
|
2696 |
),
|
2697 |
array(
|
2698 |
-
'label' => __('Padding',
|
2699 |
'name' => 'MBPPadding',
|
2700 |
'type' => 'text',
|
2701 |
'class' => '',
|
2702 |
-
'placeholder' => __('e.g.',
|
2703 |
'value' => isset($param_values->MBPPadding) ? $param_values->MBPPadding : '',
|
2704 |
'after' => 'px|%',
|
2705 |
),
|
2706 |
array(
|
2707 |
-
'label' => __('Margin',
|
2708 |
'name' => 'MBPMargin',
|
2709 |
'type' => 'text',
|
2710 |
'class' => '',
|
2711 |
-
'placeholder' => __('e.g.',
|
2712 |
'value' => isset($param_values->MBPMargin) ? $param_values->MBPMargin : '',
|
2713 |
'after' => 'px|%',
|
2714 |
),
|
2715 |
array(
|
2716 |
-
'label' => __('Border',
|
2717 |
'name' => 'MBPBorder',
|
2718 |
'type' => 'checkbox',
|
2719 |
'options' => $borders,
|
@@ -2721,16 +2721,16 @@ class FMControllerThemes_fmc {
|
|
2721 |
'after' => '',
|
2722 |
),
|
2723 |
array(
|
2724 |
-
'label' => __('Border Color',
|
2725 |
'name' => 'MBPBorderColor',
|
2726 |
'type' => 'text',
|
2727 |
'class' => 'color',
|
2728 |
-
'placeholder' => __('e.g.',
|
2729 |
'value' => isset($param_values->MBPBorderColor) ? $param_values->MBPBorderColor : '',
|
2730 |
'after' => '',
|
2731 |
),
|
2732 |
array(
|
2733 |
-
'label' => __('Border Type',
|
2734 |
'name' => 'MBPBorderType',
|
2735 |
'type' => 'select',
|
2736 |
'options' => $border_types,
|
@@ -2739,7 +2739,7 @@ class FMControllerThemes_fmc {
|
|
2739 |
'after' => '',
|
2740 |
),
|
2741 |
array(
|
2742 |
-
'label' => __('Border Width',
|
2743 |
'name' => 'MBPBorderWidth',
|
2744 |
'type' => 'text',
|
2745 |
'class' => '',
|
@@ -2747,7 +2747,7 @@ class FMControllerThemes_fmc {
|
|
2747 |
'after' => 'px',
|
2748 |
),
|
2749 |
array(
|
2750 |
-
'label' => __('Border Radius',
|
2751 |
'name' => 'MBPBorderRadius',
|
2752 |
'type' => 'text',
|
2753 |
'class' => '',
|
@@ -2755,31 +2755,31 @@ class FMControllerThemes_fmc {
|
|
2755 |
'after' => 'px',
|
2756 |
),
|
2757 |
array(
|
2758 |
-
'label' => __('Hover Parameters',
|
2759 |
'type' => 'label',
|
2760 |
'class' => 'fm-mini-title',
|
2761 |
'after' => '<br/>',
|
2762 |
),
|
2763 |
array(
|
2764 |
-
'label' => __('Background Color',
|
2765 |
'name' => 'MBHPBGColor',
|
2766 |
'type' => 'text',
|
2767 |
'class' => 'color',
|
2768 |
-
'placeholder' => __('e.g.',
|
2769 |
'value' => isset($param_values->MBHPBGColor) ? $param_values->MBHPBGColor : '',
|
2770 |
'after' => '',
|
2771 |
),
|
2772 |
array(
|
2773 |
-
'label' => __('Color',
|
2774 |
'name' => 'MBHPColor',
|
2775 |
'type' => 'text',
|
2776 |
'class' => 'color',
|
2777 |
-
'placeholder' => __('e.g.',
|
2778 |
'value' => isset($param_values->MBHPColor) ? $param_values->MBHPColor : '',
|
2779 |
'after' => '',
|
2780 |
),
|
2781 |
array(
|
2782 |
-
'label' => __('Border',
|
2783 |
'name' => 'MBHPBorder',
|
2784 |
'type' => 'checkbox',
|
2785 |
'options' => $borders,
|
@@ -2787,7 +2787,7 @@ class FMControllerThemes_fmc {
|
|
2787 |
'after' => '',
|
2788 |
),
|
2789 |
array(
|
2790 |
-
'label' => __('Border Color',
|
2791 |
'name' => 'MBHPBorderColor',
|
2792 |
'type' => 'text',
|
2793 |
'class' => 'color',
|
@@ -2795,7 +2795,7 @@ class FMControllerThemes_fmc {
|
|
2795 |
'after' => '',
|
2796 |
),
|
2797 |
array(
|
2798 |
-
'label' => __('Border Type',
|
2799 |
'name' => 'MBHPBorderType',
|
2800 |
'type' => 'select',
|
2801 |
'options' => $border_types,
|
@@ -2804,7 +2804,7 @@ class FMControllerThemes_fmc {
|
|
2804 |
'after' => '',
|
2805 |
),
|
2806 |
array(
|
2807 |
-
'label' => __('Border Width',
|
2808 |
'name' => 'MBHPBorderWidth',
|
2809 |
'type' => 'text',
|
2810 |
'class' => '',
|
@@ -2814,23 +2814,23 @@ class FMControllerThemes_fmc {
|
|
2814 |
),
|
2815 |
'other' => array(
|
2816 |
array(
|
2817 |
-
'label' => __('Inactive Text',
|
2818 |
'type' => 'panel',
|
2819 |
'class' => 'col-md-12',
|
2820 |
'label_class' => 'fm-mini-title',
|
2821 |
'after' => '<br/>',
|
2822 |
),
|
2823 |
array(
|
2824 |
-
'label' => __('Color',
|
2825 |
'name' => 'OPDeInputColor',
|
2826 |
'type' => 'text',
|
2827 |
'class' => 'color',
|
2828 |
-
'placeholder' => __('e.g.',
|
2829 |
'value' => isset($param_values->OPDeInputColor) ? $param_values->OPDeInputColor : '',
|
2830 |
'after' => '',
|
2831 |
),
|
2832 |
array(
|
2833 |
-
'label' => __('Font Style',
|
2834 |
'name' => 'OPFontStyle',
|
2835 |
'type' => 'text',
|
2836 |
'class' => '',
|
@@ -2838,13 +2838,13 @@ class FMControllerThemes_fmc {
|
|
2838 |
'after' => '',
|
2839 |
),
|
2840 |
array(
|
2841 |
-
'label' => __('Required',
|
2842 |
'type' => 'label',
|
2843 |
'class' => 'fm-mini-title',
|
2844 |
'after' => '<br/>',
|
2845 |
),
|
2846 |
array(
|
2847 |
-
'label' => __('Color',
|
2848 |
'name' => 'OPRColor',
|
2849 |
'type' => 'text',
|
2850 |
'class' => 'color',
|
@@ -2852,22 +2852,22 @@ class FMControllerThemes_fmc {
|
|
2852 |
'after' => '',
|
2853 |
),
|
2854 |
array(
|
2855 |
-
'label' => __('File Upload',
|
2856 |
'type' => 'label',
|
2857 |
'class' => 'fm-mini-title',
|
2858 |
'after' => '<br/>',
|
2859 |
),
|
2860 |
array(
|
2861 |
-
'label' => __('Background URL',
|
2862 |
'name' => 'OPFBgUrl',
|
2863 |
'type' => 'text',
|
2864 |
'class' => '',
|
2865 |
-
// 'placeholder' => __('e.g. http:// or https://',
|
2866 |
'value' => isset($param_values->OPFBgUrl) ? $param_values->OPFBgUrl : '',
|
2867 |
'after' => '',
|
2868 |
),
|
2869 |
array(
|
2870 |
-
'label' => __('Background Repeat',
|
2871 |
'name' => 'OPFBGRepeat',
|
2872 |
'type' => 'select',
|
2873 |
'options' => $bg_repeats,
|
@@ -2876,12 +2876,12 @@ class FMControllerThemes_fmc {
|
|
2876 |
'after' => '',
|
2877 |
),
|
2878 |
array(
|
2879 |
-
'label' => __('Background Position',
|
2880 |
'name1' => 'OPFPos1',
|
2881 |
'name2' => 'OPFPos2',
|
2882 |
'type' => '2text',
|
2883 |
'class' => 'fm-2text',
|
2884 |
-
'placeholder' => __('e.g.',
|
2885 |
'value1' => isset($param_values->OPFPos1) ? $param_values->OPFPos1 : '',
|
2886 |
'value2' => isset($param_values->OPFPos2) ? $param_values->OPFPos2 : '',
|
2887 |
'before1' => '',
|
@@ -2889,13 +2889,13 @@ class FMControllerThemes_fmc {
|
|
2889 |
'after' => '',
|
2890 |
),
|
2891 |
array(
|
2892 |
-
'label' => __('Grading',
|
2893 |
'type' => 'label',
|
2894 |
'class' => 'fm-mini-title',
|
2895 |
'after' => '<br/>',
|
2896 |
),
|
2897 |
array(
|
2898 |
-
'label' => __('Text Width',
|
2899 |
'name' => 'OPGWidth',
|
2900 |
'type' => 'text',
|
2901 |
'class' => '',
|
@@ -2912,7 +2912,7 @@ class FMControllerThemes_fmc {
|
|
2912 |
'after' => '',
|
2913 |
),
|
2914 |
array(
|
2915 |
-
'label' => __('Custom CSS',
|
2916 |
'name' => 'CUPCSS',
|
2917 |
'type' => 'textarea',
|
2918 |
'class' => '',
|
@@ -2930,11 +2930,11 @@ class FMControllerThemes_fmc {
|
|
2930 |
*/
|
2931 |
public function apply() {
|
2932 |
$data = $this->save_db();
|
2933 |
-
$page =
|
2934 |
-
$active_tab =
|
2935 |
-
$pagination =
|
2936 |
-
$form_type =
|
2937 |
-
|
2938 |
'page' => $page,
|
2939 |
'task' => 'edit',
|
2940 |
'current_id' => $data['id'],
|
@@ -2952,7 +2952,7 @@ class FMControllerThemes_fmc {
|
|
2952 |
*/
|
2953 |
public function save_db() {
|
2954 |
global $wpdb;
|
2955 |
-
$id = (int)
|
2956 |
$title = (isset($_POST['title']) ? esc_html(stripslashes($_POST['title'])) : '');
|
2957 |
$version = 2;
|
2958 |
$params = (isset($_POST['params']) ? stripslashes(preg_replace("/(^[\r\n]*|[\r\n]+)[\s\t]*[\r\n]+/", "\n", $_POST['params'])) : '');
|
@@ -2975,17 +2975,17 @@ class FMControllerThemes_fmc {
|
|
2975 |
$id = $wpdb->insert_id;
|
2976 |
}
|
2977 |
if ( $save !== FALSE ) {
|
2978 |
-
require_once
|
2979 |
$model_frontend = new FMModelForm_maker_fmc();
|
2980 |
$form_theme = json_decode(html_entity_decode($params), TRUE);
|
2981 |
$model_frontend->create_css($id, $form_theme, $version == 1, TRUE);
|
|
|
2982 |
$msg = 1;
|
2983 |
}
|
2984 |
else {
|
2985 |
$msg = 2;
|
2986 |
}
|
2987 |
-
|
2988 |
-
return array( 'id' => $id, 'msg' => $msg );
|
2989 |
}
|
2990 |
|
2991 |
/**
|
@@ -2993,20 +2993,20 @@ class FMControllerThemes_fmc {
|
|
2993 |
*
|
2994 |
* @param $id
|
2995 |
*/
|
2996 |
-
|
2997 |
-
|
2998 |
-
|
2999 |
-
|
3000 |
-
|
3001 |
-
|
3002 |
-
|
3003 |
-
|
3004 |
-
|
3005 |
-
|
3006 |
-
|
3007 |
-
|
3008 |
-
|
3009 |
-
|
3010 |
-
|
3011 |
-
|
3012 |
}
|
3 |
/**
|
4 |
* Class FMControllerThemes_fmc
|
5 |
*/
|
6 |
+
class FMControllerThemes_fmc extends CFMAdminController {
|
7 |
/**
|
8 |
* @var $model
|
9 |
*/
|
30 |
private $actions = array();
|
31 |
|
32 |
public function __construct() {
|
33 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/Themes_fm.php";
|
34 |
$this->model = new FMModelThemes_fmc();
|
35 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Themes_fm.php";
|
36 |
$this->view = new FMViewThemes_fmc();
|
37 |
+
$this->page = WDW_FM_Library(self::PLUGIN)->get('page');
|
38 |
$this->bulk_action_name = 'bulk_action';
|
39 |
|
40 |
$this->actions = array(
|
41 |
'duplicate' => array(
|
42 |
+
'title' => __('Duplicate', WDFMInstance(self::PLUGIN)->prefix),
|
43 |
+
$this->bulk_action_name => __('duplicated', WDFMInstance(self::PLUGIN)->prefix),
|
44 |
),
|
45 |
'delete' => array(
|
46 |
+
'title' => __('Delete', WDFMInstance(self::PLUGIN)->prefix),
|
47 |
+
$this->bulk_action_name => __('deleted', WDFMInstance(self::PLUGIN)->prefix),
|
48 |
),
|
49 |
);
|
50 |
}
|
53 |
* Execute.
|
54 |
*/
|
55 |
public function execute() {
|
56 |
+
$task = WDW_FM_Library(self::PLUGIN)->get('task');
|
57 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
58 |
if ( method_exists($this, $task) ) {
|
59 |
if ( $task != 'add' && $task != 'edit' && $task != 'display' ) {
|
60 |
+
check_admin_referer(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce);
|
61 |
}
|
62 |
$block_action = $this->bulk_action_name;
|
63 |
+
$action = WDW_FM_Library(self::PLUGIN)->get($block_action, -1);
|
64 |
if ( $action != -1 ) {
|
65 |
$this->$block_action($action);
|
66 |
}
|
80 |
// Set params for view.
|
81 |
$params = array();
|
82 |
$params['page'] = $this->page;
|
83 |
+
$params['page_title'] = __('Themes', WDFMInstance(self::PLUGIN)->prefix);
|
84 |
$params['actions'] = $this->actions;
|
85 |
+
$params['order'] = WDW_FM_Library(self::PLUGIN)->get('order', 'desc');
|
86 |
+
$params['orderby'] = WDW_FM_Library(self::PLUGIN)->get('orderby', 'default');
|
87 |
// To prevent SQL injections.
|
88 |
$params['order'] = ($params['order'] == 'desc') ? 'desc' : 'asc';
|
89 |
if ( !in_array($params['orderby'], array( 'title', 'default' )) ) {
|
90 |
$params['orderby'] = 'default';
|
91 |
}
|
92 |
$params['items_per_page'] = $this->items_per_page;
|
93 |
+
$page = (int) WDW_FM_Library(self::PLUGIN)->get('paged', 1);
|
94 |
$page_num = $page ? ($page - 1) * $params['items_per_page'] : 0;
|
95 |
$params['page_num'] = $page_num;
|
96 |
+
$params['search'] = WDW_FM_Library(self::PLUGIN)->get('s', '');;
|
97 |
$params['total'] = $this->model->total();
|
98 |
$params['rows_data'] = $this->model->get_rows_data($params);
|
99 |
$this->view->display($params);
|
108 |
$message = 0;
|
109 |
$successfully_updated = 0;
|
110 |
|
111 |
+
$check = WDW_FM_Library(self::PLUGIN)->get('check', '');
|
112 |
|
113 |
if ( $check ) {
|
114 |
foreach ( $check as $form_id => $item ) {
|
122 |
}
|
123 |
if ( $successfully_updated ) {
|
124 |
$block_action = $this->bulk_action_name;
|
125 |
+
$message = sprintf(_n('%s item successfully %s.', '%s items successfully %s.', $successfully_updated, WDFMInstance(self::PLUGIN)->prefix), $successfully_updated, $this->actions[$task][$block_action]);
|
126 |
}
|
127 |
}
|
128 |
|
129 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
130 |
'page' => $this->page,
|
131 |
'task' => 'display',
|
132 |
($message === 2 ? 'message' : 'msg') => $message,
|
163 |
if ( $bulk ) {
|
164 |
return $message;
|
165 |
}
|
166 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array('page' => $this->page, 'task' => 'display', 'message' => $message), admin_url('admin.php') ) );
|
167 |
}
|
168 |
|
169 |
/**
|
195 |
return $message;
|
196 |
}
|
197 |
else {
|
198 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
199 |
'page' => $this->page,
|
200 |
'task' => 'display',
|
201 |
'message' => $message,
|
214 |
$params['row'] = $this->model->get_row_data($params['id'], FALSE);
|
215 |
|
216 |
if ( $id != 0 && empty($params['row']) ) {
|
217 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect( add_query_arg( array('page' => $this->page, 'task' => 'display'), admin_url('admin.php') ) );
|
218 |
}
|
219 |
$params['page_title'] = $params['row']->title;
|
220 |
$params['param_values'] = $params['row']->css;
|
221 |
$params['tabs'] = array(
|
222 |
+
'global' => __('Global Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
223 |
+
'header' => __('Header', WDFMInstance(self::PLUGIN)->prefix),
|
224 |
+
'content' => __('Content', WDFMInstance(self::PLUGIN)->prefix),
|
225 |
+
'input_select' => __('Inputbox', WDFMInstance(self::PLUGIN)->prefix),
|
226 |
+
'choices' => __('Choices', WDFMInstance(self::PLUGIN)->prefix),
|
227 |
+
'subscribe' => __('General Buttons', WDFMInstance(self::PLUGIN)->prefix),
|
228 |
+
'paigination' => __('Pagination', WDFMInstance(self::PLUGIN)->prefix),
|
229 |
+
'buttons' => __('Buttons', WDFMInstance(self::PLUGIN)->prefix),
|
230 |
+
'close_button' => __('Close(Minimize) Button', WDFMInstance(self::PLUGIN)->prefix),
|
231 |
+
'minimize' => __('Minimize Text', WDFMInstance(self::PLUGIN)->prefix),
|
232 |
+
'other' => __('Other', WDFMInstance(self::PLUGIN)->prefix),
|
233 |
+
'custom_css' => __('Custom CSS', WDFMInstance(self::PLUGIN)->prefix),
|
234 |
);
|
235 |
$border_types = array(
|
236 |
'' => '',
|
249 |
);
|
250 |
$borders = array(
|
251 |
'' => '',
|
252 |
+
'top' => __('Top', WDFMInstance(self::PLUGIN)->prefix),
|
253 |
+
'right' => __('Right', WDFMInstance(self::PLUGIN)->prefix),
|
254 |
+
'bottom' => __('Bottom', WDFMInstance(self::PLUGIN)->prefix),
|
255 |
+
'left' => __('Left', WDFMInstance(self::PLUGIN)->prefix)
|
256 |
);
|
257 |
$position_types = array(
|
258 |
'' => '',
|
269 |
'lighter' => 'Lighter',
|
270 |
'initial' => 'Initial',
|
271 |
);
|
272 |
+
$aligns = array( '' => '', 'left' => __('Left', WDFMInstance(self::PLUGIN)->prefix), 'center' => __('Center', WDFMInstance(self::PLUGIN)->prefix), 'right' => __('Right', WDFMInstance(self::PLUGIN)->prefix) );
|
273 |
$basic_fonts = array(
|
274 |
'' => '',
|
275 |
'arial' => 'Arial',
|
292 |
'initial' => 'initial',
|
293 |
'inherit' => 'inherit',
|
294 |
);
|
295 |
+
$google_fonts = WDW_FM_Library(self::PLUGIN)->get_google_fonts();
|
296 |
$font_families = $basic_fonts + $google_fonts;
|
297 |
$params['fonts'] = implode("|", str_replace(' ', '+', $google_fonts));
|
298 |
$params['all_params'] = $this->all_params($params['param_values'], $borders, $border_types, $font_weights, $position_types, $aligns, $bg_repeats, $font_families);
|
312 |
'after' => '',
|
313 |
),
|
314 |
array(
|
315 |
+
'label' => __('Font Family', WDFMInstance(self::PLUGIN)->prefix),
|
316 |
'name' => 'GPFontFamily',
|
317 |
'type' => 'select',
|
318 |
'options' => $font_families,
|
321 |
'after' => '',
|
322 |
),
|
323 |
array(
|
324 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
325 |
'name' => 'AGPWidth',
|
326 |
'type' => 'text',
|
327 |
'class' => '',
|
329 |
'after' => '%',
|
330 |
),
|
331 |
array(
|
332 |
+
'label' => __('Width (for scrollbox, popup form types)', WDFMInstance(self::PLUGIN)->prefix),
|
333 |
'name' => 'AGPSPWidth',
|
334 |
'type' => 'text',
|
335 |
'class' => '',
|
337 |
'after' => '%',
|
338 |
),
|
339 |
array(
|
340 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
341 |
'name' => 'AGPPadding',
|
342 |
'type' => 'text',
|
343 |
'class' => '',
|
344 |
+
'placeholder' => __('e.g. 3px 5px or 3% 5%', WDFMInstance(self::PLUGIN)->prefix),
|
345 |
'value' => isset($param_values->AGPPadding) ? $param_values->AGPPadding : '',
|
346 |
'after' => '',
|
347 |
),
|
348 |
array(
|
349 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
350 |
'name' => 'AGPMargin',
|
351 |
'type' => 'text',
|
352 |
'class' => '',
|
353 |
'value' => isset($param_values->AGPMargin) ? $param_values->AGPMargin : '',
|
354 |
+
'placeholder' => __('e.g. 5px 10px or 5% 10%', WDFMInstance(self::PLUGIN)->prefix),
|
355 |
'after' => '',
|
356 |
),
|
357 |
array(
|
358 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
359 |
'name' => 'AGPBorder',
|
360 |
'type' => 'checkbox',
|
361 |
'options' => $borders,
|
363 |
'after' => '',
|
364 |
),
|
365 |
array(
|
366 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
367 |
'name' => 'AGPBorderColor',
|
368 |
'type' => 'text',
|
369 |
'class' => 'color',
|
370 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #e5e5e5',
|
371 |
'value' => isset($param_values->AGPBorderColor) ? $param_values->AGPBorderColor : '',
|
372 |
'after' => '',
|
373 |
),
|
374 |
array(
|
375 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
376 |
'name' => 'AGPBorderType',
|
377 |
'type' => 'select',
|
378 |
'options' => $border_types,
|
381 |
'after' => '',
|
382 |
),
|
383 |
array(
|
384 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
385 |
'name' => 'AGPBorderWidth',
|
386 |
'type' => 'text',
|
387 |
'class' => '',
|
389 |
'after' => 'px',
|
390 |
),
|
391 |
array(
|
392 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
393 |
'name' => 'AGPBorderRadius',
|
394 |
'type' => 'text',
|
395 |
'class' => '',
|
397 |
'after' => 'px',
|
398 |
),
|
399 |
array(
|
400 |
+
'label' => __('Box Shadow', WDFMInstance(self::PLUGIN)->prefix),
|
401 |
'name' => 'AGPBoxShadow',
|
402 |
'type' => 'text',
|
403 |
'class' => '',
|
404 |
'value' => isset($param_values->AGPBoxShadow) ? $param_values->AGPBoxShadow : '',
|
405 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 5px 2px #888888',
|
406 |
'after' => '</div>',
|
407 |
),
|
408 |
),
|
409 |
'header' => array(
|
410 |
array(
|
411 |
+
'label' => __('General Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
412 |
'type' => 'panel',
|
413 |
'class' => 'col-md-12',
|
414 |
'label_class' => 'fm-mini-title',
|
415 |
'after' => '<br/>',
|
416 |
),
|
417 |
array(
|
418 |
+
'label' => __('Alignment', WDFMInstance(self::PLUGIN)->prefix),
|
419 |
'name' => 'HPAlign',
|
420 |
'type' => 'select',
|
421 |
'options' => $borders,
|
424 |
'after' => '',
|
425 |
),
|
426 |
array(
|
427 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
428 |
'name' => 'HPBGColor',
|
429 |
'type' => 'text',
|
430 |
'class' => 'color',
|
431 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
432 |
'value' => isset($param_values->HPBGColor) ? $param_values->HPBGColor : '',
|
433 |
'after' => '',
|
434 |
),
|
435 |
array(
|
436 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
437 |
'name' => 'HPWidth',
|
438 |
'type' => 'text',
|
439 |
'class' => '',
|
441 |
'after' => '%',
|
442 |
),
|
443 |
array(
|
444 |
+
'label' => __('Width (for topbar form type)', WDFMInstance(self::PLUGIN)->prefix),
|
445 |
'name' => 'HTPWidth',
|
446 |
'type' => 'text',
|
447 |
'class' => '',
|
449 |
'after' => '%',
|
450 |
),
|
451 |
array(
|
452 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
453 |
'name' => 'HPPadding',
|
454 |
'type' => 'text',
|
455 |
'class' => '',
|
456 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 3px 5px or 3% 5%',
|
457 |
'value' => isset($param_values->HPPadding) ? $param_values->HPPadding : '',
|
458 |
'after' => '',
|
459 |
),
|
460 |
array(
|
461 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
462 |
'name' => 'HPMargin',
|
463 |
'type' => 'text',
|
464 |
'class' => '',
|
465 |
'value' => isset($param_values->HPMargin) ? $param_values->HPMargin : '',
|
466 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
467 |
'after' => '',
|
468 |
),
|
469 |
array(
|
470 |
+
'label' => __('Text Align', WDFMInstance(self::PLUGIN)->prefix),
|
471 |
'name' => 'HPTextAlign',
|
472 |
'type' => 'select',
|
473 |
'options' => $aligns,
|
476 |
'after' => '',
|
477 |
),
|
478 |
array(
|
479 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
480 |
'name' => 'HPBorder',
|
481 |
'type' => 'checkbox',
|
482 |
'options' => $borders,
|
484 |
'after' => '',
|
485 |
),
|
486 |
array(
|
487 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
488 |
'name' => 'HPBorderColor',
|
489 |
'type' => 'text',
|
490 |
'class' => 'color',
|
491 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
492 |
'value' => isset($param_values->HPBorderColor) ? $param_values->HPBorderColor : '',
|
493 |
'after' => '',
|
494 |
),
|
495 |
array(
|
496 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
497 |
'name' => 'HPBorderType',
|
498 |
'type' => 'select',
|
499 |
'options' => $border_types,
|
502 |
'after' => '',
|
503 |
),
|
504 |
array(
|
505 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
506 |
'name' => 'HPBorderWidth',
|
507 |
'type' => 'text',
|
508 |
'class' => '',
|
510 |
'after' => 'px',
|
511 |
),
|
512 |
array(
|
513 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
514 |
'name' => 'HPBorderRadius',
|
515 |
'type' => 'text',
|
516 |
'class' => '',
|
518 |
'after' => 'px</div>',
|
519 |
),
|
520 |
array(
|
521 |
+
'label' => __('Title Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
522 |
'type' => 'panel',
|
523 |
'class' => 'col-md-12',
|
524 |
'label_class' => 'fm-mini-title',
|
525 |
'after' => '<br/>',
|
526 |
),
|
527 |
array(
|
528 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
529 |
'name' => 'HTPFontSize',
|
530 |
'type' => 'text',
|
531 |
'class' => '',
|
533 |
'after' => 'px',
|
534 |
),
|
535 |
array(
|
536 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
537 |
'name' => 'HTPWeight',
|
538 |
'type' => 'select',
|
539 |
'options' => $font_weights,
|
542 |
'after' => '',
|
543 |
),
|
544 |
array(
|
545 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
546 |
'name' => 'HTPColor',
|
547 |
'type' => 'text',
|
548 |
'class' => 'color',
|
549 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
550 |
'value' => isset($param_values->HTPColor) ? $param_values->HTPColor : '',
|
551 |
'after' => '',
|
552 |
),
|
553 |
array(
|
554 |
+
'label' => __('Description Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
555 |
'type' => 'label',
|
556 |
'class' => 'fm-mini-title',
|
557 |
'after' => '<br/>',
|
558 |
),
|
559 |
array(
|
560 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
561 |
'name' => 'HDPFontSize',
|
562 |
'type' => 'text',
|
563 |
'class' => '',
|
565 |
'after' => 'px',
|
566 |
),
|
567 |
array(
|
568 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
569 |
'name' => 'HDPColor',
|
570 |
'type' => 'text',
|
571 |
'class' => 'color',
|
572 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
573 |
'value' => isset($param_values->HDPColor) ? $param_values->HDPColor : '',
|
574 |
'after' => '',
|
575 |
),
|
576 |
array(
|
577 |
+
'label' => __('Image Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
578 |
'type' => 'label',
|
579 |
'class' => 'fm-mini-title',
|
580 |
'after' => '<br/>',
|
581 |
),
|
582 |
array(
|
583 |
+
'label' => __('Alignment', WDFMInstance(self::PLUGIN)->prefix),
|
584 |
'name' => 'HIPAlign',
|
585 |
'type' => 'select',
|
586 |
'options' => $borders,
|
589 |
'after' => '',
|
590 |
),
|
591 |
array(
|
592 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
593 |
'name' => 'HIPWidth',
|
594 |
'type' => 'text',
|
595 |
'class' => '',
|
597 |
'after' => 'px',
|
598 |
),
|
599 |
array(
|
600 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
601 |
'name' => 'HIPHeight',
|
602 |
'type' => 'text',
|
603 |
'class' => '',
|
607 |
),
|
608 |
'content' => array(
|
609 |
array(
|
610 |
+
'label' => __('General Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
611 |
'type' => 'panel',
|
612 |
'class' => 'col-md-12',
|
613 |
'label_class' => 'fm-mini-title',
|
614 |
'after' => '<br/>',
|
615 |
),
|
616 |
array(
|
617 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
618 |
'name' => 'GPBGColor',
|
619 |
'type' => 'text',
|
620 |
'class' => 'color',
|
621 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
622 |
'value' => isset($param_values->GPBGColor) ? $param_values->GPBGColor : '',
|
623 |
'after' => '',
|
624 |
),
|
625 |
array(
|
626 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
627 |
'name' => 'GPFontSize',
|
628 |
'type' => 'text',
|
629 |
'class' => '',
|
631 |
'after' => 'px',
|
632 |
),
|
633 |
array(
|
634 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
635 |
'name' => 'GPFontWeight',
|
636 |
'type' => 'select',
|
637 |
'options' => $font_weights,
|
640 |
'after' => '',
|
641 |
),
|
642 |
array(
|
643 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
644 |
'name' => 'GPWidth',
|
645 |
'type' => 'text',
|
646 |
'class' => '',
|
648 |
'after' => '%',
|
649 |
),
|
650 |
array(
|
651 |
+
'label' => __('Width (for topbar form type)', WDFMInstance(self::PLUGIN)->prefix),
|
652 |
'name' => 'GTPWidth',
|
653 |
'type' => 'text',
|
654 |
'class' => '',
|
656 |
'after' => '%',
|
657 |
),
|
658 |
array(
|
659 |
+
'label' => __('Alignment', WDFMInstance(self::PLUGIN)->prefix),
|
660 |
'name' => 'GPAlign',
|
661 |
'type' => 'select',
|
662 |
'options' => $aligns,
|
665 |
'after' => '',
|
666 |
),
|
667 |
array(
|
668 |
+
'label' => __('Background URL', WDFMInstance(self::PLUGIN)->prefix),
|
669 |
'name' => 'GPBackground',
|
670 |
'type' => 'text',
|
671 |
'class' => '',
|
672 |
+
// 'placeholder' => __('e.g. http:// or https://', WDFMInstance(self::PLUGIN)->prefix),
|
673 |
'value' => isset($param_values->GPBackground) ? $param_values->GPBackground : '',
|
674 |
'after' => '',
|
675 |
),
|
676 |
array(
|
677 |
+
'label' => __('Background Repeat', WDFMInstance(self::PLUGIN)->prefix),
|
678 |
'name' => 'GPBackgroundRepeat',
|
679 |
'type' => 'select',
|
680 |
'options' => $bg_repeats,
|
683 |
'after' => '',
|
684 |
),
|
685 |
array(
|
686 |
+
'label' => __('Background Position', WDFMInstance(self::PLUGIN)->prefix),
|
687 |
'name1' => 'GPBGPosition1',
|
688 |
'name2' => 'GPBGPosition2',
|
689 |
'type' => '2text',
|
690 |
'class' => 'fm-2text',
|
691 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' px|%, top|bottom|left|right|center',
|
692 |
'value1' => isset($param_values->GPBGPosition1) ? $param_values->GPBGPosition1 : '',
|
693 |
'value2' => isset($param_values->GPBGPosition2) ? $param_values->GPBGPosition2 : '',
|
694 |
'before1' => '',
|
696 |
'after' => '',
|
697 |
),
|
698 |
array(
|
699 |
+
'label' => __('Background Size', WDFMInstance(self::PLUGIN)->prefix),
|
700 |
'name1' => 'GPBGSize1',
|
701 |
'name2' => 'GPBGSize2',
|
702 |
'type' => '2text',
|
703 |
'class' => 'fm-2text',
|
704 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' px|%, auto|cover|contain',
|
705 |
'value1' => isset($param_values->GPBGSize1) ? $param_values->GPBGSize1 : '',
|
706 |
'value2' => isset($param_values->GPBGSize2) ? $param_values->GPBGSize2 : '',
|
707 |
'before1' => '',
|
709 |
'after' => '',
|
710 |
),
|
711 |
array(
|
712 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
713 |
'name' => 'GPColor',
|
714 |
'type' => 'text',
|
715 |
'class' => 'color',
|
717 |
'after' => '',
|
718 |
),
|
719 |
array(
|
720 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
721 |
'name' => 'GPPadding',
|
722 |
'type' => 'text',
|
723 |
'class' => '',
|
724 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 3px 5px or 3% 5%',
|
725 |
'value' => isset($param_values->GPPadding) ? $param_values->GPPadding : '',
|
726 |
'after' => '',
|
727 |
),
|
728 |
array(
|
729 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
730 |
'name' => 'GPMargin',
|
731 |
'type' => 'text',
|
732 |
'class' => '',
|
733 |
'value' => isset($param_values->GPMargin) ? $param_values->GPMargin : '',
|
734 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
735 |
'after' => '',
|
736 |
),
|
737 |
array(
|
738 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
739 |
'name' => 'GPBorder',
|
740 |
'type' => 'checkbox',
|
741 |
'options' => $borders,
|
743 |
'after' => '',
|
744 |
),
|
745 |
array(
|
746 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
747 |
'name' => 'GPBorderColor',
|
748 |
'type' => 'text',
|
749 |
'class' => 'color',
|
751 |
'after' => '',
|
752 |
),
|
753 |
array(
|
754 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
755 |
'name' => 'GPBorderType',
|
756 |
'type' => 'select',
|
757 |
'options' => $border_types,
|
760 |
'after' => '',
|
761 |
),
|
762 |
array(
|
763 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
764 |
'name' => 'GPBorderWidth',
|
765 |
'type' => 'text',
|
766 |
'class' => '',
|
768 |
'after' => 'px',
|
769 |
),
|
770 |
array(
|
771 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
772 |
'name' => 'GPBorderRadius',
|
773 |
'type' => 'text',
|
774 |
'class' => '',
|
776 |
'after' => 'px</div>',
|
777 |
),
|
778 |
array(
|
779 |
+
'label' => __('Mini labels (name, phone, address, checkbox, radio) Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
780 |
'type' => 'panel',
|
781 |
'class' => 'col-md-12',
|
782 |
'label_class' => 'fm-mini-title',
|
783 |
'after' => '<br/>',
|
784 |
),
|
785 |
array(
|
786 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
787 |
'name' => 'GPMLFontSize',
|
788 |
'type' => 'text',
|
789 |
'class' => '',
|
791 |
'after' => 'px',
|
792 |
),
|
793 |
array(
|
794 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
795 |
'name' => 'GPMLFontWeight',
|
796 |
'type' => 'select',
|
797 |
'options' => $font_weights,
|
800 |
'after' => '',
|
801 |
),
|
802 |
array(
|
803 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
804 |
'name' => 'GPMLColor',
|
805 |
'type' => 'text',
|
806 |
'class' => 'color',
|
807 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
808 |
'value' => isset($param_values->GPMLColor) ? $param_values->GPMLColor : '',
|
809 |
'after' => '',
|
810 |
),
|
811 |
array(
|
812 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
813 |
'name' => 'GPMLPadding',
|
814 |
'type' => 'text',
|
815 |
'class' => '',
|
816 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 3px 5px or 3% 5%',
|
817 |
'value' => isset($param_values->GPMLPadding) ? $param_values->GPMLPadding : '',
|
818 |
'after' => '',
|
819 |
),
|
820 |
array(
|
821 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
822 |
'name' => 'GPMLMargin',
|
823 |
'type' => 'text',
|
824 |
'class' => '',
|
825 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
826 |
'value' => isset($param_values->GPMLMargin) ? $param_values->GPMLMargin : '',
|
827 |
'after' => '',
|
828 |
),
|
829 |
array(
|
830 |
+
'label' => __('Section Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
831 |
'type' => 'label',
|
832 |
'class' => 'fm-mini-title',
|
833 |
'after' => '<br/>',
|
834 |
),
|
835 |
array(
|
836 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
837 |
'name' => 'SEPBGColor',
|
838 |
'type' => 'text',
|
839 |
'class' => 'color',
|
840 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
841 |
'value' => isset($param_values->SEPBGColor) ? $param_values->SEPBGColor : '',
|
842 |
'after' => '',
|
843 |
),
|
844 |
array(
|
845 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
846 |
'name' => 'SEPPadding',
|
847 |
'type' => 'text',
|
848 |
'class' => '',
|
849 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 3px 5px or 3% 5%',
|
850 |
'value' => isset($param_values->SEPPadding) ? $param_values->SEPPadding : '',
|
851 |
'after' => '',
|
852 |
),
|
853 |
array(
|
854 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
855 |
'name' => 'SEPMargin',
|
856 |
'type' => 'text',
|
857 |
'class' => '',
|
858 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
859 |
'value' => isset($param_values->SEPMargin) ? $param_values->SEPMargin : '',
|
860 |
'after' => '',
|
861 |
),
|
862 |
array(
|
863 |
+
'label' => __('Section Column Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
864 |
'type' => 'label',
|
865 |
'class' => 'fm-mini-title',
|
866 |
'after' => '<br/>',
|
867 |
),
|
868 |
array(
|
869 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
870 |
'name' => 'COPPadding',
|
871 |
'type' => 'text',
|
872 |
'class' => '',
|
873 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 3px 5px or 3% 5%',
|
874 |
'value' => isset($param_values->COPPadding) ? $param_values->COPPadding : '',
|
875 |
'after' => '',
|
876 |
),
|
877 |
array(
|
878 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
879 |
'name' => 'COPMargin',
|
880 |
'type' => 'text',
|
881 |
'class' => '',
|
882 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
883 |
'value' => isset($param_values->COPMargin) ? $param_values->COPMargin : '',
|
884 |
'after' => '',
|
885 |
),
|
886 |
array(
|
887 |
+
'label' => __('Footer Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
888 |
'type' => 'label',
|
889 |
'class' => 'fm-mini-title',
|
890 |
'after' => '<br/>',
|
891 |
),
|
892 |
array(
|
893 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
894 |
'name' => 'FPWidth',
|
895 |
'type' => 'text',
|
896 |
'class' => '',
|
898 |
'after' => '%',
|
899 |
),
|
900 |
array(
|
901 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
902 |
'name' => 'FPPadding',
|
903 |
'type' => 'text',
|
904 |
'class' => '',
|
905 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 3px 5px or 3% 5%',
|
906 |
'value' => isset($param_values->FPPadding) ? $param_values->FPPadding : '',
|
907 |
'after' => '',
|
908 |
),
|
909 |
array(
|
910 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
911 |
'name' => 'FPMargin',
|
912 |
'type' => 'text',
|
913 |
'class' => '',
|
914 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
915 |
'value' => isset($param_values->FPMargin) ? $param_values->FPMargin : '',
|
916 |
'after' => '</div>',
|
917 |
),
|
925 |
'after' => '',
|
926 |
),
|
927 |
array(
|
928 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
929 |
'name' => 'IPHeight',
|
930 |
'type' => 'text',
|
931 |
'class' => '',
|
933 |
'after' => 'px',
|
934 |
),
|
935 |
array(
|
936 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
937 |
'name' => 'IPFontSize',
|
938 |
'type' => 'text',
|
939 |
'class' => '',
|
941 |
'after' => 'px',
|
942 |
),
|
943 |
array(
|
944 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
945 |
'name' => 'IPFontWeight',
|
946 |
'type' => 'select',
|
947 |
'options' => $font_weights,
|
950 |
'after' => '',
|
951 |
),
|
952 |
array(
|
953 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
954 |
'name' => 'IPBGColor',
|
955 |
'type' => 'text',
|
956 |
'class' => 'color',
|
957 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
958 |
'value' => isset($param_values->IPBGColor) ? $param_values->IPBGColor : '',
|
959 |
'after' => '',
|
960 |
),
|
961 |
array(
|
962 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
963 |
'name' => 'IPColor',
|
964 |
'type' => 'text',
|
965 |
'class' => 'color',
|
966 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
967 |
'value' => isset($param_values->IPColor) ? $param_values->IPColor : '',
|
968 |
'after' => '',
|
969 |
),
|
970 |
array(
|
971 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
972 |
'name' => 'IPPadding',
|
973 |
'type' => 'text',
|
974 |
'class' => '',
|
975 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 3px 5px or 3% 5%',
|
976 |
'value' => isset($param_values->IPPadding) ? $param_values->IPPadding : '',
|
977 |
'after' => '',
|
978 |
),
|
979 |
array(
|
980 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
981 |
'name' => 'IPMargin',
|
982 |
'type' => 'text',
|
983 |
'class' => '',
|
984 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
985 |
'value' => isset($param_values->IPMargin) ? $param_values->IPMargin : '',
|
986 |
'after' => '',
|
987 |
),
|
988 |
array(
|
989 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
990 |
'name' => 'IPBorder',
|
991 |
'type' => 'checkbox',
|
992 |
'options' => $borders,
|
994 |
'after' => '',
|
995 |
),
|
996 |
array(
|
997 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
998 |
'name' => 'IPBorderColor',
|
999 |
'type' => 'text',
|
1000 |
'class' => 'color',
|
1001 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
1002 |
'value' => isset($param_values->IPBorderColor) ? $param_values->IPBorderColor : '',
|
1003 |
'after' => '',
|
1004 |
),
|
1005 |
array(
|
1006 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1007 |
'name' => 'IPBorderType',
|
1008 |
'type' => 'select',
|
1009 |
'options' => $border_types,
|
1012 |
'after' => '',
|
1013 |
),
|
1014 |
array(
|
1015 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
1016 |
'name' => 'IPBorderWidth',
|
1017 |
'type' => 'text',
|
1018 |
'class' => '',
|
1020 |
'after' => 'px',
|
1021 |
),
|
1022 |
array(
|
1023 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
1024 |
'name' => 'IPBorderRadius',
|
1025 |
'type' => 'text',
|
1026 |
'class' => '',
|
1028 |
'after' => 'px',
|
1029 |
),
|
1030 |
array(
|
1031 |
+
'label' => __('Box Shadow', WDFMInstance(self::PLUGIN)->prefix),
|
1032 |
'name' => 'IPBoxShadow',
|
1033 |
'type' => 'text',
|
1034 |
'class' => '',
|
1035 |
'value' => isset($param_values->IPBoxShadow) ? $param_values->IPBoxShadow : '',
|
1036 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 5px 2px #888888',
|
1037 |
'after' => '</div>',
|
1038 |
),
|
1039 |
array(
|
1040 |
+
'label' => __('Dropdown additional', WDFMInstance(self::PLUGIN)->prefix),
|
1041 |
'type' => 'panel',
|
1042 |
'class' => 'col-md-12',
|
1043 |
'label_class' => 'fm-mini-title',
|
1044 |
'after' => '<br/>',
|
1045 |
),
|
1046 |
array(
|
1047 |
+
'label' => __('Appearance', WDFMInstance(self::PLUGIN)->prefix),
|
1048 |
'name' => 'SBPAppearance',
|
1049 |
'type' => 'text',
|
1050 |
'class' => '',
|
1051 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' normal, icon, window, button, menu, field',
|
1052 |
'value' => isset($param_values->SBPAppearance) ? $param_values->SBPAppearance : '',
|
1053 |
'after' => '',
|
1054 |
),
|
1055 |
array(
|
1056 |
+
'label' => __('Background URL', WDFMInstance(self::PLUGIN)->prefix),
|
1057 |
'name' => 'SBPBackground',
|
1058 |
'type' => 'text',
|
1059 |
'class' => '',
|
1060 |
+
// 'placeholder' => __('e.g. http:// or https://', WDFMInstance(self::PLUGIN)->prefix),
|
1061 |
'value' => isset($param_values->SBPBackground) ? $param_values->SBPBackground : '',
|
1062 |
'after' => '',
|
1063 |
),
|
1064 |
array(
|
1065 |
+
'label' => __('Background Repeat', WDFMInstance(self::PLUGIN)->prefix),
|
1066 |
'name' => 'SBPBGRepeat',
|
1067 |
'type' => 'select',
|
1068 |
'options' => $bg_repeats,
|
1079 |
),
|
1080 |
'choices' => array(
|
1081 |
array(
|
1082 |
+
'label' => __('Single Choice', WDFMInstance(self::PLUGIN)->prefix),
|
1083 |
'type' => 'panel',
|
1084 |
'class' => 'col-md-12',
|
1085 |
'label_class' => 'fm-mini-title',
|
1086 |
'after' => '<br/>',
|
1087 |
),
|
1088 |
array(
|
1089 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1090 |
'name' => 'SCPBGColor',
|
1091 |
'type' => 'text',
|
1092 |
'class' => 'color',
|
1093 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
1094 |
'value' => isset($param_values->SCPBGColor) ? $param_values->SCPBGColor : '',
|
1095 |
'after' => '',
|
1096 |
),
|
1097 |
array(
|
1098 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
1099 |
'name' => 'SCPWidth',
|
1100 |
'type' => 'text',
|
1101 |
'class' => '',
|
1103 |
'after' => 'px',
|
1104 |
),
|
1105 |
array(
|
1106 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
1107 |
'name' => 'SCPHeight',
|
1108 |
'type' => 'text',
|
1109 |
'class' => '',
|
1111 |
'after' => 'px',
|
1112 |
),
|
1113 |
array(
|
1114 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
1115 |
'name' => 'SCPMargin',
|
1116 |
'type' => 'text',
|
1117 |
'class' => '5px',
|
1118 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
1119 |
'value' => isset($param_values->SCPMargin) ? $param_values->SCPMargin : '',
|
1120 |
'after' => '',
|
1121 |
),
|
1122 |
array(
|
1123 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
1124 |
'name' => 'SCPBorder',
|
1125 |
'type' => 'checkbox',
|
1126 |
'options' => $borders,
|
1128 |
'after' => '',
|
1129 |
),
|
1130 |
array(
|
1131 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
1132 |
'name' => 'SCPBorderColor',
|
1133 |
'type' => 'text',
|
1134 |
'class' => 'color',
|
1135 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
1136 |
'value' => isset($param_values->SCPBorderColor) ? $param_values->SCPBorderColor : '',
|
1137 |
'after' => '',
|
1138 |
),
|
1139 |
array(
|
1140 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1141 |
'name' => 'SCPBorderType',
|
1142 |
'type' => 'select',
|
1143 |
'options' => $border_types,
|
1146 |
'after' => '',
|
1147 |
),
|
1148 |
array(
|
1149 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
1150 |
'name' => 'SCPBorderWidth',
|
1151 |
'type' => 'text',
|
1152 |
'class' => '',
|
1154 |
'after' => 'px',
|
1155 |
),
|
1156 |
array(
|
1157 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
1158 |
'name' => 'SCPBorderRadius',
|
1159 |
'type' => 'text',
|
1160 |
'class' => '',
|
1162 |
'after' => 'px',
|
1163 |
),
|
1164 |
array(
|
1165 |
+
'label' => __('Box Shadow', WDFMInstance(self::PLUGIN)->prefix),
|
1166 |
'name' => 'SCPBoxShadow',
|
1167 |
'type' => 'text',
|
1168 |
'class' => '',
|
1169 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 5px 2px #888888',
|
1170 |
'value' => isset($param_values->SCPBoxShadow) ? $param_values->SCPBoxShadow : '',
|
1171 |
'after' => '',
|
1172 |
),
|
1173 |
array(
|
1174 |
+
'label' => __('Checked Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
1175 |
'type' => 'label',
|
1176 |
'class' => 'fm-mini-title',
|
1177 |
'after' => '<br/>',
|
1178 |
),
|
1179 |
array(
|
1180 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1181 |
'name' => 'SCCPBGColor',
|
1182 |
'type' => 'text',
|
1183 |
'class' => 'color',
|
1184 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
1185 |
'value' => isset($param_values->SCCPBGColor) ? $param_values->SCCPBGColor : '',
|
1186 |
'after' => '',
|
1187 |
),
|
1188 |
array(
|
1189 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
1190 |
'name' => 'SCCPWidth',
|
1191 |
'type' => 'text',
|
1192 |
'class' => '',
|
1194 |
'after' => 'px',
|
1195 |
),
|
1196 |
array(
|
1197 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
1198 |
'name' => 'SCCPHeight',
|
1199 |
'type' => 'text',
|
1200 |
'class' => '',
|
1202 |
'after' => 'px',
|
1203 |
),
|
1204 |
array(
|
1205 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
1206 |
'name' => 'SCCPMargin',
|
1207 |
'type' => 'text',
|
1208 |
'class' => '',
|
1209 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
1210 |
'value' => isset($param_values->SCCPMargin) ? $param_values->SCCPMargin : '',
|
1211 |
'after' => '',
|
1212 |
),
|
1213 |
array(
|
1214 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
1215 |
'name' => 'SCCPBorderRadius',
|
1216 |
'type' => 'text',
|
1217 |
'class' => '',
|
1219 |
'after' => 'px</div>',
|
1220 |
),
|
1221 |
array(
|
1222 |
+
'label' => __('Multiple Choice', WDFMInstance(self::PLUGIN)->prefix),
|
1223 |
'type' => 'panel',
|
1224 |
'class' => 'col-md-12',
|
1225 |
'label_class' => 'fm-mini-title',
|
1226 |
'after' => '<br/>',
|
1227 |
),
|
1228 |
array(
|
1229 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1230 |
'name' => 'MCPBGColor',
|
1231 |
'type' => 'text',
|
1232 |
'class' => 'color',
|
1233 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
1234 |
'value' => isset($param_values->MCPBGColor) ? $param_values->MCPBGColor : '',
|
1235 |
'after' => '',
|
1236 |
),
|
1237 |
array(
|
1238 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
1239 |
'name' => 'MCPWidth',
|
1240 |
'type' => 'text',
|
1241 |
'class' => '',
|
1243 |
'after' => 'px',
|
1244 |
),
|
1245 |
array(
|
1246 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
1247 |
'name' => 'MCPHeight',
|
1248 |
'type' => 'text',
|
1249 |
'class' => '',
|
1251 |
'after' => 'px',
|
1252 |
),
|
1253 |
array(
|
1254 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
1255 |
'name' => 'MCPMargin',
|
1256 |
'type' => 'text',
|
1257 |
'class' => '5px',
|
1258 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 10px or 5% 10%',
|
1259 |
'value' => isset($param_values->MCPMargin) ? $param_values->MCPMargin : '',
|
1260 |
'after' => '',
|
1261 |
),
|
1262 |
array(
|
1263 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
1264 |
'name' => 'MCPBorder',
|
1265 |
'type' => 'checkbox',
|
1266 |
'options' => $borders,
|
1268 |
'after' => '',
|
1269 |
),
|
1270 |
array(
|
1271 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
1272 |
'name' => 'MCPBorderColor',
|
1273 |
'type' => 'text',
|
1274 |
'class' => 'color',
|
1275 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' #efefef',
|
1276 |
'value' => isset($param_values->MCPBorderColor) ? $param_values->MCPBorderColor : '',
|
1277 |
'after' => '',
|
1278 |
),
|
1279 |
array(
|
1280 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1281 |
'name' => 'MCPBorderType',
|
1282 |
'type' => 'select',
|
1283 |
'options' => $border_types,
|
1286 |
'after' => '',
|
1287 |
),
|
1288 |
array(
|
1289 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
1290 |
'name' => 'MCPBorderWidth',
|
1291 |
'type' => 'text',
|
1292 |
'class' => '',
|
1295 |
),
|
1296 |
|
1297 |
array(
|
1298 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
1299 |
'name' => 'MCPBorderRadius',
|
1300 |
'type' => 'text',
|
1301 |
'class' => '',
|
1303 |
'after' => 'px',
|
1304 |
),
|
1305 |
array(
|
1306 |
+
'label' => __('Box Shadow', WDFMInstance(self::PLUGIN)->prefix),
|
1307 |
'name' => 'MCPBoxShadow',
|
1308 |
'type' => 'text',
|
1309 |
'class' => '',
|
1310 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .' 5px 5px 2px #888888',
|
1311 |
'value' => isset($param_values->MCPBoxShadow) ? $param_values->MCPBoxShadow : '',
|
1312 |
'after' => '',
|
1313 |
),
|
1314 |
array(
|
1315 |
+
'label' => __('Checked Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
1316 |
'type' => 'label',
|
1317 |
'class' => 'fm-mini-title',
|
1318 |
'after' => '<br/>',
|
1319 |
),
|
1320 |
array(
|
1321 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1322 |
'name' => 'MCCPBGColor',
|
1323 |
'type' => 'text',
|
1324 |
'class' => 'color',
|
1325 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) .'#efefef',
|
1326 |
'value' => isset($param_values->MCCPBGColor) ? $param_values->MCCPBGColor : '',
|
1327 |
'after' => '',
|
1328 |
),
|
1329 |
array(
|
1330 |
+
'label' => __('Background URL', WDFMInstance(self::PLUGIN)->prefix),
|
1331 |
'name' => 'MCCPBackground',
|
1332 |
'type' => 'text',
|
1333 |
'class' => '',
|
1334 |
+
// 'placeholder' => __('e.g. http:// or https://', WDFMInstance(self::PLUGIN)->prefix),
|
1335 |
'value' => isset($param_values->MCCPBackground) ? $param_values->MCCPBackground : '',
|
1336 |
'after' => '',
|
1337 |
),
|
1338 |
array(
|
1339 |
+
'label' => __('Background Repeat', WDFMInstance(self::PLUGIN)->prefix),
|
1340 |
'name' => 'MCCPBGRepeat',
|
1341 |
'type' => 'select',
|
1342 |
'options' => $bg_repeats,
|
1345 |
'after' => '',
|
1346 |
),
|
1347 |
array(
|
1348 |
+
'label' => __('Background Position', WDFMInstance(self::PLUGIN)->prefix),
|
1349 |
'name1' => 'MCCPBGPos1',
|
1350 |
'name2' => 'MCCPBGPos2',
|
1351 |
'type' => '2text',
|
1352 |
'class' => 'fm-2text',
|
1353 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' px|%, top|bottom|left|right|center',
|
1354 |
'value1' => isset($param_values->MCCPBGPos1) ? $param_values->MCCPBGPos1 : '',
|
1355 |
'value2' => isset($param_values->MCCPBGPos2) ? $param_values->MCCPBGPos2 : '',
|
1356 |
'before1' => '',
|
1358 |
'after' => '',
|
1359 |
),
|
1360 |
array(
|
1361 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
1362 |
'name' => 'MCCPWidth',
|
1363 |
'type' => 'text',
|
1364 |
'class' => '',
|
1366 |
'after' => 'px',
|
1367 |
),
|
1368 |
array(
|
1369 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
1370 |
'name' => 'MCCPHeight',
|
1371 |
'type' => 'text',
|
1372 |
'class' => '',
|
1374 |
'after' => 'px',
|
1375 |
),
|
1376 |
array(
|
1377 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
1378 |
'name' => 'MCCPMargin',
|
1379 |
'type' => 'text',
|
1380 |
'class' => '',
|
1381 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10px or 5% 10%',
|
1382 |
'value' => isset($param_values->MCCPMargin) ? $param_values->MCCPMargin : '',
|
1383 |
'after' => '',
|
1384 |
),
|
1385 |
array(
|
1386 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
1387 |
'name' => 'MCCPBorderRadius',
|
1388 |
'type' => 'text',
|
1389 |
'class' => '',
|
1393 |
),
|
1394 |
'subscribe' => array(
|
1395 |
array(
|
1396 |
+
'label' => __('Global Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
1397 |
'type' => 'panel',
|
1398 |
'class' => 'col-md-12',
|
1399 |
'label_class' => 'fm-mini-title',
|
1400 |
'after' => '<br/>',
|
1401 |
),
|
1402 |
array(
|
1403 |
+
'label' => __('Alignment', WDFMInstance(self::PLUGIN)->prefix),
|
1404 |
'name' => 'SPAlign',
|
1405 |
'type' => 'select',
|
1406 |
'options' => $aligns,
|
1409 |
'after' => '</div>',
|
1410 |
),
|
1411 |
array(
|
1412 |
+
'label' => __('Submit', WDFMInstance(self::PLUGIN)->prefix),
|
1413 |
'type' => 'panel',
|
1414 |
'class' => 'col-md-12',
|
1415 |
'label_class' => 'fm-mini-title',
|
1416 |
'after' => '<br/>',
|
1417 |
),
|
1418 |
array(
|
1419 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1420 |
'name' => 'SPBGColor',
|
1421 |
'type' => 'text',
|
1422 |
'class' => 'color',
|
1423 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1424 |
'value' => isset($param_values->SPBGColor) ? $param_values->SPBGColor : '',
|
1425 |
'after' => '',
|
1426 |
),
|
1427 |
array(
|
1428 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
1429 |
'name' => 'SPWidth',
|
1430 |
'type' => 'text',
|
1431 |
'class' => '',
|
1433 |
'after' => 'px',
|
1434 |
),
|
1435 |
array(
|
1436 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
1437 |
'name' => 'SPHeight',
|
1438 |
'type' => 'text',
|
1439 |
'class' => '',
|
1441 |
'after' => 'px',
|
1442 |
),
|
1443 |
array(
|
1444 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
1445 |
'name' => 'SPFontSize',
|
1446 |
'type' => 'text',
|
1447 |
'class' => '',
|
1449 |
'after' => 'px',
|
1450 |
),
|
1451 |
array(
|
1452 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
1453 |
'name' => 'SPFontWeight',
|
1454 |
'type' => 'select',
|
1455 |
'options' => $font_weights,
|
1458 |
'after' => '',
|
1459 |
),
|
1460 |
array(
|
1461 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
1462 |
'name' => 'SPColor',
|
1463 |
'type' => 'text',
|
1464 |
'class' => 'color',
|
1465 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1466 |
'value' => isset($param_values->SPColor) ? $param_values->SPColor : '',
|
1467 |
'after' => '',
|
1468 |
),
|
1469 |
array(
|
1470 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
1471 |
'name' => 'SPPadding',
|
1472 |
'type' => 'text',
|
1473 |
'class' => '',
|
1474 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 3px 5px or 3% 5%',
|
1475 |
'value' => isset($param_values->SPPadding) ? $param_values->SPPadding : '',
|
1476 |
'after' => '',
|
1477 |
),
|
1478 |
array(
|
1479 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
1480 |
'name' => 'SPMargin',
|
1481 |
'type' => 'text',
|
1482 |
'class' => '',
|
1483 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10px or 5% 10%',
|
1484 |
'value' => isset($param_values->SPMargin) ? $param_values->SPMargin : '',
|
1485 |
'after' => '',
|
1486 |
),
|
1487 |
array(
|
1488 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
1489 |
'name' => 'SPBorder',
|
1490 |
'type' => 'checkbox',
|
1491 |
'options' => $borders,
|
1493 |
'after' => '',
|
1494 |
),
|
1495 |
array(
|
1496 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
1497 |
'name' => 'SPBorderColor',
|
1498 |
'type' => 'text',
|
1499 |
'class' => 'color',
|
1500 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1501 |
'value' => isset($param_values->SPBorderColor) ? $param_values->SPBorderColor : '',
|
1502 |
'after' => '',
|
1503 |
),
|
1504 |
array(
|
1505 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1506 |
'name' => 'SPBorderType',
|
1507 |
'type' => 'select',
|
1508 |
'options' => $border_types,
|
1511 |
'after' => '',
|
1512 |
),
|
1513 |
array(
|
1514 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
1515 |
'name' => 'SPBorderWidth',
|
1516 |
'type' => 'text',
|
1517 |
'class' => '',
|
1519 |
'after' => 'px',
|
1520 |
),
|
1521 |
array(
|
1522 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
1523 |
'name' => 'SPBorderRadius',
|
1524 |
'type' => 'text',
|
1525 |
'class' => '',
|
1527 |
'after' => 'px',
|
1528 |
),
|
1529 |
array(
|
1530 |
+
'label' => __('Box Shadow', WDFMInstance(self::PLUGIN)->prefix),
|
1531 |
'name' => 'SPBoxShadow',
|
1532 |
'type' => 'text',
|
1533 |
'class' => '',
|
1534 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 5px 2px #888888',
|
1535 |
'value' => isset($param_values->SPBoxShadow) ? $param_values->SPBoxShadow : '',
|
1536 |
'after' => '',
|
1537 |
),
|
1538 |
array(
|
1539 |
+
'label' => __('Hover Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
1540 |
'type' => 'label',
|
1541 |
'class' => 'fm-mini-title',
|
1542 |
'after' => '<br/>',
|
1543 |
),
|
1544 |
array(
|
1545 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1546 |
'name' => 'SHPBGColor',
|
1547 |
'type' => 'text',
|
1548 |
'class' => 'color',
|
1549 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1550 |
'value' => isset($param_values->SHPBGColor) ? $param_values->SHPBGColor : '',
|
1551 |
'after' => '',
|
1552 |
),
|
1553 |
array(
|
1554 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
1555 |
'name' => 'SHPColor',
|
1556 |
'type' => 'text',
|
1557 |
'class' => 'color',
|
1558 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1559 |
'value' => isset($param_values->SHPColor) ? $param_values->SHPColor : '',
|
1560 |
'after' => '',
|
1561 |
),
|
1562 |
array(
|
1563 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
1564 |
'name' => 'SHPBorder',
|
1565 |
'type' => 'checkbox',
|
1566 |
'options' => $borders,
|
1568 |
'after' => '',
|
1569 |
),
|
1570 |
array(
|
1571 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
1572 |
'name' => 'SHPBorderColor',
|
1573 |
'type' => 'text',
|
1574 |
'class' => 'color',
|
1575 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1576 |
'value' => isset($param_values->SHPBorderColor) ? $param_values->SHPBorderColor : '',
|
1577 |
'after' => '',
|
1578 |
),
|
1579 |
array(
|
1580 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1581 |
'name' => 'SHPBorderType',
|
1582 |
'type' => 'select',
|
1583 |
'options' => $border_types,
|
1586 |
'after' => '',
|
1587 |
),
|
1588 |
array(
|
1589 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
1590 |
'name' => 'SHPBorderWidth',
|
1591 |
'type' => 'text',
|
1592 |
'class' => '',
|
1594 |
'after' => 'px</div>',
|
1595 |
),
|
1596 |
array(
|
1597 |
+
'label' => __('Reset', WDFMInstance(self::PLUGIN)->prefix),
|
1598 |
'type' => 'panel',
|
1599 |
'class' => 'col-md-12',
|
1600 |
'label_class' => 'fm-mini-title',
|
1601 |
'after' => '<br/>',
|
1602 |
),
|
1603 |
array(
|
1604 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1605 |
'name' => 'BPBGColor',
|
1606 |
'type' => 'text',
|
1607 |
'class' => 'color',
|
1608 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1609 |
'value' => isset($param_values->BPBGColor) ? $param_values->BPBGColor : '',
|
1610 |
'after' => '',
|
1611 |
),
|
1612 |
array(
|
1613 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
1614 |
'name' => 'BPWidth',
|
1615 |
'type' => 'text',
|
1616 |
'class' => '',
|
1618 |
'after' => 'px',
|
1619 |
),
|
1620 |
array(
|
1621 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
1622 |
'name' => 'BPHeight',
|
1623 |
'type' => 'text',
|
1624 |
'class' => '',
|
1626 |
'after' => 'px',
|
1627 |
),
|
1628 |
array(
|
1629 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
1630 |
'name' => 'BPFontSize',
|
1631 |
'type' => 'text',
|
1632 |
'class' => '',
|
1634 |
'after' => 'px',
|
1635 |
),
|
1636 |
array(
|
1637 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
1638 |
'name' => 'BPFontWeight',
|
1639 |
'type' => 'select',
|
1640 |
'options' => $font_weights,
|
1643 |
'after' => '',
|
1644 |
),
|
1645 |
array(
|
1646 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
1647 |
'name' => 'BPColor',
|
1648 |
'type' => 'text',
|
1649 |
'class' => 'color',
|
1650 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1651 |
'value' => isset($param_values->BPColor) ? $param_values->BPColor : '',
|
1652 |
'after' => '',
|
1653 |
),
|
1654 |
array(
|
1655 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
1656 |
'name' => 'BPPadding',
|
1657 |
'type' => 'text',
|
1658 |
'class' => '',
|
1659 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 3px 5xp or 3% 5%',
|
1660 |
'value' => isset($param_values->BPPadding) ? $param_values->BPPadding : '',
|
1661 |
'after' => '',
|
1662 |
),
|
1663 |
array(
|
1664 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
1665 |
'name' => 'BPMargin',
|
1666 |
'type' => 'text',
|
1667 |
'class' => '',
|
1668 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10xp or 5% 10%',
|
1669 |
'value' => isset($param_values->BPMargin) ? $param_values->BPMargin : '',
|
1670 |
'after' => '',
|
1671 |
),
|
1672 |
array(
|
1673 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
1674 |
'name' => 'BPBorder',
|
1675 |
'type' => 'checkbox',
|
1676 |
'options' => $borders,
|
1678 |
'after' => '',
|
1679 |
),
|
1680 |
array(
|
1681 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
1682 |
'name' => 'BPBorderColor',
|
1683 |
'type' => 'text',
|
1684 |
'class' => 'color',
|
1685 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1686 |
'value' => isset($param_values->BPBorderColor) ? $param_values->BPBorderColor : '',
|
1687 |
'after' => '',
|
1688 |
),
|
1689 |
array(
|
1690 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1691 |
'name' => 'BPBorderType',
|
1692 |
'type' => 'select',
|
1693 |
'options' => $border_types,
|
1696 |
'after' => '',
|
1697 |
),
|
1698 |
array(
|
1699 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
1700 |
'name' => 'BPBorderWidth',
|
1701 |
'type' => 'text',
|
1702 |
'class' => '',
|
1704 |
'after' => 'px',
|
1705 |
),
|
1706 |
array(
|
1707 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
1708 |
'name' => 'BPBorderRadius',
|
1709 |
'type' => 'text',
|
1710 |
'class' => '',
|
1712 |
'after' => 'px',
|
1713 |
),
|
1714 |
array(
|
1715 |
+
'label' => __('Box Shadow', WDFMInstance(self::PLUGIN)->prefix),
|
1716 |
'name' => 'BPBoxShadow',
|
1717 |
'type' => 'text',
|
1718 |
'class' => '',
|
1719 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 5px 2px #888888',
|
1720 |
'value' => isset($param_values->BPBoxShadow) ? $param_values->BPBoxShadow : '',
|
1721 |
'after' => '',
|
1722 |
),
|
1723 |
array(
|
1724 |
+
'label' => __('Hover Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
1725 |
'type' => 'label',
|
1726 |
'class' => 'fm-mini-title',
|
1727 |
'after' => '<br/>',
|
1728 |
),
|
1729 |
array(
|
1730 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1731 |
'name' => 'BHPBGColor',
|
1732 |
'type' => 'text',
|
1733 |
'class' => 'color',
|
1734 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1735 |
'value' => isset($param_values->BHPBGColor) ? $param_values->BHPBGColor : '',
|
1736 |
'after' => '',
|
1737 |
),
|
1738 |
array(
|
1739 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
1740 |
'name' => 'BHPColor',
|
1741 |
'type' => 'text',
|
1742 |
'class' => 'color',
|
1743 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1744 |
'value' => isset($param_values->BHPColor) ? $param_values->BHPColor : '',
|
1745 |
'after' => '',
|
1746 |
),
|
1747 |
array(
|
1748 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
1749 |
'name' => 'BHPBorder',
|
1750 |
'type' => 'checkbox',
|
1751 |
'options' => $borders,
|
1753 |
'after' => '',
|
1754 |
),
|
1755 |
array(
|
1756 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
1757 |
'name' => 'BHPBorderColor',
|
1758 |
'type' => 'text',
|
1759 |
'class' => 'color',
|
1760 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1761 |
'value' => isset($param_values->BHPBorderColor) ? $param_values->BHPBorderColor : '',
|
1762 |
'after' => '',
|
1763 |
),
|
1764 |
array(
|
1765 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1766 |
'name' => 'BHPBorderType',
|
1767 |
'type' => 'select',
|
1768 |
'options' => $border_types,
|
1771 |
'after' => '',
|
1772 |
),
|
1773 |
array(
|
1774 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
1775 |
'name' => 'BHPBorderWidth',
|
1776 |
'type' => 'text',
|
1777 |
'class' => '',
|
1781 |
),
|
1782 |
'paigination' => array(
|
1783 |
array(
|
1784 |
+
'label' => __('Active', WDFMInstance(self::PLUGIN)->prefix),
|
1785 |
'type' => 'panel',
|
1786 |
'class' => 'col-md-12',
|
1787 |
'label_class' => 'fm-mini-title',
|
1788 |
'after' => '',
|
1789 |
),
|
1790 |
array(
|
1791 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1792 |
'name' => 'PSAPBGColor',
|
1793 |
'type' => 'text',
|
1794 |
'class' => 'color',
|
1795 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1796 |
'value' => isset($param_values->PSAPBGColor) ? $param_values->PSAPBGColor : '',
|
1797 |
'after' => '',
|
1798 |
),
|
1799 |
array(
|
1800 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
1801 |
'name' => 'PSAPFontSize',
|
1802 |
'type' => 'text',
|
1803 |
'class' => '',
|
1805 |
'after' => 'px',
|
1806 |
),
|
1807 |
array(
|
1808 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
1809 |
'name' => 'PSAPFontWeight',
|
1810 |
'type' => 'select',
|
1811 |
'options' => $font_weights,
|
1814 |
'after' => '',
|
1815 |
),
|
1816 |
array(
|
1817 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
1818 |
'name' => 'PSAPColor',
|
1819 |
'type' => 'text',
|
1820 |
'class' => 'color',
|
1821 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1822 |
'value' => isset($param_values->PSAPColor) ? $param_values->PSAPColor : '',
|
1823 |
'after' => '',
|
1824 |
),
|
1825 |
array(
|
1826 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
1827 |
'name' => 'PSAPHeight',
|
1828 |
'type' => 'text',
|
1829 |
'class' => '',
|
1831 |
'after' => 'px',
|
1832 |
),
|
1833 |
array(
|
1834 |
+
'label' => __('Line Height', WDFMInstance(self::PLUGIN)->prefix),
|
1835 |
'name' => 'PSAPLineHeight',
|
1836 |
'type' => 'text',
|
1837 |
'class' => '',
|
1839 |
'after' => 'px',
|
1840 |
),
|
1841 |
array(
|
1842 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
1843 |
'name' => 'PSAPPadding',
|
1844 |
'type' => 'text',
|
1845 |
'class' => '',
|
1846 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 3px 5px or 3% 5%',
|
1847 |
'value' => isset($param_values->PSAPPadding) ? $param_values->PSAPPadding : '',
|
1848 |
'after' => '',
|
1849 |
),
|
1850 |
array(
|
1851 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
1852 |
'name' => 'PSAPMargin',
|
1853 |
'type' => 'text',
|
1854 |
'class' => '',
|
1855 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10px or 5% 10%',
|
1856 |
'value' => isset($param_values->PSAPMargin) ? $param_values->PSAPMargin : '',
|
1857 |
'after' => '',
|
1858 |
),
|
1859 |
array(
|
1860 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
1861 |
'name' => 'PSAPBorder',
|
1862 |
'type' => 'checkbox',
|
1863 |
'options' => $borders,
|
1865 |
'after' => '',
|
1866 |
),
|
1867 |
array(
|
1868 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
1869 |
'name' => 'PSAPBorderColor',
|
1870 |
'type' => 'text',
|
1871 |
'class' => 'color',
|
1872 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1873 |
'value' => isset($param_values->PSAPBorderColor) ? $param_values->PSAPBorderColor : '',
|
1874 |
'after' => '',
|
1875 |
),
|
1876 |
array(
|
1877 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1878 |
'name' => 'PSAPBorderType',
|
1879 |
'type' => 'select',
|
1880 |
'options' => $border_types,
|
1883 |
'after' => '',
|
1884 |
),
|
1885 |
array(
|
1886 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
1887 |
'name' => 'PSAPBorderWidth',
|
1888 |
'type' => 'text',
|
1889 |
'class' => '',
|
1891 |
'after' => 'px',
|
1892 |
),
|
1893 |
array(
|
1894 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
1895 |
'name' => 'PSAPBorderRadius',
|
1896 |
'type' => 'text',
|
1897 |
'class' => '',
|
1899 |
'after' => 'px</div>',
|
1900 |
),
|
1901 |
array(
|
1902 |
+
'label' => __('Inactive', WDFMInstance(self::PLUGIN)->prefix),
|
1903 |
'type' => 'panel',
|
1904 |
'class' => 'col-md-12',
|
1905 |
'label_class' => 'fm-mini-title',
|
1906 |
'after' => '',
|
1907 |
),
|
1908 |
array(
|
1909 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
1910 |
'name' => 'PSDPBGColor',
|
1911 |
'type' => 'text',
|
1912 |
'class' => 'color',
|
1913 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1914 |
'value' => isset($param_values->PSDPBGColor) ? $param_values->PSDPBGColor : '',
|
1915 |
'after' => '',
|
1916 |
),
|
1917 |
array(
|
1918 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
1919 |
'name' => 'PSDPFontSize',
|
1920 |
'type' => 'text',
|
1921 |
'class' => '',
|
1923 |
'after' => 'px',
|
1924 |
),
|
1925 |
array(
|
1926 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
1927 |
'name' => 'PSDPFontWeight',
|
1928 |
'type' => 'select',
|
1929 |
'options' => $font_weights,
|
1932 |
'after' => '',
|
1933 |
),
|
1934 |
array(
|
1935 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
1936 |
'name' => 'PSDPColor',
|
1937 |
'type' => 'text',
|
1938 |
'class' => 'color',
|
1939 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1940 |
'value' => isset($param_values->PSDPColor) ? $param_values->PSDPColor : '',
|
1941 |
'after' => '',
|
1942 |
),
|
1943 |
array(
|
1944 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
1945 |
'name' => 'PSDPHeight',
|
1946 |
'type' => 'text',
|
1947 |
'class' => '',
|
1949 |
'after' => 'px',
|
1950 |
),
|
1951 |
array(
|
1952 |
+
'label' => __('Line Height', WDFMInstance(self::PLUGIN)->prefix),
|
1953 |
'name' => 'PSDPLineHeight',
|
1954 |
'type' => 'text',
|
1955 |
'class' => '',
|
1957 |
'after' => 'px',
|
1958 |
),
|
1959 |
array(
|
1960 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
1961 |
'name' => 'PSDPPadding',
|
1962 |
'type' => 'text',
|
1963 |
'class' => '',
|
1964 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 3px 5px or 3% 5%',
|
1965 |
'value' => isset($param_values->PSDPPadding) ? $param_values->PSDPPadding : '',
|
1966 |
'after' => '',
|
1967 |
),
|
1968 |
array(
|
1969 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
1970 |
'name' => 'PSDPMargin',
|
1971 |
'type' => 'text',
|
1972 |
'class' => '',
|
1973 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10px or 5% 10%',
|
1974 |
'value' => isset($param_values->PSDPMargin) ? $param_values->PSDPMargin : '',
|
1975 |
'after' => '',
|
1976 |
),
|
1977 |
array(
|
1978 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
1979 |
'name' => 'PSDPBorder',
|
1980 |
'type' => 'checkbox',
|
1981 |
'options' => $borders,
|
1983 |
'after' => '',
|
1984 |
),
|
1985 |
array(
|
1986 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
1987 |
'name' => 'PSDPBorderColor',
|
1988 |
'type' => 'text',
|
1989 |
'class' => 'color',
|
1990 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
1991 |
'value' => isset($param_values->PSDPBorderColor) ? $param_values->PSDPBorderColor : '',
|
1992 |
'after' => '',
|
1993 |
),
|
1994 |
array(
|
1995 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
1996 |
'name' => 'PSDPBorderType',
|
1997 |
'type' => 'select',
|
1998 |
'options' => $border_types,
|
2001 |
'after' => '',
|
2002 |
),
|
2003 |
array(
|
2004 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2005 |
'name' => 'PSDPBorderWidth',
|
2006 |
'type' => 'text',
|
2007 |
'class' => '',
|
2009 |
'after' => 'px',
|
2010 |
),
|
2011 |
array(
|
2012 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
2013 |
'name' => 'PSDPBorderRadius',
|
2014 |
'type' => 'text',
|
2015 |
'class' => '',
|
2017 |
'after' => 'px</div>',
|
2018 |
),
|
2019 |
array(
|
2020 |
+
'label' => __('Steps', WDFMInstance(self::PLUGIN)->prefix),
|
2021 |
'type' => 'panel',
|
2022 |
'class' => 'col-md-12',
|
2023 |
'label_class' => 'fm-mini-title',
|
2024 |
'after' => '',
|
2025 |
),
|
2026 |
array(
|
2027 |
+
'label' => __('Alignment', WDFMInstance(self::PLUGIN)->prefix),
|
2028 |
'name' => 'PSAPAlign',
|
2029 |
'type' => 'select',
|
2030 |
'options' => $aligns,
|
2033 |
'after' => '',
|
2034 |
),
|
2035 |
array(
|
2036 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
2037 |
'name' => 'PSAPWidth',
|
2038 |
'type' => 'text',
|
2039 |
'class' => '',
|
2041 |
'after' => 'px</div>',
|
2042 |
),
|
2043 |
array(
|
2044 |
+
'label' => __('Percentage', WDFMInstance(self::PLUGIN)->prefix),
|
2045 |
'type' => 'panel',
|
2046 |
'class' => 'col-md-12',
|
2047 |
'label_class' => 'fm-mini-title',
|
2048 |
'after' => '',
|
2049 |
),
|
2050 |
array(
|
2051 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
2052 |
'name' => 'PPAPWidth',
|
2053 |
'type' => 'text',
|
2054 |
'class' => '',
|
2055 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 500px or 50%',
|
2056 |
'value' => isset($param_values->PPAPWidth) ? $param_values->PPAPWidth : '',
|
2057 |
'after' => '</div>',
|
2058 |
),
|
2059 |
),
|
2060 |
'buttons' => array(
|
2061 |
array(
|
2062 |
+
'label' => __('Global Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
2063 |
'type' => 'panel',
|
2064 |
'class' => 'col-md-12',
|
2065 |
'label_class' => 'fm-mini-title',
|
2066 |
'after' => '<br/>',
|
2067 |
),
|
2068 |
array(
|
2069 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
2070 |
'name' => 'BPFontSize',
|
2071 |
'type' => 'text',
|
2072 |
'class' => '',
|
2074 |
'after' => 'px',
|
2075 |
),
|
2076 |
array(
|
2077 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
2078 |
'name' => 'BPFontWeight',
|
2079 |
'type' => 'select',
|
2080 |
'options' => $font_weights,
|
2083 |
'after' => '</div>',
|
2084 |
),
|
2085 |
array(
|
2086 |
+
'label' => __('Next Button Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
2087 |
'type' => 'panel',
|
2088 |
'class' => 'col-md-12',
|
2089 |
'label_class' => 'fm-mini-title',
|
2090 |
'after' => '<br/>',
|
2091 |
),
|
2092 |
array(
|
2093 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
2094 |
'name' => 'NBPBGColor',
|
2095 |
'type' => 'text',
|
2096 |
'class' => 'color',
|
2097 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2098 |
'value' => isset($param_values->NBPBGColor) ? $param_values->NBPBGColor : '',
|
2099 |
'after' => '',
|
2100 |
),
|
2101 |
array(
|
2102 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
2103 |
'name' => 'NBPWidth',
|
2104 |
'type' => 'text',
|
2105 |
'class' => '',
|
2107 |
'after' => 'px',
|
2108 |
),
|
2109 |
array(
|
2110 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
2111 |
'name' => 'NBPHeight',
|
2112 |
'type' => 'text',
|
2113 |
'class' => '',
|
2115 |
'after' => 'px',
|
2116 |
),
|
2117 |
array(
|
2118 |
+
'label' => __('Line Height', WDFMInstance(self::PLUGIN)->prefix),
|
2119 |
'name' => 'NBPLineHeight',
|
2120 |
'type' => 'text',
|
2121 |
'class' => '',
|
2123 |
'after' => 'px',
|
2124 |
),
|
2125 |
array(
|
2126 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2127 |
'name' => 'NBPColor',
|
2128 |
'type' => 'text',
|
2129 |
'class' => 'color',
|
2130 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2131 |
'value' => isset($param_values->NBPColor) ? $param_values->NBPColor : '',
|
2132 |
'after' => '',
|
2133 |
),
|
2134 |
array(
|
2135 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
2136 |
'name' => 'NBPPadding',
|
2137 |
'type' => 'text',
|
2138 |
'class' => '',
|
2139 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 3px 5px or 3% 5%',
|
2140 |
'value' => isset($param_values->NBPPadding) ? $param_values->NBPPadding : '',
|
2141 |
'after' => '',
|
2142 |
),
|
2143 |
array(
|
2144 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
2145 |
'name' => 'NBPMargin',
|
2146 |
'type' => 'text',
|
2147 |
'class' => '',
|
2148 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10px or 5% 10%',
|
2149 |
'value' => isset($param_values->NBPMargin) ? $param_values->NBPMargin : '',
|
2150 |
'after' => '',
|
2151 |
),
|
2152 |
array(
|
2153 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
2154 |
'name' => 'NBPBorder',
|
2155 |
'type' => 'checkbox',
|
2156 |
'options' => $borders,
|
2158 |
'after' => '',
|
2159 |
),
|
2160 |
array(
|
2161 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
2162 |
'name' => 'NBPBorderColor',
|
2163 |
'type' => 'text',
|
2164 |
'class' => 'color',
|
2165 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2166 |
'value' => isset($param_values->NBPBorderColor) ? $param_values->NBPBorderColor : '',
|
2167 |
'after' => '',
|
2168 |
),
|
2169 |
array(
|
2170 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
2171 |
'name' => 'NBPBorderType',
|
2172 |
'type' => 'select',
|
2173 |
'options' => $border_types,
|
2176 |
'after' => '',
|
2177 |
),
|
2178 |
array(
|
2179 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2180 |
'name' => 'NBPBorderWidth',
|
2181 |
'type' => 'text',
|
2182 |
'class' => '',
|
2184 |
'after' => 'px',
|
2185 |
),
|
2186 |
array(
|
2187 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
2188 |
'name' => 'NBPBorderRadius',
|
2189 |
'type' => 'text',
|
2190 |
'class' => '',
|
2192 |
'after' => 'px',
|
2193 |
),
|
2194 |
array(
|
2195 |
+
'label' => __('Box Shadow', WDFMInstance(self::PLUGIN)->prefix),
|
2196 |
'name' => 'NBPBoxShadow',
|
2197 |
'type' => 'text',
|
2198 |
'class' => '',
|
2199 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 5px 2px #888888',
|
2200 |
'value' => isset($param_values->NBPBoxShadow) ? $param_values->NBPBoxShadow : '',
|
2201 |
'after' => '',
|
2202 |
),
|
2203 |
array(
|
2204 |
+
'label' => __('Hover Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
2205 |
'type' => 'label',
|
2206 |
'class' => 'fm-mini-title',
|
2207 |
'after' => '<br/>',
|
2208 |
),
|
2209 |
array(
|
2210 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
2211 |
'name' => 'NBHPBGColor',
|
2212 |
'type' => 'text',
|
2213 |
'class' => 'color',
|
2214 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2215 |
'value' => isset($param_values->NBHPBGColor) ? $param_values->NBHPBGColor : '',
|
2216 |
'after' => '',
|
2217 |
),
|
2218 |
array(
|
2219 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2220 |
'name' => 'NBHPColor',
|
2221 |
'type' => 'text',
|
2222 |
'class' => 'color',
|
2223 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2224 |
'value' => isset($param_values->NBHPColor) ? $param_values->NBHPColor : '',
|
2225 |
'after' => '',
|
2226 |
),
|
2227 |
array(
|
2228 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
2229 |
'name' => 'NBHPBorder',
|
2230 |
'type' => 'checkbox',
|
2231 |
'options' => $borders,
|
2233 |
'after' => '',
|
2234 |
),
|
2235 |
array(
|
2236 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
2237 |
'name' => 'NBHPBorderColor',
|
2238 |
'type' => 'text',
|
2239 |
'class' => 'color',
|
2240 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2241 |
'value' => isset($param_values->NBHPBorderColor) ? $param_values->NBHPBorderColor : '',
|
2242 |
'after' => '',
|
2243 |
),
|
2244 |
array(
|
2245 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
2246 |
'name' => 'NBHPBorderType',
|
2247 |
'type' => 'select',
|
2248 |
'options' => $border_types,
|
2251 |
'after' => '',
|
2252 |
),
|
2253 |
array(
|
2254 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2255 |
'name' => 'NBHPBorderWidth',
|
2256 |
'type' => 'text',
|
2257 |
'class' => '',
|
2259 |
'after' => 'px</div>',
|
2260 |
),
|
2261 |
array(
|
2262 |
+
'label' => __('Previous Button Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
2263 |
'type' => 'panel',
|
2264 |
'class' => 'col-md-12',
|
2265 |
'label_class' => 'fm-mini-title',
|
2266 |
'after' => '<br/>',
|
2267 |
),
|
2268 |
array(
|
2269 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
2270 |
'name' => 'PBPBGColor',
|
2271 |
'type' => 'text',
|
2272 |
'class' => 'color',
|
2273 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2274 |
'value' => isset($param_values->PBPBGColor) ? $param_values->PBPBGColor : '',
|
2275 |
'after' => '',
|
2276 |
),
|
2277 |
array(
|
2278 |
+
'label' => __('Width', WDFMInstance(self::PLUGIN)->prefix),
|
2279 |
'name' => 'PBPWidth',
|
2280 |
'type' => 'text',
|
2281 |
'class' => '',
|
2283 |
'after' => 'px',
|
2284 |
),
|
2285 |
array(
|
2286 |
+
'label' => __('Height', WDFMInstance(self::PLUGIN)->prefix),
|
2287 |
'name' => 'PBPHeight',
|
2288 |
'type' => 'text',
|
2289 |
'class' => '',
|
2291 |
'after' => 'px',
|
2292 |
),
|
2293 |
array(
|
2294 |
+
'label' => __('Line Height', WDFMInstance(self::PLUGIN)->prefix),
|
2295 |
'name' => 'PBPLineHeight',
|
2296 |
'type' => 'text',
|
2297 |
'class' => '',
|
2299 |
'after' => 'px',
|
2300 |
),
|
2301 |
array(
|
2302 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2303 |
'name' => 'PBPColor',
|
2304 |
'type' => 'text',
|
2305 |
'class' => 'color',
|
2306 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2307 |
'value' => isset($param_values->PBPColor) ? $param_values->PBPColor : '',
|
2308 |
'after' => '',
|
2309 |
),
|
2310 |
array(
|
2311 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
2312 |
'name' => 'PBPPadding',
|
2313 |
'type' => 'text',
|
2314 |
'class' => '',
|
2315 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 3px 5px or 3% 5%',
|
2316 |
'value' => isset($param_values->PBPPadding) ? $param_values->PBPPadding : '',
|
2317 |
'after' => '',
|
2318 |
),
|
2319 |
array(
|
2320 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
2321 |
'name' => 'PBPMargin',
|
2322 |
'type' => 'text',
|
2323 |
'class' => '',
|
2324 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10px or 5% 10%',
|
2325 |
'value' => isset($param_values->PBPMargin) ? $param_values->PBPMargin : '',
|
2326 |
'after' => '',
|
2327 |
),
|
2328 |
array(
|
2329 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
2330 |
'name' => 'PBPBorder',
|
2331 |
'type' => 'checkbox',
|
2332 |
'options' => $borders,
|
2334 |
'after' => '',
|
2335 |
),
|
2336 |
array(
|
2337 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
2338 |
'name' => 'PBPBorderColor',
|
2339 |
'type' => 'text',
|
2340 |
'class' => 'color',
|
2341 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2342 |
'value' => isset($param_values->PBPBorderColor) ? $param_values->PBPBorderColor : '',
|
2343 |
'after' => '',
|
2344 |
),
|
2345 |
array(
|
2346 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
2347 |
'name' => 'PBPBorderType',
|
2348 |
'type' => 'select',
|
2349 |
'options' => $border_types,
|
2352 |
'after' => '',
|
2353 |
),
|
2354 |
array(
|
2355 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2356 |
'name' => 'PBPBorderWidth',
|
2357 |
'type' => 'text',
|
2358 |
'class' => '',
|
2360 |
'after' => 'px',
|
2361 |
),
|
2362 |
array(
|
2363 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
2364 |
'name' => 'PBPBorderRadius',
|
2365 |
'type' => 'text',
|
2366 |
'class' => '',
|
2368 |
'after' => 'px',
|
2369 |
),
|
2370 |
array(
|
2371 |
+
'label' => __('Box Shadow', WDFMInstance(self::PLUGIN)->prefix),
|
2372 |
'name' => 'PBPBoxShadow',
|
2373 |
'type' => 'text',
|
2374 |
'class' => '',
|
2375 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 5px 2px #888888',
|
2376 |
'value' => isset($param_values->PBPBoxShadow) ? $param_values->PBPBoxShadow : '',
|
2377 |
'after' => '',
|
2378 |
),
|
2379 |
array(
|
2380 |
+
'label' => __('Hover Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
2381 |
'type' => 'label',
|
2382 |
'class' => 'fm-mini-title',
|
2383 |
'after' => '<br/>',
|
2384 |
),
|
2385 |
array(
|
2386 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
2387 |
'name' => 'PBHPBGColor',
|
2388 |
'type' => 'text',
|
2389 |
'class' => 'color',
|
2390 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2391 |
'value' => isset($param_values->PBHPBGColor) ? $param_values->PBHPBGColor : '',
|
2392 |
'after' => '',
|
2393 |
),
|
2394 |
array(
|
2395 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2396 |
'name' => 'PBHPColor',
|
2397 |
'type' => 'text',
|
2398 |
'class' => 'color',
|
2399 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2400 |
'value' => isset($param_values->PBHPColor) ? $param_values->PBHPColor : '',
|
2401 |
'after' => '',
|
2402 |
),
|
2403 |
array(
|
2404 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
2405 |
'name' => 'PBHPBorder',
|
2406 |
'type' => 'checkbox',
|
2407 |
'options' => $borders,
|
2409 |
'after' => '',
|
2410 |
),
|
2411 |
array(
|
2412 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
2413 |
'name' => 'PBHPBorderColor',
|
2414 |
'type' => 'text',
|
2415 |
'class' => 'color',
|
2416 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2417 |
'value' => isset($param_values->PBHPBorderColor) ? $param_values->PBHPBorderColor : '',
|
2418 |
'after' => '',
|
2419 |
),
|
2420 |
array(
|
2421 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
2422 |
'name' => 'PBHPBorderType',
|
2423 |
'type' => 'select',
|
2424 |
'options' => $border_types,
|
2427 |
'after' => '',
|
2428 |
),
|
2429 |
array(
|
2430 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2431 |
'name' => 'PBHPBorderWidth',
|
2432 |
'type' => 'text',
|
2433 |
'class' => '',
|
2444 |
'after' => '',
|
2445 |
),
|
2446 |
array(
|
2447 |
+
'label' => __('Position', WDFMInstance(self::PLUGIN)->prefix),
|
2448 |
'name' => 'CBPPosition',
|
2449 |
'type' => 'select',
|
2450 |
'options' => $position_types,
|
2453 |
'after' => '',
|
2454 |
),
|
2455 |
array(
|
2456 |
+
'label' => __('Top', WDFMInstance(self::PLUGIN)->prefix),
|
2457 |
'name' => 'CBPTop',
|
2458 |
'type' => 'text',
|
2459 |
'class' => '',
|
2460 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 100px or 10%',
|
2461 |
'value' => isset($param_values->CBPTop) ? $param_values->CBPTop : '',
|
2462 |
'after' => '',
|
2463 |
),
|
2464 |
array(
|
2465 |
+
'label' => __('Right', WDFMInstance(self::PLUGIN)->prefix),
|
2466 |
'name' => 'CBPRight',
|
2467 |
'type' => 'text',
|
2468 |
'class' => '',
|
2469 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 100px or 10%',
|
2470 |
'value' => isset($param_values->CBPRight) ? $param_values->CBPRight : '',
|
2471 |
'after' => '',
|
2472 |
),
|
2473 |
array(
|
2474 |
+
'label' => __('Bottom', WDFMInstance(self::PLUGIN)->prefix),
|
2475 |
'name' => 'CBPBottom',
|
2476 |
'type' => 'text',
|
2477 |
'class' => '',
|
2478 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 100px or 10%',
|
2479 |
'value' => isset($param_values->CBPBottom) ? $param_values->CBPBottom : '',
|
2480 |
'after' => '',
|
2481 |
),
|
2482 |
array(
|
2483 |
+
'label' => __('Left', WDFMInstance(self::PLUGIN)->prefix),
|
2484 |
'name' => 'CBPLeft',
|
2485 |
'type' => 'text',
|
2486 |
'class' => '',
|
2487 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 100px or 10%',
|
2488 |
'value' => isset($param_values->CBPLeft) ? $param_values->CBPLeft : '',
|
2489 |
'after' => '',
|
2490 |
),
|
2491 |
array(
|
2492 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
2493 |
'name' => 'CBPBGColor',
|
2494 |
'type' => 'text',
|
2495 |
'class' => 'color',
|
2496 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2497 |
'value' => isset($param_values->CBPBGColor) ? $param_values->CBPBGColor : '',
|
2498 |
'after' => '',
|
2499 |
),
|
2500 |
array(
|
2501 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
2502 |
'name' => 'CBPFontSize',
|
2503 |
'type' => 'text',
|
2504 |
'class' => '13',
|
2506 |
'after' => 'px',
|
2507 |
),
|
2508 |
array(
|
2509 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
2510 |
'name' => 'CBPFontWeight',
|
2511 |
'type' => 'select',
|
2512 |
'options' => $font_weights,
|
2515 |
'after' => '',
|
2516 |
),
|
2517 |
array(
|
2518 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2519 |
'name' => 'CBPColor',
|
2520 |
'type' => 'text',
|
2521 |
'class' => 'color',
|
2522 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2523 |
'value' => isset($param_values->CBPColor) ? $param_values->CBPColor : '',
|
2524 |
'after' => '',
|
2525 |
),
|
2526 |
array(
|
2527 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
2528 |
'name' => 'CBPPadding',
|
2529 |
'type' => 'text',
|
2530 |
'class' => '',
|
2531 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 3px 5px or 3% 5%',
|
2532 |
'value' => isset($param_values->CBPPadding) ? $param_values->CBPPadding : '',
|
2533 |
'after' => '',
|
2534 |
),
|
2535 |
array(
|
2536 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
2537 |
'name' => 'CBPMargin',
|
2538 |
'type' => 'text',
|
2539 |
'class' => '',
|
2540 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10px or 5% 10%',
|
2541 |
'value' => isset($param_values->CBPMargin) ? $param_values->CBPMargin : '',
|
2542 |
'after' => '',
|
2543 |
),
|
2544 |
array(
|
2545 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
2546 |
'name' => 'CBPBorder',
|
2547 |
'type' => 'checkbox',
|
2548 |
'options' => $borders,
|
2550 |
'after' => '',
|
2551 |
),
|
2552 |
array(
|
2553 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
2554 |
'name' => 'CBPBorderColor',
|
2555 |
'type' => 'text',
|
2556 |
'class' => 'color',
|
2557 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2558 |
'value' => isset($param_values->CBPBorderColor) ? $param_values->CBPBorderColor : '',
|
2559 |
'after' => '',
|
2560 |
),
|
2561 |
array(
|
2562 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
2563 |
'name' => 'CBPBorderType',
|
2564 |
'type' => 'select',
|
2565 |
'options' => $border_types,
|
2568 |
'after' => '',
|
2569 |
),
|
2570 |
array(
|
2571 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2572 |
'name' => 'CBPBorderWidth',
|
2573 |
'type' => 'text',
|
2574 |
'class' => '',
|
2576 |
'after' => 'px',
|
2577 |
),
|
2578 |
array(
|
2579 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
2580 |
'name' => 'CBPBorderRadius',
|
2581 |
'type' => 'text',
|
2582 |
'class' => '',
|
2584 |
'after' => 'px',
|
2585 |
),
|
2586 |
array(
|
2587 |
+
'label' => __('Hover Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
2588 |
'type' => 'label',
|
2589 |
'class' => 'fm-mini-title',
|
2590 |
'after' => '<br/>',
|
2591 |
),
|
2592 |
array(
|
2593 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
2594 |
'name' => 'CBHPBGColor',
|
2595 |
'type' => 'text',
|
2596 |
'class' => 'color',
|
2597 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2598 |
'value' => isset($param_values->CBHPBGColor) ? $param_values->CBHPBGColor : '',
|
2599 |
'after' => '',
|
2600 |
),
|
2601 |
array(
|
2602 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2603 |
'name' => 'CBHPColor',
|
2604 |
'type' => 'text',
|
2605 |
'class' => 'color',
|
2606 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2607 |
'value' => isset($param_values->CBHPColor) ? $param_values->CBHPColor : '',
|
2608 |
'after' => '',
|
2609 |
),
|
2610 |
array(
|
2611 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
2612 |
'name' => 'CBHPBorder',
|
2613 |
'type' => 'checkbox',
|
2614 |
'options' => $borders,
|
2616 |
'after' => '',
|
2617 |
),
|
2618 |
array(
|
2619 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
2620 |
'name' => 'CBHPBorderColor',
|
2621 |
'type' => 'text',
|
2622 |
'class' => 'color',
|
2623 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2624 |
'value' => isset($param_values->CBHPBorderColor) ? $param_values->CBHPBorderColor : '',
|
2625 |
'after' => '',
|
2626 |
),
|
2627 |
array(
|
2628 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
2629 |
'name' => 'CBHPBorderType',
|
2630 |
'type' => 'select',
|
2631 |
'options' => $border_types,
|
2634 |
'after' => '',
|
2635 |
),
|
2636 |
array(
|
2637 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2638 |
'name' => 'CBHPBorderWidth',
|
2639 |
'type' => 'text',
|
2640 |
'class' => '',
|
2651 |
'after' => '',
|
2652 |
),
|
2653 |
array(
|
2654 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
2655 |
'name' => 'MBPBGColor',
|
2656 |
'type' => 'text',
|
2657 |
'class' => 'color',
|
2658 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2659 |
'value' => isset($param_values->MBPBGColor) ? $param_values->MBPBGColor : '',
|
2660 |
'after' => '',
|
2661 |
),
|
2662 |
array(
|
2663 |
+
'label' => __('Font Size', WDFMInstance(self::PLUGIN)->prefix),
|
2664 |
'name' => 'MBPFontSize',
|
2665 |
'type' => 'text',
|
2666 |
'class' => '13',
|
2668 |
'after' => 'px',
|
2669 |
),
|
2670 |
array(
|
2671 |
+
'label' => __('Font Weight', WDFMInstance(self::PLUGIN)->prefix),
|
2672 |
'name' => 'MBPFontWeight',
|
2673 |
'type' => 'select',
|
2674 |
'options' => $font_weights,
|
2677 |
'after' => '',
|
2678 |
),
|
2679 |
array(
|
2680 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2681 |
'name' => 'MBPColor',
|
2682 |
'type' => 'text',
|
2683 |
'class' => 'color',
|
2684 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2685 |
'value' => isset($param_values->MBPColor) ? $param_values->MBPColor : '',
|
2686 |
'after' => '',
|
2687 |
),
|
2688 |
array(
|
2689 |
+
'label' => __('Text Align', WDFMInstance(self::PLUGIN)->prefix),
|
2690 |
'name' => 'MBPTextAlign',
|
2691 |
'type' => 'select',
|
2692 |
'options' => $aligns,
|
2695 |
'after' => '',
|
2696 |
),
|
2697 |
array(
|
2698 |
+
'label' => __('Padding', WDFMInstance(self::PLUGIN)->prefix),
|
2699 |
'name' => 'MBPPadding',
|
2700 |
'type' => 'text',
|
2701 |
'class' => '',
|
2702 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 3px 5px or 3% 5%',
|
2703 |
'value' => isset($param_values->MBPPadding) ? $param_values->MBPPadding : '',
|
2704 |
'after' => 'px|%',
|
2705 |
),
|
2706 |
array(
|
2707 |
+
'label' => __('Margin', WDFMInstance(self::PLUGIN)->prefix),
|
2708 |
'name' => 'MBPMargin',
|
2709 |
'type' => 'text',
|
2710 |
'class' => '',
|
2711 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' 5px 10px or 5% 10%',
|
2712 |
'value' => isset($param_values->MBPMargin) ? $param_values->MBPMargin : '',
|
2713 |
'after' => 'px|%',
|
2714 |
),
|
2715 |
array(
|
2716 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
2717 |
'name' => 'MBPBorder',
|
2718 |
'type' => 'checkbox',
|
2719 |
'options' => $borders,
|
2721 |
'after' => '',
|
2722 |
),
|
2723 |
array(
|
2724 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
2725 |
'name' => 'MBPBorderColor',
|
2726 |
'type' => 'text',
|
2727 |
'class' => 'color',
|
2728 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2729 |
'value' => isset($param_values->MBPBorderColor) ? $param_values->MBPBorderColor : '',
|
2730 |
'after' => '',
|
2731 |
),
|
2732 |
array(
|
2733 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
2734 |
'name' => 'MBPBorderType',
|
2735 |
'type' => 'select',
|
2736 |
'options' => $border_types,
|
2739 |
'after' => '',
|
2740 |
),
|
2741 |
array(
|
2742 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2743 |
'name' => 'MBPBorderWidth',
|
2744 |
'type' => 'text',
|
2745 |
'class' => '',
|
2747 |
'after' => 'px',
|
2748 |
),
|
2749 |
array(
|
2750 |
+
'label' => __('Border Radius', WDFMInstance(self::PLUGIN)->prefix),
|
2751 |
'name' => 'MBPBorderRadius',
|
2752 |
'type' => 'text',
|
2753 |
'class' => '',
|
2755 |
'after' => 'px',
|
2756 |
),
|
2757 |
array(
|
2758 |
+
'label' => __('Hover Parameters', WDFMInstance(self::PLUGIN)->prefix),
|
2759 |
'type' => 'label',
|
2760 |
'class' => 'fm-mini-title',
|
2761 |
'after' => '<br/>',
|
2762 |
),
|
2763 |
array(
|
2764 |
+
'label' => __('Background Color', WDFMInstance(self::PLUGIN)->prefix),
|
2765 |
'name' => 'MBHPBGColor',
|
2766 |
'type' => 'text',
|
2767 |
'class' => 'color',
|
2768 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2769 |
'value' => isset($param_values->MBHPBGColor) ? $param_values->MBHPBGColor : '',
|
2770 |
'after' => '',
|
2771 |
),
|
2772 |
array(
|
2773 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2774 |
'name' => 'MBHPColor',
|
2775 |
'type' => 'text',
|
2776 |
'class' => 'color',
|
2777 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2778 |
'value' => isset($param_values->MBHPColor) ? $param_values->MBHPColor : '',
|
2779 |
'after' => '',
|
2780 |
),
|
2781 |
array(
|
2782 |
+
'label' => __('Border', WDFMInstance(self::PLUGIN)->prefix),
|
2783 |
'name' => 'MBHPBorder',
|
2784 |
'type' => 'checkbox',
|
2785 |
'options' => $borders,
|
2787 |
'after' => '',
|
2788 |
),
|
2789 |
array(
|
2790 |
+
'label' => __('Border Color', WDFMInstance(self::PLUGIN)->prefix),
|
2791 |
'name' => 'MBHPBorderColor',
|
2792 |
'type' => 'text',
|
2793 |
'class' => 'color',
|
2795 |
'after' => '',
|
2796 |
),
|
2797 |
array(
|
2798 |
+
'label' => __('Border Type', WDFMInstance(self::PLUGIN)->prefix),
|
2799 |
'name' => 'MBHPBorderType',
|
2800 |
'type' => 'select',
|
2801 |
'options' => $border_types,
|
2804 |
'after' => '',
|
2805 |
),
|
2806 |
array(
|
2807 |
+
'label' => __('Border Width', WDFMInstance(self::PLUGIN)->prefix),
|
2808 |
'name' => 'MBHPBorderWidth',
|
2809 |
'type' => 'text',
|
2810 |
'class' => '',
|
2814 |
),
|
2815 |
'other' => array(
|
2816 |
array(
|
2817 |
+
'label' => __('Inactive Text', WDFMInstance(self::PLUGIN)->prefix),
|
2818 |
'type' => 'panel',
|
2819 |
'class' => 'col-md-12',
|
2820 |
'label_class' => 'fm-mini-title',
|
2821 |
'after' => '<br/>',
|
2822 |
),
|
2823 |
array(
|
2824 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2825 |
'name' => 'OPDeInputColor',
|
2826 |
'type' => 'text',
|
2827 |
'class' => 'color',
|
2828 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' #efefef',
|
2829 |
'value' => isset($param_values->OPDeInputColor) ? $param_values->OPDeInputColor : '',
|
2830 |
'after' => '',
|
2831 |
),
|
2832 |
array(
|
2833 |
+
'label' => __('Font Style', WDFMInstance(self::PLUGIN)->prefix),
|
2834 |
'name' => 'OPFontStyle',
|
2835 |
'type' => 'text',
|
2836 |
'class' => '',
|
2838 |
'after' => '',
|
2839 |
),
|
2840 |
array(
|
2841 |
+
'label' => __('Required', WDFMInstance(self::PLUGIN)->prefix),
|
2842 |
'type' => 'label',
|
2843 |
'class' => 'fm-mini-title',
|
2844 |
'after' => '<br/>',
|
2845 |
),
|
2846 |
array(
|
2847 |
+
'label' => __('Color', WDFMInstance(self::PLUGIN)->prefix),
|
2848 |
'name' => 'OPRColor',
|
2849 |
'type' => 'text',
|
2850 |
'class' => 'color',
|
2852 |
'after' => '',
|
2853 |
),
|
2854 |
array(
|
2855 |
+
'label' => __('File Upload', WDFMInstance(self::PLUGIN)->prefix),
|
2856 |
'type' => 'label',
|
2857 |
'class' => 'fm-mini-title',
|
2858 |
'after' => '<br/>',
|
2859 |
),
|
2860 |
array(
|
2861 |
+
'label' => __('Background URL', WDFMInstance(self::PLUGIN)->prefix),
|
2862 |
'name' => 'OPFBgUrl',
|
2863 |
'type' => 'text',
|
2864 |
'class' => '',
|
2865 |
+
// 'placeholder' => __('e.g. http:// or https://', WDFMInstance(self::PLUGIN)->prefix),
|
2866 |
'value' => isset($param_values->OPFBgUrl) ? $param_values->OPFBgUrl : '',
|
2867 |
'after' => '',
|
2868 |
),
|
2869 |
array(
|
2870 |
+
'label' => __('Background Repeat', WDFMInstance(self::PLUGIN)->prefix),
|
2871 |
'name' => 'OPFBGRepeat',
|
2872 |
'type' => 'select',
|
2873 |
'options' => $bg_repeats,
|
2876 |
'after' => '',
|
2877 |
),
|
2878 |
array(
|
2879 |
+
'label' => __('Background Position', WDFMInstance(self::PLUGIN)->prefix),
|
2880 |
'name1' => 'OPFPos1',
|
2881 |
'name2' => 'OPFPos2',
|
2882 |
'type' => '2text',
|
2883 |
'class' => 'fm-2text',
|
2884 |
+
'placeholder' => __('e.g.', WDFMInstance(self::PLUGIN)->prefix) . ' px|%, top|bottom|left|right|center',
|
2885 |
'value1' => isset($param_values->OPFPos1) ? $param_values->OPFPos1 : '',
|
2886 |
'value2' => isset($param_values->OPFPos2) ? $param_values->OPFPos2 : '',
|
2887 |
'before1' => '',
|
2889 |
'after' => '',
|
2890 |
),
|
2891 |
array(
|
2892 |
+
'label' => __('Grading', WDFMInstance(self::PLUGIN)->prefix),
|
2893 |
'type' => 'label',
|
2894 |
'class' => 'fm-mini-title',
|
2895 |
'after' => '<br/>',
|
2896 |
),
|
2897 |
array(
|
2898 |
+
'label' => __('Text Width', WDFMInstance(self::PLUGIN)->prefix),
|
2899 |
'name' => 'OPGWidth',
|
2900 |
'type' => 'text',
|
2901 |
'class' => '',
|
2912 |
'after' => '',
|
2913 |
),
|
2914 |
array(
|
2915 |
+
'label' => __('Custom CSS', WDFMInstance(self::PLUGIN)->prefix),
|
2916 |
'name' => 'CUPCSS',
|
2917 |
'type' => 'textarea',
|
2918 |
'class' => '',
|
2930 |
*/
|
2931 |
public function apply() {
|
2932 |
$data = $this->save_db();
|
2933 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
2934 |
+
$active_tab = WDW_FM_Library(self::PLUGIN)->get('active_tab');
|
2935 |
+
$pagination = WDW_FM_Library(self::PLUGIN)->get('pagination-type');
|
2936 |
+
$form_type = WDW_FM_Library(self::PLUGIN)->get('form_type');
|
2937 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
2938 |
'page' => $page,
|
2939 |
'task' => 'edit',
|
2940 |
'current_id' => $data['id'],
|
2952 |
*/
|
2953 |
public function save_db() {
|
2954 |
global $wpdb;
|
2955 |
+
$id = (int) WDW_FM_Library(self::PLUGIN)->get('current_id', 0);
|
2956 |
$title = (isset($_POST['title']) ? esc_html(stripslashes($_POST['title'])) : '');
|
2957 |
$version = 2;
|
2958 |
$params = (isset($_POST['params']) ? stripslashes(preg_replace("/(^[\r\n]*|[\r\n]+)[\s\t]*[\r\n]+/", "\n", $_POST['params'])) : '');
|
2975 |
$id = $wpdb->insert_id;
|
2976 |
}
|
2977 |
if ( $save !== FALSE ) {
|
2978 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/frontend/models/form_maker.php";
|
2979 |
$model_frontend = new FMModelForm_maker_fmc();
|
2980 |
$form_theme = json_decode(html_entity_decode($params), TRUE);
|
2981 |
$model_frontend->create_css($id, $form_theme, $version == 1, TRUE);
|
2982 |
+
|
2983 |
$msg = 1;
|
2984 |
}
|
2985 |
else {
|
2986 |
$msg = 2;
|
2987 |
}
|
2988 |
+
return array('id' => $id, 'msg' => $msg);
|
|
|
2989 |
}
|
2990 |
|
2991 |
/**
|
2993 |
*
|
2994 |
* @param $id
|
2995 |
*/
|
2996 |
+
public function setdefault( $id ) {
|
2997 |
+
$this->model->update_formmaker_themes( array( 'default' => 0 ), array( 'default' => 1 ) );
|
2998 |
+
$save = $this->model->update_formmaker_themes( array( 'default' => 1 ), array( 'id' => $id ) );
|
2999 |
+
if ( $save !== FALSE ) {
|
3000 |
+
$message = 7;
|
3001 |
+
}
|
3002 |
+
else {
|
3003 |
+
$message = 2;
|
3004 |
+
}
|
3005 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
3006 |
+
WDW_FM_Library(self::PLUGIN)->fm_redirect(add_query_arg(array(
|
3007 |
+
'page' => $page,
|
3008 |
+
'task' => 'display',
|
3009 |
+
'message' => $message,
|
3010 |
+
), admin_url('admin.php')));
|
3011 |
+
}
|
3012 |
}
|
admin/controllers/Uninstall_fm.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
class FMControllerUninstall_fmc {
|
4 |
private $model;
|
5 |
private $view;
|
6 |
private $addons = array(
|
@@ -18,19 +18,19 @@ class FMControllerUninstall_fmc {
|
|
18 |
);
|
19 |
|
20 |
public function __construct() {
|
21 |
-
require_once
|
22 |
$this->model = new FMModelUninstall_fmc();
|
23 |
-
require_once
|
24 |
$this->view = new FMViewUninstall_fmc();
|
25 |
|
26 |
-
if (
|
27 |
global $fm_options;
|
28 |
global $cfm_options;
|
29 |
if (!class_exists("DoradoWebConfig")) {
|
30 |
-
include_once(
|
31 |
}
|
32 |
$config = new DoradoWebConfig();
|
33 |
-
$config->set_options(
|
34 |
$deactivate_reasons = new DoradoWebDeactivate($config);
|
35 |
$deactivate_reasons->submit_and_deactivate();
|
36 |
}
|
@@ -39,7 +39,7 @@ class FMControllerUninstall_fmc {
|
|
39 |
public function execute() {
|
40 |
$task = ((isset($_POST['task'])) ? esc_html(stripslashes($_POST['task'])) : '');
|
41 |
if ( method_exists($this, $task) ) {
|
42 |
-
check_admin_referer(
|
43 |
$this->$task();
|
44 |
}
|
45 |
else {
|
@@ -60,7 +60,7 @@ class FMControllerUninstall_fmc {
|
|
60 |
$params['prefix'] = $wpdb->prefix;
|
61 |
$params['addons'] = $this->addons;
|
62 |
// Deactivate all addons
|
63 |
-
|
64 |
$this->view->uninstall($params);
|
65 |
}
|
66 |
}
|
1 |
<?php
|
2 |
|
3 |
+
class FMControllerUninstall_fmc extends CFMAdminController {
|
4 |
private $model;
|
5 |
private $view;
|
6 |
private $addons = array(
|
18 |
);
|
19 |
|
20 |
public function __construct() {
|
21 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/Uninstall_fm.php";
|
22 |
$this->model = new FMModelUninstall_fmc();
|
23 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Uninstall_fm.php";
|
24 |
$this->view = new FMViewUninstall_fmc();
|
25 |
|
26 |
+
if ( WDFMInstance(self::PLUGIN)->is_free ) {
|
27 |
global $fm_options;
|
28 |
global $cfm_options;
|
29 |
if (!class_exists("DoradoWebConfig")) {
|
30 |
+
include_once(WDFMInstance(self::PLUGIN)->plugin_dir . "/wd/config.php");
|
31 |
}
|
32 |
$config = new DoradoWebConfig();
|
33 |
+
$config->set_options(WDFMInstance(self::PLUGIN)->is_free == 1 ? $fm_options : $cfm_options);
|
34 |
$deactivate_reasons = new DoradoWebDeactivate($config);
|
35 |
$deactivate_reasons->submit_and_deactivate();
|
36 |
}
|
39 |
public function execute() {
|
40 |
$task = ((isset($_POST['task'])) ? esc_html(stripslashes($_POST['task'])) : '');
|
41 |
if ( method_exists($this, $task) ) {
|
42 |
+
check_admin_referer(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce);
|
43 |
$this->$task();
|
44 |
}
|
45 |
else {
|
60 |
$params['prefix'] = $wpdb->prefix;
|
61 |
$params['addons'] = $this->addons;
|
62 |
// Deactivate all addons
|
63 |
+
WDW_FM_Library(self::PLUGIN)->deactivate_all_addons();
|
64 |
$this->view->uninstall($params);
|
65 |
}
|
66 |
}
|
admin/controllers/Widget.php
CHANGED
@@ -4,32 +4,37 @@
|
|
4 |
* Class FMControllerWidget_fmc
|
5 |
*/
|
6 |
class FMControllerWidget_fmc extends WP_Widget {
|
|
|
|
|
|
|
|
|
|
|
7 |
private $view;
|
8 |
private $model;
|
9 |
|
10 |
public function __construct() {
|
11 |
$widget_ops = array(
|
12 |
'classname' => 'form_maker_widget',
|
13 |
-
'description' => __('Add
|
14 |
);
|
15 |
// Widget Control Settings.
|
16 |
$control_ops = array( 'id_base' => 'form_maker_widget' );
|
17 |
// Create the widget.
|
18 |
-
parent::__construct('form_maker_widget',
|
19 |
-
require_once
|
20 |
$this->model = new FMModelWidget_fmc();
|
21 |
-
require_once
|
22 |
$this->view = new FMViewWidget_fmc($this->model);
|
23 |
}
|
24 |
|
25 |
public function widget( $args, $instance ) {
|
26 |
-
if( get_the_title() == 'Preview' && get_post_type() == 'form-maker' .
|
27 |
return;
|
28 |
}
|
29 |
$contact_form_forms = explode(',', get_option('contact_form_forms'));
|
30 |
-
if ( !
|
31 |
-
if (
|
32 |
-
require_once(
|
33 |
$controller_class = 'FMControllerForm_maker';
|
34 |
}
|
35 |
else {
|
@@ -37,8 +42,8 @@ class FMControllerWidget_fmc extends WP_Widget {
|
|
37 |
}
|
38 |
}
|
39 |
else {
|
40 |
-
if (
|
41 |
-
require_once(
|
42 |
$controller_class = 'FMControllerForm_maker_fmc';
|
43 |
}
|
44 |
else {
|
4 |
* Class FMControllerWidget_fmc
|
5 |
*/
|
6 |
class FMControllerWidget_fmc extends WP_Widget {
|
7 |
+
/**
|
8 |
+
* PLUGIN = 2 points to Contact Form Maker
|
9 |
+
*/
|
10 |
+
const PLUGIN = 2;
|
11 |
+
|
12 |
private $view;
|
13 |
private $model;
|
14 |
|
15 |
public function __construct() {
|
16 |
$widget_ops = array(
|
17 |
'classname' => 'form_maker_widget',
|
18 |
+
'description' => sprintf(__('Add %s widget.', WDFMInstance(self::PLUGIN)->prefix), WDFMInstance(self::PLUGIN)->nicename),
|
19 |
);
|
20 |
// Widget Control Settings.
|
21 |
$control_ops = array( 'id_base' => 'form_maker_widget' );
|
22 |
// Create the widget.
|
23 |
+
parent::__construct('form_maker_widget', WDFMInstance(self::PLUGIN)->nicename, $widget_ops, $control_ops);
|
24 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/models/Widget.php";
|
25 |
$this->model = new FMModelWidget_fmc();
|
26 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/admin/views/Widget.php";
|
27 |
$this->view = new FMViewWidget_fmc($this->model);
|
28 |
}
|
29 |
|
30 |
public function widget( $args, $instance ) {
|
31 |
+
if( get_the_title() == 'Preview' && get_post_type() == 'form-maker' . WDFMInstance(self::PLUGIN)->plugin_postfix ) {
|
32 |
return;
|
33 |
}
|
34 |
$contact_form_forms = explode(',', get_option('contact_form_forms'));
|
35 |
+
if ( !WDFMInstance(self::PLUGIN)->is_free || !in_array($instance['form_id'], $contact_form_forms) ) {
|
36 |
+
if ( class_exists('WDFM') ) {
|
37 |
+
require_once(WDFMInstance(self::PLUGIN)->plugin_dir . '/frontend/controllers/form_maker.php');
|
38 |
$controller_class = 'FMControllerForm_maker';
|
39 |
}
|
40 |
else {
|
42 |
}
|
43 |
}
|
44 |
else {
|
45 |
+
if ( class_exists('WDCFM') ) {
|
46 |
+
require_once(WDFMInstance(2)->plugin_dir . '/frontend/controllers/form_maker.php');
|
47 |
$controller_class = 'FMControllerForm_maker_fmc';
|
48 |
}
|
49 |
else {
|
admin/controllers/controller.php
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Admin controller class.
|
4 |
+
*/
|
5 |
+
class CFMAdminController {
|
6 |
+
/**
|
7 |
+
* PLUGIN = 2 points to Contact Form Maker
|
8 |
+
*/
|
9 |
+
const PLUGIN = 2;
|
10 |
+
}
|
admin/models/Blocked_ips_fm.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelBlocked_ips_fmc
|
5 |
*/
|
6 |
-
class FMModelBlocked_ips_fmc {
|
7 |
/**
|
8 |
* Get blocked Ips.
|
9 |
*
|
@@ -15,8 +15,8 @@ class FMModelBlocked_ips_fmc {
|
|
15 |
$order = $params['order'];
|
16 |
$orderby = $params['orderby'];
|
17 |
$items_per_page = $params['items_per_page'];
|
18 |
-
$search =
|
19 |
-
$page = (int)
|
20 |
$limit = $page ? ($page - 1) * $items_per_page : 0;
|
21 |
|
22 |
global $wpdb;
|
@@ -54,7 +54,7 @@ class FMModelBlocked_ips_fmc {
|
|
54 |
global $wpdb;
|
55 |
$query = "SELECT COUNT(*) FROM `" . $wpdb->prefix . "formmaker_blocked`";
|
56 |
|
57 |
-
$search =
|
58 |
if ( $search ) {
|
59 |
$query .= ' WHERE `ip` LIKE "%' . $search . '%"';
|
60 |
}
|
3 |
/**
|
4 |
* Class FMModelBlocked_ips_fmc
|
5 |
*/
|
6 |
+
class FMModelBlocked_ips_fmc extends CFMAdminModel {
|
7 |
/**
|
8 |
* Get blocked Ips.
|
9 |
*
|
15 |
$order = $params['order'];
|
16 |
$orderby = $params['orderby'];
|
17 |
$items_per_page = $params['items_per_page'];
|
18 |
+
$search = WDW_FM_Library(self::PLUGIN)->get('s', '');
|
19 |
+
$page = (int) WDW_FM_Library(self::PLUGIN)->get('paged', 1);
|
20 |
$limit = $page ? ($page - 1) * $items_per_page : 0;
|
21 |
|
22 |
global $wpdb;
|
54 |
global $wpdb;
|
55 |
$query = "SELECT COUNT(*) FROM `" . $wpdb->prefix . "formmaker_blocked`";
|
56 |
|
57 |
+
$search = WDW_FM_Library(self::PLUGIN)->get('s', '');
|
58 |
if ( $search ) {
|
59 |
$query .= ' WHERE `ip` LIKE "%' . $search . '%"';
|
60 |
}
|
admin/models/Checkpaypal.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelCheckpaypal
|
5 |
*/
|
6 |
-
class FMModelCheckpaypal {
|
7 |
/**
|
8 |
* Get form by id.
|
9 |
*
|
3 |
/**
|
4 |
* Class FMModelCheckpaypal
|
5 |
*/
|
6 |
+
class FMModelCheckpaypal extends FMAdminModel {
|
7 |
/**
|
8 |
* Get form by id.
|
9 |
*
|
admin/models/FMPaypalInfo.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelPaypal_info
|
5 |
*/
|
6 |
-
class FMModelPaypal_info {
|
7 |
/**
|
8 |
* Get form session.
|
9 |
*
|
3 |
/**
|
4 |
* Class FMModelPaypal_info
|
5 |
*/
|
6 |
+
class FMModelPaypal_info extends FMAdminModel {
|
7 |
/**
|
8 |
* Get form session.
|
9 |
*
|
admin/models/FMSelectDataFromDb.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelSelect_data_from_db_fmc
|
5 |
*/
|
6 |
-
class FMModelSelect_data_from_db_fmc {
|
7 |
/**
|
8 |
* Get labels by form id.
|
9 |
*
|
@@ -32,10 +32,10 @@ class FMModelSelect_data_from_db_fmc {
|
|
32 |
}
|
33 |
else {
|
34 |
if ( $con_type == 'remote' ) {
|
35 |
-
$username =
|
36 |
-
$password =
|
37 |
-
$database =
|
38 |
-
$host =
|
39 |
$wpdb_temp = new wpdb($username, $password, $database, $host);
|
40 |
$query = "SHOW TABLES";
|
41 |
$tables = $wpdb_temp->get_col($query);
|
@@ -80,18 +80,18 @@ class FMModelSelect_data_from_db_fmc {
|
|
80 |
*/
|
81 |
function get_table_struct() {
|
82 |
global $wpdb;
|
83 |
-
$name =
|
84 |
if ( !$name ) {
|
85 |
return array();
|
86 |
}
|
87 |
-
$con_method =
|
88 |
-
$con_type =
|
89 |
$query = 'SHOW COLUMNS FROM `' . $name . '`';
|
90 |
if ( $con_type == 'remote' ) {
|
91 |
-
$username =
|
92 |
-
$password =
|
93 |
-
$database =
|
94 |
-
$host =
|
95 |
$wpdb_temp = new wpdb($username, $password, $database, $host);
|
96 |
$table_struct = $wpdb_temp->get_results($query);
|
97 |
}
|
3 |
/**
|
4 |
* Class FMModelSelect_data_from_db_fmc
|
5 |
*/
|
6 |
+
class FMModelSelect_data_from_db_fmc extends CFMAdminModel {
|
7 |
/**
|
8 |
* Get labels by form id.
|
9 |
*
|
32 |
}
|
33 |
else {
|
34 |
if ( $con_type == 'remote' ) {
|
35 |
+
$username = WDW_FM_Library(self::PLUGIN)->get('username', '');
|
36 |
+
$password = WDW_FM_Library(self::PLUGIN)->get('password', '');
|
37 |
+
$database = WDW_FM_Library(self::PLUGIN)->get('database', '');
|
38 |
+
$host = WDW_FM_Library(self::PLUGIN)->get('host', '');
|
39 |
$wpdb_temp = new wpdb($username, $password, $database, $host);
|
40 |
$query = "SHOW TABLES";
|
41 |
$tables = $wpdb_temp->get_col($query);
|
80 |
*/
|
81 |
function get_table_struct() {
|
82 |
global $wpdb;
|
83 |
+
$name = WDW_FM_Library(self::PLUGIN)->get('name', NULL);
|
84 |
if ( !$name ) {
|
85 |
return array();
|
86 |
}
|
87 |
+
$con_method = WDW_FM_Library(self::PLUGIN)->get('con_method', NULL);
|
88 |
+
$con_type = WDW_FM_Library(self::PLUGIN)->get('con_type', NULL);
|
89 |
$query = 'SHOW COLUMNS FROM `' . $name . '`';
|
90 |
if ( $con_type == 'remote' ) {
|
91 |
+
$username = WDW_FM_Library(self::PLUGIN)->get('username', '');
|
92 |
+
$password = WDW_FM_Library(self::PLUGIN)->get('password', '');
|
93 |
+
$database = WDW_FM_Library(self::PLUGIN)->get('database', '');
|
94 |
+
$host = WDW_FM_Library(self::PLUGIN)->get('host', '');
|
95 |
$wpdb_temp = new wpdb($username, $password, $database, $host);
|
96 |
$table_struct = $wpdb_temp->get_results($query);
|
97 |
}
|
admin/models/FMShortocde.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelFMShortocde_fmc
|
5 |
*/
|
6 |
-
class FMModelFMShortocde_fmc {
|
7 |
/**
|
8 |
* Get forms.
|
9 |
*
|
@@ -11,7 +11,8 @@ class FMModelFMShortocde_fmc {
|
|
11 |
*/
|
12 |
public function get_form_data() {
|
13 |
global $wpdb;
|
14 |
-
$rows = $wpdb->get_results("SELECT * FROM `" . $wpdb->prefix . "formmaker`" . (!
|
|
|
15 |
return $rows;
|
16 |
}
|
17 |
}
|
3 |
/**
|
4 |
* Class FMModelFMShortocde_fmc
|
5 |
*/
|
6 |
+
class FMModelFMShortocde_fmc extends CFMAdminModel {
|
7 |
/**
|
8 |
* Get forms.
|
9 |
*
|
11 |
*/
|
12 |
public function get_form_data() {
|
13 |
global $wpdb;
|
14 |
+
$rows = $wpdb->get_results("SELECT * FROM `" . $wpdb->prefix . "formmaker`" . (!WDFMInstance(self::PLUGIN)->is_free ? '' : ' WHERE id' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ') ORDER BY `title`'));
|
15 |
+
|
16 |
return $rows;
|
17 |
}
|
18 |
}
|
admin/models/FMSqlMapping.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelFormMakerSQLMapping_fmc
|
5 |
*/
|
6 |
-
class FMModelFormMakerSQLMapping_fmc {
|
7 |
/**
|
8 |
* Get query by id.
|
9 |
*
|
@@ -39,17 +39,17 @@ class FMModelFormMakerSQLMapping_fmc {
|
|
39 |
*/
|
40 |
function get_tables() {
|
41 |
global $wpdb;
|
42 |
-
$con_type =
|
43 |
if ( $con_type == 'local' ) {
|
44 |
$query = "SHOW TABLES";
|
45 |
$tables = $wpdb->get_col($query);
|
46 |
}
|
47 |
else {
|
48 |
if ( $con_type == 'remote' ) {
|
49 |
-
$username =
|
50 |
-
$password =
|
51 |
-
$database =
|
52 |
-
$host =
|
53 |
$wpdb_temp = new wpdb($username, $password, $database, $host);
|
54 |
$query = "SHOW TABLES";
|
55 |
$tables = $wpdb_temp->get_col($query);
|
@@ -78,18 +78,18 @@ class FMModelFormMakerSQLMapping_fmc {
|
|
78 |
|
79 |
function get_table_struct() {
|
80 |
global $wpdb;
|
81 |
-
$name =
|
82 |
if ( !$name ) {
|
83 |
return array();
|
84 |
}
|
85 |
-
$con_method =
|
86 |
-
$con_type =
|
87 |
$query = 'SHOW COLUMNS FROM `' . $name . '`';
|
88 |
if ( $con_type == 'remote' ) {
|
89 |
-
$username =
|
90 |
-
$password =
|
91 |
-
$database =
|
92 |
-
$host =
|
93 |
$wpdb_temp = new wpdb($username, $password, $database, $host);
|
94 |
$table_struct = $wpdb_temp->get_results($query);
|
95 |
}
|
3 |
/**
|
4 |
* Class FMModelFormMakerSQLMapping_fmc
|
5 |
*/
|
6 |
+
class FMModelFormMakerSQLMapping_fmc extends CFMAdminModel {
|
7 |
/**
|
8 |
* Get query by id.
|
9 |
*
|
39 |
*/
|
40 |
function get_tables() {
|
41 |
global $wpdb;
|
42 |
+
$con_type = WDW_FM_Library(self::PLUGIN)->get('con_type', NULL);
|
43 |
if ( $con_type == 'local' ) {
|
44 |
$query = "SHOW TABLES";
|
45 |
$tables = $wpdb->get_col($query);
|
46 |
}
|
47 |
else {
|
48 |
if ( $con_type == 'remote' ) {
|
49 |
+
$username = WDW_FM_Library(self::PLUGIN)->get('username', '');
|
50 |
+
$password = WDW_FM_Library(self::PLUGIN)->get('password', '');
|
51 |
+
$database = WDW_FM_Library(self::PLUGIN)->get('database', '');
|
52 |
+
$host = WDW_FM_Library(self::PLUGIN)->get('host', '');
|
53 |
$wpdb_temp = new wpdb($username, $password, $database, $host);
|
54 |
$query = "SHOW TABLES";
|
55 |
$tables = $wpdb_temp->get_col($query);
|
78 |
|
79 |
function get_table_struct() {
|
80 |
global $wpdb;
|
81 |
+
$name = WDW_FM_Library(self::PLUGIN)->get('name', NULL);
|
82 |
if ( !$name ) {
|
83 |
return array();
|
84 |
}
|
85 |
+
$con_method = WDW_FM_Library(self::PLUGIN)->get('con_method', NULL);
|
86 |
+
$con_type = WDW_FM_Library(self::PLUGIN)->get('con_type', NULL);
|
87 |
$query = 'SHOW COLUMNS FROM `' . $name . '`';
|
88 |
if ( $con_type == 'remote' ) {
|
89 |
+
$username = WDW_FM_Library(self::PLUGIN)->get('username', '');
|
90 |
+
$password = WDW_FM_Library(self::PLUGIN)->get('password', '');
|
91 |
+
$database = WDW_FM_Library(self::PLUGIN)->get('database', '');
|
92 |
+
$host = WDW_FM_Library(self::PLUGIN)->get('host', '');
|
93 |
$wpdb_temp = new wpdb($username, $password, $database, $host);
|
94 |
$table_struct = $wpdb_temp->get_results($query);
|
95 |
}
|
admin/models/FormMakerSubmits.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelFormMakerSubmits_fmc
|
5 |
*/
|
6 |
-
class FMModelFormMakerSubmits_fmc {
|
7 |
public function get_from_label_order( $form_id ) {
|
8 |
global $wpdb;
|
9 |
$label_order = $wpdb->get_var($wpdb->prepare('SELECT `label_order` FROM `' . $wpdb->prefix . 'formmaker` WHERE id="%d"', $form_id));
|
3 |
/**
|
4 |
* Class FMModelFormMakerSubmits_fmc
|
5 |
*/
|
6 |
+
class FMModelFormMakerSubmits_fmc extends CFMAdminModel {
|
7 |
public function get_from_label_order( $form_id ) {
|
8 |
global $wpdb;
|
9 |
$label_order = $wpdb->get_var($wpdb->prepare('SELECT `label_order` FROM `' . $wpdb->prefix . 'formmaker` WHERE id="%d"', $form_id));
|
admin/models/Manage_fm.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelManage_fmc
|
5 |
*/
|
6 |
-
class FMModelManage_fmc {
|
7 |
/**
|
8 |
* Get forms.
|
9 |
*
|
@@ -15,15 +15,15 @@ class FMModelManage_fmc {
|
|
15 |
$order = $params['order'];
|
16 |
$orderby = $params['orderby'];
|
17 |
$items_per_page = $params['items_per_page'];
|
18 |
-
$search =
|
19 |
-
$page = (int)
|
20 |
$limit = $page ? ($page - 1) * $items_per_page : 0;
|
21 |
|
22 |
global $wpdb;
|
23 |
$query = "SELECT t1.* FROM " . $wpdb->prefix . "formmaker as t1 ";
|
24 |
-
$query .= (!
|
25 |
if ( $search ) {
|
26 |
-
$query .= (!
|
27 |
}
|
28 |
$query .= ' ORDER BY t1.`' . $orderby . '` ' . $order;
|
29 |
$query .= " LIMIT " . $limit . "," . $items_per_page;
|
@@ -50,7 +50,7 @@ class FMModelManage_fmc {
|
|
50 |
$row->title = '';
|
51 |
$row->mail = '';
|
52 |
$row->form = '';
|
53 |
-
$row->form_front = '<div class="wdform-page-and-images wd-table"><div id="form_id_tempform_view1" class="wdform_page" page_title="Untitled page" next_title="Next" next_type="text" next_class="wdform-page-button" next_checkable="
|
54 |
$row->theme = 0;
|
55 |
$row->javascript = '';
|
56 |
$row->submit_text = '';
|
@@ -115,14 +115,14 @@ class FMModelManage_fmc {
|
|
115 |
$row->title = '';
|
116 |
$row->mail = '';
|
117 |
$row->form = '';
|
118 |
-
$row->form_front = '<div class="wdform-page-and-images" class="wd-table"><div id="form_id_tempform_view1" class="wdform_page" page_title="Untitled page" next_title="Next" next_type="text" next_class="wdform-page-button" next_checkable="
|
119 |
$row->theme = $wpdb->get_var("SELECT id FROM " . $wpdb->prefix . "formmaker_themes WHERE `default`='1'");
|
120 |
$row->javascript = '';
|
121 |
$row->submit_text = '';
|
122 |
$row->url = '';
|
123 |
$row->submit_text_type = 1;
|
124 |
-
$row->script1 = '
|
125 |
-
$row->script2 = '
|
126 |
$row->script_user1 = '';
|
127 |
$row->script_user2 = '';
|
128 |
$row->counter = 2;
|
@@ -247,7 +247,16 @@ class FMModelManage_fmc {
|
|
247 |
case 'type_arithmetic_captcha':
|
248 |
case 'type_recaptcha': {
|
249 |
$arrows = '<div id="wdform_arrows' . $id . '" class="wdform_arrows" style="display: none;">
|
250 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
251 |
<span id="left_' . $id . '" valign="middle" class="element_toolbar">
|
252 |
<span title="Move the field to the left" class="page_toolbar dashicons dashicons-arrow-left-alt" onclick="left_row("' . $id . '")"></span>
|
253 |
</span>
|
@@ -266,21 +275,23 @@ class FMModelManage_fmc {
|
|
266 |
<span id="page_down_' . $id . '" valign="middle" class="element_toolbar">
|
267 |
<span title="Move the field to the lower page" class="page_toolbar dashicons dashicons-download" onclick="page_down("' . $id . '")"></span>
|
268 |
</span>
|
269 |
-
</
|
270 |
-
<span class="wdform_arrows_basic wdform_arrows_container"> <span id="edit_' . $id . '" valign="middle" class="element_toolbar">
|
271 |
-
<span title="Edit the field" class="page_toolbar dashicons dashicons-edit" onclick="edit("' . $id . '")"></span>
|
272 |
-
</span>
|
273 |
-
<span id="duplicate_' . $id . '" valign="middle" class="element_toolbar"></span>
|
274 |
-
<span id="X_' . $id . '" valign="middle" align="right" class="element_toolbar">
|
275 |
-
<span title="Remove the field" class="page_toolbar dashicons dashicons-no-alt" onclick="remove_row("' . $id . '")"></span>
|
276 |
-
</span>
|
277 |
-
</span>
|
278 |
</div>';
|
279 |
break;
|
280 |
}
|
281 |
default : {
|
282 |
$arrows = '<div id="wdform_arrows' . $id . '" class="wdform_arrows" style="display: none;">
|
283 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
284 |
<span id="left_' . $id . '" valign="middle" class="element_toolbar">
|
285 |
<span title="Move the field to the left" class="page_toolbar dashicons dashicons-arrow-left-alt" onclick="left_row("' . $id . '")"></span>
|
286 |
</span>
|
@@ -299,17 +310,7 @@ class FMModelManage_fmc {
|
|
299 |
<span id="page_down_' . $id . '" valign="middle" class="element_toolbar">
|
300 |
<span title="Move the field to the lower page" class="page_toolbar dashicons dashicons-download" onclick="page_down("' . $id . '")"></span>
|
301 |
</span>
|
302 |
-
</
|
303 |
-
<span class="wdform_arrows_basic wdform_arrows_container"> <span id="edit_' . $id . '" valign="middle" class="element_toolbar">
|
304 |
-
<span title="Edit the field" class="page_toolbar dashicons dashicons-edit" onclick="edit("' . $id . '")"></span>
|
305 |
-
</span>
|
306 |
-
<span id="duplicate_' . $id . '" valign="middle" class="element_toolbar">
|
307 |
-
<span title="Duplicate the field" class="page_toolbar dashicons dashicons-admin-page" onclick="duplicate("' . $id . '")"></span>
|
308 |
-
</span>
|
309 |
-
<span id="X_' . $id . '" valign="middle" align="right" class="element_toolbar">
|
310 |
-
<span title="Remove the field" class="page_toolbar dashicons dashicons-no-alt" onclick="remove_row("' . $id . '")"></span>
|
311 |
-
</span>
|
312 |
-
</span>
|
313 |
</div>';
|
314 |
break;
|
315 |
}
|
@@ -323,7 +324,7 @@ class FMModelManage_fmc {
|
|
323 |
$param[$params_name] = $temp[0];
|
324 |
$temp = $temp[1];
|
325 |
}
|
326 |
-
$rep = '<div id="wdform_field' . $id . '" type="type_section_break" class="wdform_field_section_break">' . $arrows . '<span id="' . $id . '_element_labelform_id_temp" style="display: none;">' . __('Section Break',
|
327 |
break;
|
328 |
}
|
329 |
case 'type_editor': {
|
@@ -334,7 +335,7 @@ class FMModelManage_fmc {
|
|
334 |
$param[$params_name] = $temp[0];
|
335 |
$temp = $temp[1];
|
336 |
}
|
337 |
-
$rep = '<div id="wdform_field' . $id . '" type="type_editor" class="wdform_field" >' . $param['w_editor'] . '</div>' . $arrows . '<div id="' . $id . '_element_labelform_id_temp" style="color: red;">' . __('Custom HTML',
|
338 |
break;
|
339 |
}
|
340 |
case 'type_send_copy': {
|
@@ -855,7 +856,7 @@ class FMModelManage_fmc {
|
|
855 |
$g++;
|
856 |
if ( $w_disabled_fields[5] == 'yes' && $w_disabled_fields[6] == 'yes' ) {
|
857 |
$address_fields .= '<span style="float: ' . (($g % 2 == 0) ? 'right' : 'left') . '; width: 48%; padding-bottom: 8px;"><select type="text" id="' . $id . '_stateform_id_temp" name="' . ($id + 3) . '_stateform_id_temp" style="width: 100%;" ' . $param['attributes'] . ' disabled >';
|
858 |
-
$states =
|
859 |
foreach ($states as $st => $state) {
|
860 |
$address_fields .= '<option value="' . $st . '">' . $state . '</option>';
|
861 |
}
|
@@ -871,7 +872,7 @@ class FMModelManage_fmc {
|
|
871 |
}
|
872 |
if ( $w_disabled_fields[5] == 'no' ) {
|
873 |
$g++;
|
874 |
-
$countries_list =
|
875 |
$address_fields .= '<span style="float: ' . (($g % 2 == 0) ? 'right' : 'left') . '; width: 48%; padding-bottom: 8px;">
|
876 |
<select type="text" id="' . $id . '_countryform_id_temp" name="' . ($id + 5) . '_countryform_id_temp" style="width: 100%;" ' . $param['attributes'] . ' disabled>';
|
877 |
foreach ($countries_list as $value => $item) {
|
@@ -2056,7 +2057,7 @@ class FMModelManage_fmc {
|
|
2056 |
$param['w_hide_label'] = (isset($param['w_hide_label']) ? $param['w_hide_label'] : "no");
|
2057 |
$display_label = $param['w_hide_label'] == "no" ? $param['w_field_label_pos'] : "none";
|
2058 |
$rep = '<div id="wdform_field' . $id . '" type="type_captcha" class="wdform_field" style="display: table-cell;">' . $arrows . '<div align="left" id="' . $id . '_label_sectionform_id_temp" class="' . $param['w_class'] . '" style="display:' . $display_label . '; width: ' . $param['w_field_label_size'] . 'px;"><span id="' . $id . '_element_labelform_id_temp" class="label" style="vertical-align: top;">' . $label . '</span></div><div align="left" id="' . $id . '_element_sectionform_id_temp" class="' . $param['w_class'] . '" style="display: ' . $param['w_field_label_pos'] . ';"><input type="hidden" value="type_captcha" name="' . $id . '_typeform_id_temp" id="' . $id . '_typeform_id_temp"><div style="display: table;"><div style="display: table-row;"><div valign="middle" style="display: table-cell;"><img type="captcha" digit="' . $param['w_digit'] . '" src="' . add_query_arg(array(
|
2059 |
-
'action' => 'formmakerwdcaptcha' .
|
2060 |
'digit' => $param['w_digit'],
|
2061 |
'i' => 'form_id_temp',
|
2062 |
), admin_url('admin-ajax.php')) . '" id="_wd_captchaform_id_temp" class="captcha_img" onclick="captcha_refresh("_wd_captcha","form_id_temp")" ' . $param['attributes'] . '></div><div valign="middle" style="display: table-cell;"><div class="captcha_refresh" id="_element_refreshform_id_temp" onclick="captcha_refresh("_wd_captcha","form_id_temp")" ' . $param['attributes'] . '></div></div></div><div style="display: table-row;"><div style="display: table-cell;"><input type="text" class="captcha_input" id="_wd_captcha_inputform_id_temp" name="captcha_input" style="width: ' . ($param['w_digit'] * 10 + 15) . 'px;" ' . $param['attributes'] . ' disabled/><input type="hidden" value="' . $param['w_hide_label'] . '" name="' . $id . '_hide_labelform_id_temp" id="' . $id . '_hide_labelform_id_temp"/></div></div></div></div></div>';
|
@@ -2102,7 +2103,7 @@ class FMModelManage_fmc {
|
|
2102 |
$param['w_operations'] = $param['w_operations'] ? $param['w_operations'] : '+, -, *, /';
|
2103 |
$param['w_input_size'] = $param['w_input_size'] ? $param['w_input_size'] : 60;
|
2104 |
$rep = '<div id="wdform_field' . $id . '" type="type_arithmetic_captcha" class="wdform_field" style="display: table-cell;">' . $arrows . '<div align="left" id="' . $id . '_label_sectionform_id_temp" class="' . $param['w_class'] . '" style="display:' . $display_label . '; width: ' . $param['w_field_label_size'] . 'px;"><span id="' . $id . '_element_labelform_id_temp" class="label" style="vertical-align: top;">' . $label . '</span></div><div align="left" id="' . $id . '_element_sectionform_id_temp" class="' . $param['w_class'] . '" style="display: ' . $param['w_field_label_pos'] . ';"><input type="hidden" value="type_captcha" name="' . $id . '_typeform_id_temp" id="' . $id . '_typeform_id_temp"><div style="display: table;"><div style="display: table-row;"><div style="display: table-cell;"><img type="captcha" operations_count="' . $param['w_count'] . '" operations="' . $param['w_operations'] . '" input_size="' . $param['w_input_size'] . '" src="' . add_query_arg(array(
|
2105 |
-
'action' => 'formmakerwdmathcaptcha' .
|
2106 |
'operations_count' => $param['w_count'],
|
2107 |
'operations' => urlencode($param['w_operations']),
|
2108 |
'i' => 'form_id_temp',
|
@@ -2149,7 +2150,7 @@ class FMModelManage_fmc {
|
|
2149 |
$param['w_field_label_pos'] = ($param['w_field_label_pos'] == "left" ? "table-cell" : "block");
|
2150 |
$param['w_hide_label'] = (isset($param['w_hide_label']) ? $param['w_hide_label'] : "no");
|
2151 |
$display_label = $param['w_hide_label'] == "no" ? $param['w_field_label_pos'] : "none";
|
2152 |
-
$rep = '<div id="wdform_field' . $id . '" type="type_recaptcha" class="wdform_field" style="display: table-cell;">' . $arrows . '<div align="left" id="' . $id . '_label_sectionform_id_temp" style="display: ' . $display_label . '; width: ' . $param['w_field_label_size'] . 'px;"><span id="' . $id . '_element_labelform_id_temp" class="label" style="vertical-align: top;">' . $label . '</span></div><div align="left" id="' . $id . '_element_sectionform_id_temp" style="display: ' . $param['w_field_label_pos'] . ';"><input type="hidden" value="type_recaptcha" name="' . $id . '_typeform_id_temp" id="' . $id . '_typeform_id_temp"><input type="hidden" value="' . $param['w_hide_label'] . '" name="' . $id . '_hide_labelform_id_temp" id="' . $id . '_hide_labelform_id_temp"/><div id="wd_recaptchaform_id_temp" w_type="' . $param['w_type'] . '" position="' . $param['w_position'] . '"><span style="color: red; font-style: italic;">' . __('No preview available for reCAPTCHA.',
|
2153 |
break;
|
2154 |
}
|
2155 |
case 'type_hidden': {
|
@@ -2979,7 +2980,7 @@ class FMModelManage_fmc {
|
|
2979 |
$required_sym = ($param['w_required'] == "yes" ? " *" : "");
|
2980 |
$images = '';
|
2981 |
for ( $i = 0; $i < $param['w_star_amount']; $i++ ) {
|
2982 |
-
$images .= '<img id="' . $id . '_star_' . $i . '" src="' .
|
2983 |
}
|
2984 |
$rep = '<div id="wdform_field' . $id . '" type="type_star_rating" class="wdform_field" style="display: table-cell;">' . $arrows . '<div align="left" id="' . $id . '_label_sectionform_id_temp" class="' . $param['w_class'] . '" style="display: ' . $display_label . '; width: ' . $param['w_field_label_size'] . 'px;"><span id="' . $id . '_element_labelform_id_temp" class="label">' . $label . '</span><span id="' . $id . '_required_elementform_id_temp" class="required">' . $required_sym . '</span></div><div align="left" id="' . $id . '_element_sectionform_id_temp" class="' . $param['w_class'] . '" style="display: ' . $param['w_field_label_pos'] . ';"><input type="hidden" value="type_star_rating" name="' . $id . '_typeform_id_temp" id="' . $id . '_typeform_id_temp"><input type="hidden" value="' . $param['w_required'] . '" name="' . $id . '_requiredform_id_temp" id="' . $id . '_requiredform_id_temp"><input type="hidden" value="' . $param['w_hide_label'] . '" name="' . $id . '_hide_labelform_id_temp" id="' . $id . '_hide_labelform_id_temp"/><input type="hidden" value="' . $param['w_star_amount'] . '" id="' . $id . '_star_amountform_id_temp" name="' . $id . '_star_amountform_id_temp"><input type="hidden" value="' . $param['w_field_label_col'] . '" name="' . $id . '_star_colorform_id_temp" id="' . $id . '_star_colorform_id_temp"><div id="' . $id . '_elementform_id_temp" class="wdform_stars" ' . $param['attributes'] . '>' . $images . '</div></div></div>';
|
2985 |
break;
|
@@ -3398,11 +3399,11 @@ class FMModelManage_fmc {
|
|
3398 |
global $wpdb;
|
3399 |
$query = "SELECT COUNT(*) FROM `" . $wpdb->prefix . "formmaker`";
|
3400 |
|
3401 |
-
$search =
|
3402 |
|
3403 |
-
$query .= (!
|
3404 |
if ( $search ) {
|
3405 |
-
$query .= (!
|
3406 |
}
|
3407 |
|
3408 |
$total = $wpdb->get_var($query);
|
@@ -3718,7 +3719,7 @@ class FMModelManage_fmc {
|
|
3718 |
}
|
3719 |
|
3720 |
public function create_js( $form_id ) {
|
3721 |
-
|
3722 |
$jsversion = rand();
|
3723 |
global $wpdb;
|
3724 |
$wpdb->update($wpdb->prefix . 'formmaker', array(
|
@@ -3736,7 +3737,7 @@ class FMModelManage_fmc {
|
|
3736 |
*/
|
3737 |
public function insert_formmaker_backup( $backup_id, $id ) {
|
3738 |
global $wpdb;
|
3739 |
-
$query = "INSERT INTO " . $wpdb->prefix . "formmaker_backup SELECT " . $backup_id . "
|
3740 |
|
3741 |
return $wpdb->query($query);
|
3742 |
}
|
@@ -3816,7 +3817,7 @@ class FMModelManage_fmc {
|
|
3816 |
* @return string $guid
|
3817 |
*/
|
3818 |
public function get_form_preview_post() {
|
3819 |
-
$post_type = 'form-maker' .
|
3820 |
$row = get_posts(array( 'post_type' => $post_type ));
|
3821 |
if ( !empty($row[0]) ) {
|
3822 |
return get_post_permalink($row[0]->ID);
|
@@ -3825,9 +3826,9 @@ class FMModelManage_fmc {
|
|
3825 |
$post_params = array(
|
3826 |
'post_author' => 1,
|
3827 |
'post_status' => 'publish',
|
3828 |
-
'post_content' => '[FormPreview' .
|
3829 |
'post_title' => 'Preview',
|
3830 |
-
'post_type' => 'form-maker' .
|
3831 |
'comment_status' => 'closed',
|
3832 |
'ping_status' => 'closed',
|
3833 |
'post_parent' => 0,
|
3 |
/**
|
4 |
* Class FMModelManage_fmc
|
5 |
*/
|
6 |
+
class FMModelManage_fmc extends CFMAdminModel {
|
7 |
/**
|
8 |
* Get forms.
|
9 |
*
|
15 |
$order = $params['order'];
|
16 |
$orderby = $params['orderby'];
|
17 |
$items_per_page = $params['items_per_page'];
|
18 |
+
$search = WDW_FM_Library(self::PLUGIN)->get('s', '');
|
19 |
+
$page = (int) WDW_FM_Library(self::PLUGIN)->get('paged', 1);
|
20 |
$limit = $page ? ($page - 1) * $items_per_page : 0;
|
21 |
|
22 |
global $wpdb;
|
23 |
$query = "SELECT t1.* FROM " . $wpdb->prefix . "formmaker as t1 ";
|
24 |
+
$query .= (!WDFMInstance(self::PLUGIN)->is_free ? '' : 'WHERE t1.id' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')');
|
25 |
if ( $search ) {
|
26 |
+
$query .= (!WDFMInstance(self::PLUGIN)->is_free ? 'WHERE' : ' AND') . ' t1.title LIKE "%' . $search . '%"';
|
27 |
}
|
28 |
$query .= ' ORDER BY t1.`' . $orderby . '` ' . $order;
|
29 |
$query .= " LIMIT " . $limit . "," . $items_per_page;
|
50 |
$row->title = '';
|
51 |
$row->mail = '';
|
52 |
$row->form = '';
|
53 |
+
$row->form_front = '<div class="wdform-page-and-images wd-table"><div id="form_id_tempform_view1" class="wdform_page" page_title="Untitled page" next_title="Next" next_type="text" next_class="wdform-page-button" next_checkable="true" previous_title="Previous" previous_type="text" previous_class="wdform-page-button" previous_checkable="false"><div class="wdform_section"><div class="wdform_column"><div wdid="1" class="wdform_row ui-sortable-handle">%1 - type_submit_reset_1%</div></div></div><div valign="top" class="wdform_footer wd-width-100"><div class="wd-width-100"><div class="wd-width-100 wd-table" style="padding-top:10px;"><div class="wd-table-group"><div id="form_id_temppage_nav1" class="wd-table-row"></div></div></div></div></div></div></div>';
|
54 |
$row->theme = 0;
|
55 |
$row->javascript = '';
|
56 |
$row->submit_text = '';
|
115 |
$row->title = '';
|
116 |
$row->mail = '';
|
117 |
$row->form = '';
|
118 |
+
$row->form_front = '<div class="wdform-page-and-images" class="wd-table"><div id="form_id_tempform_view1" class="wdform_page" page_title="Untitled page" next_title="Next" next_type="text" next_class="wdform-page-button" next_checkable="true" previous_title="Previous" previous_type="text" previous_class="wdform-page-button" previous_checkable="false"><div class="wdform_section"><div class="wdform_column"><div wdid="1" class="wdform_row ui-sortable-handle">%1 - type_submit_reset_1%</div></div></div><div valign="top" class="wdform_footer wd-width-100"><div class="wd-width-100"><div class="wd-width-100 wd-table" style="padding-top:10px;"><div class="wd-table-group"><div id="form_id_temppage_nav1" class="wd-table-row"></div></div></div></div></div></div></div>';
|
119 |
$row->theme = $wpdb->get_var("SELECT id FROM " . $wpdb->prefix . "formmaker_themes WHERE `default`='1'");
|
120 |
$row->javascript = '';
|
121 |
$row->submit_text = '';
|
122 |
$row->url = '';
|
123 |
$row->submit_text_type = 1;
|
124 |
+
$row->script1 = '{all}';
|
125 |
+
$row->script2 = '{all}';
|
126 |
$row->script_user1 = '';
|
127 |
$row->script_user2 = '';
|
128 |
$row->counter = 2;
|
247 |
case 'type_arithmetic_captcha':
|
248 |
case 'type_recaptcha': {
|
249 |
$arrows = '<div id="wdform_arrows' . $id . '" class="wdform_arrows" style="display: none;">
|
250 |
+
<div class="wdform_arrows_basic wdform_arrows_container">
|
251 |
+
<span id="edit_' . $id . '" valign="middle" class="element_toolbar">
|
252 |
+
<span title="Edit the field" class="page_toolbar dashicons dashicons-edit" onclick="edit("' . $id . '")"></span>
|
253 |
+
</span>
|
254 |
+
<span id="duplicate_' . $id . '" valign="middle" class="element_toolbar"></span>
|
255 |
+
<span id="X_' . $id . '" valign="middle" align="right" class="element_toolbar">
|
256 |
+
<span title="Remove the field" class="page_toolbar dashicons dashicons-no-alt" onclick="remove_row("' . $id . '")"></span>
|
257 |
+
</span>
|
258 |
+
</div>
|
259 |
+
<div class="wdform_arrows_advanced wdform_arrows_container" style="display: none;">
|
260 |
<span id="left_' . $id . '" valign="middle" class="element_toolbar">
|
261 |
<span title="Move the field to the left" class="page_toolbar dashicons dashicons-arrow-left-alt" onclick="left_row("' . $id . '")"></span>
|
262 |
</span>
|
275 |
<span id="page_down_' . $id . '" valign="middle" class="element_toolbar">
|
276 |
<span title="Move the field to the lower page" class="page_toolbar dashicons dashicons-download" onclick="page_down("' . $id . '")"></span>
|
277 |
</span>
|
278 |
+
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
279 |
</div>';
|
280 |
break;
|
281 |
}
|
282 |
default : {
|
283 |
$arrows = '<div id="wdform_arrows' . $id . '" class="wdform_arrows" style="display: none;">
|
284 |
+
<div class="wdform_arrows_basic wdform_arrows_container"> <span id="edit_' . $id . '" valign="middle" class="element_toolbar">
|
285 |
+
<span title="Edit the field" class="page_toolbar dashicons dashicons-edit" onclick="edit("' . $id . '")"></span>
|
286 |
+
</span>
|
287 |
+
<span id="duplicate_' . $id . '" valign="middle" class="element_toolbar">
|
288 |
+
<span title="Duplicate the field" class="page_toolbar dashicons dashicons-admin-page" onclick="duplicate("' . $id . '")"></span>
|
289 |
+
</span>
|
290 |
+
<span id="X_' . $id . '" valign="middle" align="right" class="element_toolbar">
|
291 |
+
<span title="Remove the field" class="page_toolbar dashicons dashicons-no-alt" onclick="remove_row("' . $id . '")"></span>
|
292 |
+
</span>
|
293 |
+
</div>
|
294 |
+
<div class="wdform_arrows_advanced wdform_arrows_container" style="display: none;">
|
295 |
<span id="left_' . $id . '" valign="middle" class="element_toolbar">
|
296 |
<span title="Move the field to the left" class="page_toolbar dashicons dashicons-arrow-left-alt" onclick="left_row("' . $id . '")"></span>
|
297 |
</span>
|
310 |
<span id="page_down_' . $id . '" valign="middle" class="element_toolbar">
|
311 |
<span title="Move the field to the lower page" class="page_toolbar dashicons dashicons-download" onclick="page_down("' . $id . '")"></span>
|
312 |
</span>
|
313 |
+
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
314 |
</div>';
|
315 |
break;
|
316 |
}
|
324 |
$param[$params_name] = $temp[0];
|
325 |
$temp = $temp[1];
|
326 |
}
|
327 |
+
$rep = '<div id="wdform_field' . $id . '" type="type_section_break" class="wdform_field_section_break">' . $arrows . '<span id="' . $id . '_element_labelform_id_temp" style="display: none;">' . __('Section Break', WDFMInstance(self::PLUGIN)->prefix) . '</span><div id="' . $id . '_element_sectionform_id_temp" align="left" class="wdform_section_break">' . $param['w_editor'] . '</div></div><div id="' . $id . '_element_labelform_id_temp" style="color:red;">' . __('Section Break', WDFMInstance(self::PLUGIN)->prefix) . '</div>';
|
328 |
break;
|
329 |
}
|
330 |
case 'type_editor': {
|
335 |
$param[$params_name] = $temp[0];
|
336 |
$temp = $temp[1];
|
337 |
}
|
338 |
+
$rep = '<div id="wdform_field' . $id . '" type="type_editor" class="wdform_field" >' . $param['w_editor'] . '</div>' . $arrows . '<div id="' . $id . '_element_labelform_id_temp" style="color: red;">' . __('Custom HTML', WDFMInstance(self::PLUGIN)->prefix) . $id . '</div>';
|
339 |
break;
|
340 |
}
|
341 |
case 'type_send_copy': {
|
856 |
$g++;
|
857 |
if ( $w_disabled_fields[5] == 'yes' && $w_disabled_fields[6] == 'yes' ) {
|
858 |
$address_fields .= '<span style="float: ' . (($g % 2 == 0) ? 'right' : 'left') . '; width: 48%; padding-bottom: 8px;"><select type="text" id="' . $id . '_stateform_id_temp" name="' . ($id + 3) . '_stateform_id_temp" style="width: 100%;" ' . $param['attributes'] . ' disabled >';
|
859 |
+
$states = WDW_FM_Library(self::PLUGIN)->get_states();
|
860 |
foreach ($states as $st => $state) {
|
861 |
$address_fields .= '<option value="' . $st . '">' . $state . '</option>';
|
862 |
}
|
872 |
}
|
873 |
if ( $w_disabled_fields[5] == 'no' ) {
|
874 |
$g++;
|
875 |
+
$countries_list = WDW_FM_Library(self::PLUGIN)->get_countries();
|
876 |
$address_fields .= '<span style="float: ' . (($g % 2 == 0) ? 'right' : 'left') . '; width: 48%; padding-bottom: 8px;">
|
877 |
<select type="text" id="' . $id . '_countryform_id_temp" name="' . ($id + 5) . '_countryform_id_temp" style="width: 100%;" ' . $param['attributes'] . ' disabled>';
|
878 |
foreach ($countries_list as $value => $item) {
|
2057 |
$param['w_hide_label'] = (isset($param['w_hide_label']) ? $param['w_hide_label'] : "no");
|
2058 |
$display_label = $param['w_hide_label'] == "no" ? $param['w_field_label_pos'] : "none";
|
2059 |
$rep = '<div id="wdform_field' . $id . '" type="type_captcha" class="wdform_field" style="display: table-cell;">' . $arrows . '<div align="left" id="' . $id . '_label_sectionform_id_temp" class="' . $param['w_class'] . '" style="display:' . $display_label . '; width: ' . $param['w_field_label_size'] . 'px;"><span id="' . $id . '_element_labelform_id_temp" class="label" style="vertical-align: top;">' . $label . '</span></div><div align="left" id="' . $id . '_element_sectionform_id_temp" class="' . $param['w_class'] . '" style="display: ' . $param['w_field_label_pos'] . ';"><input type="hidden" value="type_captcha" name="' . $id . '_typeform_id_temp" id="' . $id . '_typeform_id_temp"><div style="display: table;"><div style="display: table-row;"><div valign="middle" style="display: table-cell;"><img type="captcha" digit="' . $param['w_digit'] . '" src="' . add_query_arg(array(
|
2060 |
+
'action' => 'formmakerwdcaptcha' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
2061 |
'digit' => $param['w_digit'],
|
2062 |
'i' => 'form_id_temp',
|
2063 |
), admin_url('admin-ajax.php')) . '" id="_wd_captchaform_id_temp" class="captcha_img" onclick="captcha_refresh("_wd_captcha","form_id_temp")" ' . $param['attributes'] . '></div><div valign="middle" style="display: table-cell;"><div class="captcha_refresh" id="_element_refreshform_id_temp" onclick="captcha_refresh("_wd_captcha","form_id_temp")" ' . $param['attributes'] . '></div></div></div><div style="display: table-row;"><div style="display: table-cell;"><input type="text" class="captcha_input" id="_wd_captcha_inputform_id_temp" name="captcha_input" style="width: ' . ($param['w_digit'] * 10 + 15) . 'px;" ' . $param['attributes'] . ' disabled/><input type="hidden" value="' . $param['w_hide_label'] . '" name="' . $id . '_hide_labelform_id_temp" id="' . $id . '_hide_labelform_id_temp"/></div></div></div></div></div>';
|
2103 |
$param['w_operations'] = $param['w_operations'] ? $param['w_operations'] : '+, -, *, /';
|
2104 |
$param['w_input_size'] = $param['w_input_size'] ? $param['w_input_size'] : 60;
|
2105 |
$rep = '<div id="wdform_field' . $id . '" type="type_arithmetic_captcha" class="wdform_field" style="display: table-cell;">' . $arrows . '<div align="left" id="' . $id . '_label_sectionform_id_temp" class="' . $param['w_class'] . '" style="display:' . $display_label . '; width: ' . $param['w_field_label_size'] . 'px;"><span id="' . $id . '_element_labelform_id_temp" class="label" style="vertical-align: top;">' . $label . '</span></div><div align="left" id="' . $id . '_element_sectionform_id_temp" class="' . $param['w_class'] . '" style="display: ' . $param['w_field_label_pos'] . ';"><input type="hidden" value="type_captcha" name="' . $id . '_typeform_id_temp" id="' . $id . '_typeform_id_temp"><div style="display: table;"><div style="display: table-row;"><div style="display: table-cell;"><img type="captcha" operations_count="' . $param['w_count'] . '" operations="' . $param['w_operations'] . '" input_size="' . $param['w_input_size'] . '" src="' . add_query_arg(array(
|
2106 |
+
'action' => 'formmakerwdmathcaptcha' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
2107 |
'operations_count' => $param['w_count'],
|
2108 |
'operations' => urlencode($param['w_operations']),
|
2109 |
'i' => 'form_id_temp',
|
2150 |
$param['w_field_label_pos'] = ($param['w_field_label_pos'] == "left" ? "table-cell" : "block");
|
2151 |
$param['w_hide_label'] = (isset($param['w_hide_label']) ? $param['w_hide_label'] : "no");
|
2152 |
$display_label = $param['w_hide_label'] == "no" ? $param['w_field_label_pos'] : "none";
|
2153 |
+
$rep = '<div id="wdform_field' . $id . '" type="type_recaptcha" class="wdform_field" style="display: table-cell;">' . $arrows . '<div align="left" id="' . $id . '_label_sectionform_id_temp" style="display: ' . $display_label . '; width: ' . $param['w_field_label_size'] . 'px;"><span id="' . $id . '_element_labelform_id_temp" class="label" style="vertical-align: top;">' . $label . '</span></div><div align="left" id="' . $id . '_element_sectionform_id_temp" style="display: ' . $param['w_field_label_pos'] . ';"><input type="hidden" value="type_recaptcha" name="' . $id . '_typeform_id_temp" id="' . $id . '_typeform_id_temp"><input type="hidden" value="' . $param['w_hide_label'] . '" name="' . $id . '_hide_labelform_id_temp" id="' . $id . '_hide_labelform_id_temp"/><div id="wd_recaptchaform_id_temp" w_type="' . $param['w_type'] . '" position="' . $param['w_position'] . '"><span style="color: red; font-style: italic;">' . __('No preview available for reCAPTCHA.', WDFMInstance(self::PLUGIN)->prefix) . '</span></div></div></div>';
|
2154 |
break;
|
2155 |
}
|
2156 |
case 'type_hidden': {
|
2980 |
$required_sym = ($param['w_required'] == "yes" ? " *" : "");
|
2981 |
$images = '';
|
2982 |
for ( $i = 0; $i < $param['w_star_amount']; $i++ ) {
|
2983 |
+
$images .= '<img id="' . $id . '_star_' . $i . '" src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/star.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" onmouseover="change_src(' . $i . ',' . $id . ',"form_id_temp")" onmouseout="reset_src(' . $i . ',' . $id . ')" onclick="select_star_rating(' . $i . ',' . $id . ', "form_id_temp")">';
|
2984 |
}
|
2985 |
$rep = '<div id="wdform_field' . $id . '" type="type_star_rating" class="wdform_field" style="display: table-cell;">' . $arrows . '<div align="left" id="' . $id . '_label_sectionform_id_temp" class="' . $param['w_class'] . '" style="display: ' . $display_label . '; width: ' . $param['w_field_label_size'] . 'px;"><span id="' . $id . '_element_labelform_id_temp" class="label">' . $label . '</span><span id="' . $id . '_required_elementform_id_temp" class="required">' . $required_sym . '</span></div><div align="left" id="' . $id . '_element_sectionform_id_temp" class="' . $param['w_class'] . '" style="display: ' . $param['w_field_label_pos'] . ';"><input type="hidden" value="type_star_rating" name="' . $id . '_typeform_id_temp" id="' . $id . '_typeform_id_temp"><input type="hidden" value="' . $param['w_required'] . '" name="' . $id . '_requiredform_id_temp" id="' . $id . '_requiredform_id_temp"><input type="hidden" value="' . $param['w_hide_label'] . '" name="' . $id . '_hide_labelform_id_temp" id="' . $id . '_hide_labelform_id_temp"/><input type="hidden" value="' . $param['w_star_amount'] . '" id="' . $id . '_star_amountform_id_temp" name="' . $id . '_star_amountform_id_temp"><input type="hidden" value="' . $param['w_field_label_col'] . '" name="' . $id . '_star_colorform_id_temp" id="' . $id . '_star_colorform_id_temp"><div id="' . $id . '_elementform_id_temp" class="wdform_stars" ' . $param['attributes'] . '>' . $images . '</div></div></div>';
|
2986 |
break;
|
3399 |
global $wpdb;
|
3400 |
$query = "SELECT COUNT(*) FROM `" . $wpdb->prefix . "formmaker`";
|
3401 |
|
3402 |
+
$search = WDW_FM_Library(self::PLUGIN)->get('s', '');
|
3403 |
|
3404 |
+
$query .= (!WDFMInstance(self::PLUGIN)->is_free ? '' : 'WHERE id' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')');
|
3405 |
if ( $search ) {
|
3406 |
+
$query .= (!WDFMInstance(self::PLUGIN)->is_free ? 'WHERE' : ' AND') . ' `title` LIKE "%' . $search . '%"';
|
3407 |
}
|
3408 |
|
3409 |
$total = $wpdb->get_var($query);
|
3719 |
}
|
3720 |
|
3721 |
public function create_js( $form_id ) {
|
3722 |
+
WDW_FM_Library(self::PLUGIN)->create_js($form_id, true);
|
3723 |
$jsversion = rand();
|
3724 |
global $wpdb;
|
3725 |
$wpdb->update($wpdb->prefix . 'formmaker', array(
|
3737 |
*/
|
3738 |
public function insert_formmaker_backup( $backup_id, $id ) {
|
3739 |
global $wpdb;
|
3740 |
+
$query = "INSERT INTO " . $wpdb->prefix . "formmaker_backup (backup_id, cur, id, title, `type`, mail, form_front, theme, javascript, submit_text, url, submit_text_type, script_mail, script_mail_user, counter, published, label_order, label_order_current, article_id, pagination, show_title, show_numbers, public_key, private_key, recaptcha_theme, paypal_mode, checkout_mode, paypal_email, payment_currency, tax, form_fields, savedb, sendemail, requiredmark, from_mail, from_name, reply_to, send_to, autogen_layout, custom_front, mail_from_user, mail_from_name_user, reply_to_user, `condition`, mail_cc, mail_cc_user, mail_bcc, mail_bcc_user, mail_subject, mail_subject_user, mail_mode, mail_mode_user, mail_attachment, mail_attachment_user, user_id_wd, sortable, frontend_submit_fields, frontend_submit_stat_fields, mail_emptyfields, mail_verify, mail_verify_expiretime, mail_verification_post_id, save_uploads, header_title, header_description, header_image_url, header_image_animation, header_hide_image) SELECT " . $backup_id . ", 1, formmakerbkup.id, formmakerbkup.title, formmakerbkup.type, formmakerbkup.mail, formmakerbkup.form_front, formmakerbkup.theme, formmakerbkup.javascript, formmakerbkup.submit_text, formmakerbkup.url, formmakerbkup.submit_text_type, formmakerbkup.script_mail, formmakerbkup.script_mail_user, formmakerbkup.counter, formmakerbkup.published, formmakerbkup.label_order, formmakerbkup.label_order_current, formmakerbkup.article_id, formmakerbkup.pagination, formmakerbkup.show_title, formmakerbkup.show_numbers, formmakerbkup.public_key, formmakerbkup.private_key, formmakerbkup.recaptcha_theme, formmakerbkup.paypal_mode, formmakerbkup.checkout_mode, formmakerbkup.paypal_email, formmakerbkup.payment_currency, formmakerbkup.tax, formmakerbkup.form_fields, formmakerbkup.savedb, formmakerbkup.sendemail, formmakerbkup.requiredmark, formmakerbkup.from_mail, formmakerbkup.from_name, formmakerbkup.reply_to, formmakerbkup.send_to, formmakerbkup.autogen_layout, formmakerbkup.custom_front, formmakerbkup.mail_from_user, formmakerbkup.mail_from_name_user, formmakerbkup.reply_to_user, formmakerbkup.condition, formmakerbkup.mail_cc, formmakerbkup.mail_cc_user, formmakerbkup.mail_bcc, formmakerbkup.mail_bcc_user, formmakerbkup.mail_subject, formmakerbkup.mail_subject_user, formmakerbkup.mail_mode, formmakerbkup.mail_mode_user, formmakerbkup.mail_attachment, formmakerbkup.mail_attachment_user, formmakerbkup.user_id_wd, formmakerbkup.sortable, formmakerbkup.frontend_submit_fields, formmakerbkup.frontend_submit_stat_fields, formmakerbkup.mail_emptyfields, formmakerbkup.mail_verify, formmakerbkup.mail_verify_expiretime, formmakerbkup.mail_verification_post_id, formmakerbkup.save_uploads, formmakerbkup.header_title, formmakerbkup.header_description, formmakerbkup.header_image_url, formmakerbkup.header_image_animation, formmakerbkup.header_hide_image FROM " . $wpdb->prefix . "formmaker as formmakerbkup WHERE id=" . $id;
|
3741 |
|
3742 |
return $wpdb->query($query);
|
3743 |
}
|
3817 |
* @return string $guid
|
3818 |
*/
|
3819 |
public function get_form_preview_post() {
|
3820 |
+
$post_type = 'form-maker' . WDFMInstance(self::PLUGIN)->plugin_postfix;
|
3821 |
$row = get_posts(array( 'post_type' => $post_type ));
|
3822 |
if ( !empty($row[0]) ) {
|
3823 |
return get_post_permalink($row[0]->ID);
|
3826 |
$post_params = array(
|
3827 |
'post_author' => 1,
|
3828 |
'post_status' => 'publish',
|
3829 |
+
'post_content' => '[FormPreview' . WDFMInstance(self::PLUGIN)->plugin_postfix . ']',
|
3830 |
'post_title' => 'Preview',
|
3831 |
+
'post_type' => 'form-maker' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
3832 |
'comment_status' => 'closed',
|
3833 |
'ping_status' => 'closed',
|
3834 |
'post_parent' => 0,
|
admin/models/Options_fm.php
CHANGED
@@ -3,18 +3,18 @@
|
|
3 |
/**
|
4 |
* Class FMModelOptions_fmc
|
5 |
*/
|
6 |
-
class FMModelOptions_fmc {
|
7 |
/**
|
8 |
* Save data to DB.
|
9 |
*/
|
10 |
public function save_db() {
|
11 |
-
$public_key =
|
12 |
-
$private_key =
|
13 |
$csv_delimiter = (isset($_POST['csv_delimiter']) && $_POST['csv_delimiter'] != '' ? esc_html(stripslashes($_POST['csv_delimiter'])) : ',');
|
14 |
$fm_shortcode = (isset($_POST['fm_shortcode']) ? "old" : '');
|
15 |
-
$fm_advanced_layout =
|
16 |
-
$map_key =
|
17 |
-
update_option('fmc_settings', array(
|
18 |
'public_key' => $public_key,
|
19 |
'private_key' => $private_key,
|
20 |
'csv_delimiter' => $csv_delimiter,
|
3 |
/**
|
4 |
* Class FMModelOptions_fmc
|
5 |
*/
|
6 |
+
class FMModelOptions_fmc extends CFMAdminModel {
|
7 |
/**
|
8 |
* Save data to DB.
|
9 |
*/
|
10 |
public function save_db() {
|
11 |
+
$public_key = WDW_FM_Library(self::PLUGIN)->get('public_key', '');
|
12 |
+
$private_key = WDW_FM_Library(self::PLUGIN)->get('private_key', '');
|
13 |
$csv_delimiter = (isset($_POST['csv_delimiter']) && $_POST['csv_delimiter'] != '' ? esc_html(stripslashes($_POST['csv_delimiter'])) : ',');
|
14 |
$fm_shortcode = (isset($_POST['fm_shortcode']) ? "old" : '');
|
15 |
+
$fm_advanced_layout = WDW_FM_Library(self::PLUGIN)->get('fm_advanced_layout', '0');
|
16 |
+
$map_key = WDW_FM_Library(self::PLUGIN)->get('map_key', '');
|
17 |
+
update_option((WDFMInstance(self::PLUGIN)->is_free == 2 ? 'fmc_settings' : 'fm_settings'), array(
|
18 |
'public_key' => $public_key,
|
19 |
'private_key' => $private_key,
|
20 |
'csv_delimiter' => $csv_delimiter,
|
admin/models/Submissions_fm.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMModelSubmissions_fmc
|
5 |
*/
|
6 |
-
class FMModelSubmissions_fmc {
|
7 |
public function blocked_ips() {
|
8 |
global $wpdb;
|
9 |
$ips = $wpdb->get_col('SELECT ip FROM ' . $wpdb->prefix . 'formmaker_blocked');
|
@@ -18,7 +18,7 @@ class FMModelSubmissions_fmc {
|
|
18 |
*/
|
19 |
public function get_forms() {
|
20 |
global $wpdb;
|
21 |
-
$query = "SELECT `id`, `title`, `published` FROM " . $wpdb->prefix . "formmaker " . (!
|
22 |
$results = $wpdb->get_results($query);
|
23 |
$forms = array();
|
24 |
if( !empty($results) ) {
|
@@ -561,10 +561,10 @@ class FMModelSubmissions_fmc {
|
|
561 |
$stars = "";
|
562 |
$new_filename = explode('***', $new_filename);
|
563 |
for ( $j = 0; $j < $new_filename[1]; $j++ ) {
|
564 |
-
$stars .= '<img id="' . $element_label . '_star_' . $j . '" src="' .
|
565 |
}
|
566 |
for ( $k = $new_filename[1]; $k < $new_filename[0]; $k++ ) {
|
567 |
-
$stars .= '<img id="' . $element_label . '_star_' . $k . '" src="' .
|
568 |
}
|
569 |
array_push($view_star_rating_array, $stars);
|
570 |
|
@@ -594,10 +594,10 @@ class FMModelSubmissions_fmc {
|
|
594 |
$element_value1 = str_replace("***star_rating***", '', $element_value);
|
595 |
$stars_value = explode('/', $element_value1);
|
596 |
for ( $j = 0; $j < $stars_value[0]; $j++ ) {
|
597 |
-
$edit_stars .= '<img id="' . $label_id . '_star_' . $j . '" onclick="edit_star_rating(' . $j . ',' . $label_id . ')" src="' .
|
598 |
}
|
599 |
for ( $k = $stars_value[0]; $k < $stars_value[1]; $k++ ) {
|
600 |
-
$edit_stars .= '<img id="' . $label_id . '_star_' . $k . '" onclick="edit_star_rating(' . $k . ',' . $label_id . ')" src="' .
|
601 |
}
|
602 |
array_push($star_rating_array, $edit_stars);
|
603 |
array_push($star_rating_array, $stars_value);
|
@@ -760,6 +760,7 @@ class FMModelSubmissions_fmc {
|
|
760 |
public function select_data_from_db_for_labels( $db_info, $label_column, $table, $where, $order_by ) {
|
761 |
global $wpdb;
|
762 |
$query = "SELECT `" . $label_column . "` FROM " . $table . $where . " ORDER BY " . $order_by;
|
|
|
763 |
if ( $db_info ) {
|
764 |
$temp = explode('@@@wdfhostwdf@@@', $db_info);
|
765 |
$host = $temp[0];
|
@@ -784,6 +785,7 @@ class FMModelSubmissions_fmc {
|
|
784 |
public function select_data_from_db_for_values( $db_info, $value_column, $table, $where, $order_by ) {
|
785 |
global $wpdb;
|
786 |
$query = "SELECT `" . $value_column . "` FROM " . $table . $where . " ORDER BY " . $order_by;
|
|
|
787 |
if ( $db_info ) {
|
788 |
$temp = explode('@@@wdfhostwdf@@@', $db_info);
|
789 |
$host = $temp[0];
|
3 |
/**
|
4 |
* Class FMModelSubmissions_fmc
|
5 |
*/
|
6 |
+
class FMModelSubmissions_fmc extends CFMAdminModel {
|
7 |
public function blocked_ips() {
|
8 |
global $wpdb;
|
9 |
$ips = $wpdb->get_col('SELECT ip FROM ' . $wpdb->prefix . 'formmaker_blocked');
|
18 |
*/
|
19 |
public function get_forms() {
|
20 |
global $wpdb;
|
21 |
+
$query = "SELECT `id`, `title`, `published` FROM " . $wpdb->prefix . "formmaker " . (!WDFMInstance(self::PLUGIN)->is_free ? '' : ' WHERE id' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')') . " ORDER BY `title`";
|
22 |
$results = $wpdb->get_results($query);
|
23 |
$forms = array();
|
24 |
if( !empty($results) ) {
|
561 |
$stars = "";
|
562 |
$new_filename = explode('***', $new_filename);
|
563 |
for ( $j = 0; $j < $new_filename[1]; $j++ ) {
|
564 |
+
$stars .= '<img id="' . $element_label . '_star_' . $j . '" src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/star_' . $new_filename[2] . '.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" /> ';
|
565 |
}
|
566 |
for ( $k = $new_filename[1]; $k < $new_filename[0]; $k++ ) {
|
567 |
+
$stars .= '<img id="' . $element_label . '_star_' . $k . '" src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/star.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" /> ';
|
568 |
}
|
569 |
array_push($view_star_rating_array, $stars);
|
570 |
|
594 |
$element_value1 = str_replace("***star_rating***", '', $element_value);
|
595 |
$stars_value = explode('/', $element_value1);
|
596 |
for ( $j = 0; $j < $stars_value[0]; $j++ ) {
|
597 |
+
$edit_stars .= '<img id="' . $label_id . '_star_' . $j . '" onclick="edit_star_rating(' . $j . ',' . $label_id . ')" src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/star_yellow.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" /> ';
|
598 |
}
|
599 |
for ( $k = $stars_value[0]; $k < $stars_value[1]; $k++ ) {
|
600 |
+
$edit_stars .= '<img id="' . $label_id . '_star_' . $k . '" onclick="edit_star_rating(' . $k . ',' . $label_id . ')" src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/star.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" /> ';
|
601 |
}
|
602 |
array_push($star_rating_array, $edit_stars);
|
603 |
array_push($star_rating_array, $stars_value);
|
760 |
public function select_data_from_db_for_labels( $db_info, $label_column, $table, $where, $order_by ) {
|
761 |
global $wpdb;
|
762 |
$query = "SELECT `" . $label_column . "` FROM " . $table . $where . " ORDER BY " . $order_by;
|
763 |
+
$db_info = trim($db_info, '[]');
|
764 |
if ( $db_info ) {
|
765 |
$temp = explode('@@@wdfhostwdf@@@', $db_info);
|
766 |
$host = $temp[0];
|
785 |
public function select_data_from_db_for_values( $db_info, $value_column, $table, $where, $order_by ) {
|
786 |
global $wpdb;
|
787 |
$query = "SELECT `" . $value_column . "` FROM " . $table . $where . " ORDER BY " . $order_by;
|
788 |
+
$db_info = trim($db_info, '[]');
|
789 |
if ( $db_info ) {
|
790 |
$temp = explode('@@@wdfhostwdf@@@', $db_info);
|
791 |
$host = $temp[0];
|
admin/models/Themes_fm.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
class FMModelThemes_fmc {
|
4 |
/**
|
5 |
* Get rows data.
|
6 |
*
|
1 |
<?php
|
2 |
|
3 |
+
class FMModelThemes_fmc extends CFMAdminModel {
|
4 |
/**
|
5 |
* Get rows data.
|
6 |
*
|
admin/models/Uninstall_fm.php
CHANGED
@@ -1,13 +1,13 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
class FMModelUninstall_fmc {
|
4 |
public function delete_db_tables() {
|
5 |
global $wpdb;
|
6 |
-
$true_or_false_forms = !
|
7 |
if ($true_or_false_forms) {
|
8 |
-
$wpdb->query('DELETE FROM ' . $wpdb->prefix . 'formmaker WHERE `id`' . (
|
9 |
-
$wpdb->query('DELETE FROM ' . $wpdb->prefix . 'formmaker_submits WHERE `form_id`' . (
|
10 |
-
$wpdb->query('DELETE FROM ' . $wpdb->prefix . 'formmaker_views WHERE `form_id`' . (
|
11 |
}
|
12 |
else {
|
13 |
$email_verification_post_id = $wpdb->get_var('SELECT mail_verification_post_id FROM ' . $wpdb->prefix . 'formmaker WHERE mail_verification_post_id != 0');
|
@@ -51,6 +51,7 @@ class FMModelUninstall_fmc {
|
|
51 |
}
|
52 |
}
|
53 |
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker');
|
|
|
54 |
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker_submits');
|
55 |
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker_views');
|
56 |
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker_themes');
|
1 |
<?php
|
2 |
|
3 |
+
class FMModelUninstall_fmc extends CFMAdminModel {
|
4 |
public function delete_db_tables() {
|
5 |
global $wpdb;
|
6 |
+
$true_or_false_forms = !WDFMInstance(self::PLUGIN)->is_free ? false : $wpdb->get_var('SELECT COUNT(*) FROM ' . $wpdb->prefix . 'formmaker WHERE `id`' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')');
|
7 |
if ($true_or_false_forms) {
|
8 |
+
$wpdb->query('DELETE FROM ' . $wpdb->prefix . 'formmaker WHERE `id`' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')');
|
9 |
+
$wpdb->query('DELETE FROM ' . $wpdb->prefix . 'formmaker_submits WHERE `form_id`' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')');
|
10 |
+
$wpdb->query('DELETE FROM ' . $wpdb->prefix . 'formmaker_views WHERE `form_id`' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')');
|
11 |
}
|
12 |
else {
|
13 |
$email_verification_post_id = $wpdb->get_var('SELECT mail_verification_post_id FROM ' . $wpdb->prefix . 'formmaker WHERE mail_verification_post_id != 0');
|
51 |
}
|
52 |
}
|
53 |
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker');
|
54 |
+
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker_groups');
|
55 |
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker_submits');
|
56 |
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker_views');
|
57 |
$wpdb->query('DROP TABLE IF EXISTS ' . $wpdb->prefix . 'formmaker_themes');
|
admin/models/Widget.php
CHANGED
@@ -4,11 +4,16 @@
|
|
4 |
* Class FMModelWidget_fmc
|
5 |
*/
|
6 |
class FMModelWidget_fmc {
|
|
|
|
|
|
|
|
|
|
|
7 |
public function get_gallery_rows_data() {
|
8 |
global $wpdb;
|
9 |
$query = 'SELECT * FROM ' . $wpdb->prefix . 'formmaker';
|
10 |
-
if (
|
11 |
-
$query .= (!
|
12 |
}
|
13 |
$query .= ' order by `title`';
|
14 |
$rows = $wpdb->get_results($query);
|
4 |
* Class FMModelWidget_fmc
|
5 |
*/
|
6 |
class FMModelWidget_fmc {
|
7 |
+
/**
|
8 |
+
* PLUGIN = 2 points to Contact Form Maker
|
9 |
+
*/
|
10 |
+
const PLUGIN = 2;
|
11 |
+
|
12 |
public function get_gallery_rows_data() {
|
13 |
global $wpdb;
|
14 |
$query = 'SELECT * FROM ' . $wpdb->prefix . 'formmaker';
|
15 |
+
if ( WDFMInstance(self::PLUGIN)->is_free && !class_exists('WDFM') ) {
|
16 |
+
$query .= (!WDFMInstance(self::PLUGIN)->is_free ? '' : ' WHERE id' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')');
|
17 |
}
|
18 |
$query .= ' order by `title`';
|
19 |
$rows = $wpdb->get_results($query);
|
admin/models/model.php
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Admin model class.
|
4 |
+
*/
|
5 |
+
class CFMAdminModel {
|
6 |
+
/**
|
7 |
+
* PLUGIN = 2 points to Contact Form Maker
|
8 |
+
*/
|
9 |
+
const PLUGIN = 2;
|
10 |
+
}
|
admin/views/Addons_fm.php
ADDED
@@ -0,0 +1,84 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
/**
|
4 |
+
* Class FMViewAddons_fmc
|
5 |
+
*/
|
6 |
+
class FMViewAddons_fmc extends FMAdminView_fmc {
|
7 |
+
/**
|
8 |
+
* FMViewAddons_fm constructor.
|
9 |
+
*/
|
10 |
+
public function __construct() {
|
11 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
12 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-pricing');
|
13 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-admin');
|
14 |
+
}
|
15 |
+
|
16 |
+
public function display( $params = array() ) {
|
17 |
+
$page = $params['page'];
|
18 |
+
$page_url = $params['page_url'];
|
19 |
+
ob_start();
|
20 |
+
echo $this->body($params);
|
21 |
+
// Pass the content to form.
|
22 |
+
$form_attr = array(
|
23 |
+
'id' => WDFMInstance(self::PLUGIN)->prefix . '_addons',
|
24 |
+
'name' => WDFMInstance(self::PLUGIN)->prefix . '_addons',
|
25 |
+
'class' => WDFMInstance(self::PLUGIN)->prefix . '_addons wd-form',
|
26 |
+
'action' => add_query_arg( array('page' => $page, 'task' => 'display'), $page_url),
|
27 |
+
);
|
28 |
+
echo $this->form(ob_get_clean(), $form_attr);
|
29 |
+
}
|
30 |
+
|
31 |
+
/**
|
32 |
+
* Generate page body.
|
33 |
+
*
|
34 |
+
* @return string Body html.
|
35 |
+
*/
|
36 |
+
public function body( $params = array() ) {
|
37 |
+
$addons = $params['addons'];
|
38 |
+
echo '<div class="fm-add-ons">';
|
39 |
+
if ( $addons ) {
|
40 |
+
foreach ($addons as $value) {
|
41 |
+
foreach ( $value as $addon ) {
|
42 |
+
$activated = false;
|
43 |
+
if ( is_plugin_active( $addon['dir'] ) ) {
|
44 |
+
$activated = true;
|
45 |
+
}
|
46 |
+
$premium_version = ( WDFMInstance(self::PLUGIN)->is_free && $addon['pro'] ) ? true : false;
|
47 |
+
?>
|
48 |
+
<div class="fm-add-on<?php echo (!$premium_version) ? ' fm-not-premium-version' : ''; echo ( $activated ) ? ' fm-add-on-activated': ''?>">
|
49 |
+
<div class="fm-add-on-img">
|
50 |
+
<?php if ( $activated ) { ?><a href="<?php echo $addon['url'] ?>" target="_blank"><?php } ?>
|
51 |
+
<img src="<?php echo $addon['icon'] ?>" alt="<?php echo $addon['name'] ?>"/>
|
52 |
+
<?php if ( $activated ) { ?></a><?php } ?>
|
53 |
+
</div>
|
54 |
+
<h2 class="fm-add-on-name">
|
55 |
+
<?php if ( $activated ) { ?>
|
56 |
+
<a href="<?php echo $addon['url'] ?>" target="_blank"><?php echo $addon['name'] ?></a>
|
57 |
+
<?php }
|
58 |
+
else { echo $addon['name']; } ?>
|
59 |
+
</h2>
|
60 |
+
<p class="fm-add-on-premium-version">
|
61 |
+
<?php echo $premium_version ? __('Compatible with Premium version only', WDFMInstance(self::PLUGIN)->prefix) : ' '; ?>
|
62 |
+
</p>
|
63 |
+
<div class="fm-add-on-desc-more-wrap">
|
64 |
+
<div class="fm-add-on-desc">
|
65 |
+
<?php echo ( strlen($addon['description']) > 83 ) ? mb_substr($addon['description'], 0, 83, "utf-8") .' ...' : $addon['description']; ?>
|
66 |
+
</div>
|
67 |
+
<?php if ( strlen($addon['description']) > 83 ) { ?>
|
68 |
+
<div class="fm-add-on-desc-more"><?php echo $addon['description']; ?></div>
|
69 |
+
<?php } ?>
|
70 |
+
</div>
|
71 |
+
<?php if ( $activated ) { ?>
|
72 |
+
<span class="fm-add-on-buy" target="_blank"><?php _e('Activated', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
73 |
+
<?php } else { ?>
|
74 |
+
<a href="<?php echo $addon['url'] ?>" class="fm-add-on-buy" target="_blank"><?php _e('Get this add on', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
75 |
+
<?php } ?>
|
76 |
+
<a href="<?php echo $addon['url'] ?>" target="_blank" class="fm-add-on-learn-more"><?php _e('Learn More', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
77 |
+
</div>
|
78 |
+
<?php
|
79 |
+
}
|
80 |
+
}
|
81 |
+
}
|
82 |
+
echo '</div>';
|
83 |
+
}
|
84 |
+
}
|
admin/views/Blocked_ips_fm.php
CHANGED
@@ -2,18 +2,18 @@
|
|
2 |
/**
|
3 |
* Class FMViewBlocked_ips_fm
|
4 |
*/
|
5 |
-
class
|
6 |
/**
|
7 |
* FMViewBlocked_ips_fm constructor.
|
8 |
*/
|
9 |
public function __construct() {
|
10 |
-
wp_enqueue_style('
|
11 |
-
wp_enqueue_style('
|
12 |
-
wp_enqueue_style('
|
13 |
-
wp_enqueue_style('
|
14 |
|
15 |
wp_enqueue_script('jquery');
|
16 |
-
wp_enqueue_script('
|
17 |
}
|
18 |
|
19 |
/**
|
@@ -26,7 +26,7 @@ class FMViewBlocked_ips_fm extends FMAdminView_fmc {
|
|
26 |
$form_attr = array(
|
27 |
'id' => 'blocked_ips',
|
28 |
'class' => 'wd-form',
|
29 |
-
'action' => add_query_arg(array('page' => 'blocked_ips' .
|
30 |
);
|
31 |
echo $this->form(ob_get_clean(), $form_attr);
|
32 |
}
|
@@ -48,11 +48,11 @@ class FMViewBlocked_ips_fm extends FMAdminView_fmc {
|
|
48 |
|
49 |
$page_url = add_query_arg(array(
|
50 |
'page' => $page,
|
51 |
-
|
52 |
), admin_url('admin.php'));
|
53 |
|
54 |
echo $this->title(array(
|
55 |
-
'title' => __('Blocked IPs',
|
56 |
'title_class' => 'wd-header',
|
57 |
'add_new_button' => FALSE,
|
58 |
));
|
@@ -70,18 +70,18 @@ class FMViewBlocked_ips_fm extends FMAdminView_fmc {
|
|
70 |
<thead>
|
71 |
<tr>
|
72 |
<td id="cb" class="manage-column column-cb check-column">
|
73 |
-
<label class="screen-reader-text" for="cb-select-all-1"><?php _e('Select all',
|
74 |
<input id="check_all" type="checkbox" />
|
75 |
</td>
|
76 |
-
<?php echo
|
77 |
</tr>
|
78 |
<tr id="tr">
|
79 |
<th></th>
|
80 |
|
81 |
<td>
|
82 |
<input type="text" class="input_th" id="fm_ip" name="ip" onkeypress="fm_enter_ip(event); return fm_check_isnum(event)">
|
83 |
-
<input type = button class="button action" id="add_ip" onclick="if (fm_check_required('fm_ip', '<?php _e('IP',
|
84 |
-
<div class="loading"><img src="<?php echo
|
85 |
</td>
|
86 |
</tr>
|
87 |
|
@@ -97,23 +97,23 @@ class FMViewBlocked_ips_fm extends FMAdminView_fmc {
|
|
97 |
<input id="check_<?php echo $row_data->id; ?>" name="check[<?php echo $row_data->id; ?>]" type="checkbox" />
|
98 |
</th>
|
99 |
|
100 |
-
<td class="column-primary" id="td_ip_<?php echo $row_data->id; ?>" data-colname="<?php _e('IP',
|
101 |
|
102 |
<strong class="wd_ip_name_<?php echo $row_data->id; ?>">
|
103 |
<a class="pointer" id="ip<?php echo $row_data->id; ?>" onclick="fm_edit_ip(<?php echo $row_data->id; ?>)" title="Edit"><?php echo $row_data->ip; ?></a>
|
104 |
|
105 |
</strong>
|
106 |
-
<div class="loading"><img src="<?php echo
|
107 |
|
108 |
<div class="row-actions">
|
109 |
|
110 |
<span id="td_edit_<?php echo $row_data->id; ?>">
|
111 |
-
<a class="pointer" onclick="fm_edit_ip(<?php echo $row_data->id; ?>);"> <?php _e('Edit',
|
112 |
|
|
113 |
</span>
|
114 |
|
115 |
<span class="trash" id="td_delete_<?php echo $row_data->id; ?>">
|
116 |
-
<a class="pointer" onclick="if (!confirm('<?php echo addslashes(__('Do you want to delete selected item?',
|
117 |
</span>
|
118 |
</div>
|
119 |
</td>
|
@@ -122,7 +122,7 @@ class FMViewBlocked_ips_fm extends FMAdminView_fmc {
|
|
122 |
}
|
123 |
}
|
124 |
else {
|
125 |
-
echo
|
126 |
}
|
127 |
?>
|
128 |
</tbody>
|
2 |
/**
|
3 |
* Class FMViewBlocked_ips_fm
|
4 |
*/
|
5 |
+
class FMViewBlocked_ips_fmc extends FMAdminView_fmc {
|
6 |
/**
|
7 |
* FMViewBlocked_ips_fm constructor.
|
8 |
*/
|
9 |
public function __construct() {
|
10 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-tables');
|
11 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-first');
|
12 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
13 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-layout');
|
14 |
|
15 |
wp_enqueue_script('jquery');
|
16 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-admin');
|
17 |
}
|
18 |
|
19 |
/**
|
26 |
$form_attr = array(
|
27 |
'id' => 'blocked_ips',
|
28 |
'class' => 'wd-form',
|
29 |
+
'action' => add_query_arg(array('page' => 'blocked_ips' . WDFMInstance(self::PLUGIN)->menu_postfix), 'admin.php'),
|
30 |
);
|
31 |
echo $this->form(ob_get_clean(), $form_attr);
|
32 |
}
|
48 |
|
49 |
$page_url = add_query_arg(array(
|
50 |
'page' => $page,
|
51 |
+
WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce),
|
52 |
), admin_url('admin.php'));
|
53 |
|
54 |
echo $this->title(array(
|
55 |
+
'title' => __('Blocked IPs', WDFMInstance(self::PLUGIN)->prefix),
|
56 |
'title_class' => 'wd-header',
|
57 |
'add_new_button' => FALSE,
|
58 |
));
|
70 |
<thead>
|
71 |
<tr>
|
72 |
<td id="cb" class="manage-column column-cb check-column">
|
73 |
+
<label class="screen-reader-text" for="cb-select-all-1"><?php _e('Select all', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
74 |
<input id="check_all" type="checkbox" />
|
75 |
</td>
|
76 |
+
<?php echo WDW_FM_Library(self::PLUGIN)->ordering('ip', $orderby, $order, __('IP', WDFMInstance(self::PLUGIN)->prefix), $page_url, 'column-primary col_type wd-left'); ?>
|
77 |
</tr>
|
78 |
<tr id="tr">
|
79 |
<th></th>
|
80 |
|
81 |
<td>
|
82 |
<input type="text" class="input_th" id="fm_ip" name="ip" onkeypress="fm_enter_ip(event); return fm_check_isnum(event)">
|
83 |
+
<input type = button class="button action" id="add_ip" onclick="if (fm_check_required('fm_ip', '<?php _e('IP', WDFMInstance(self::PLUGIN)->prefix); ?>')) {return false;} fm_insert_blocked_ip('blocked_ips'); " value="<?php _e('Add IP', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
84 |
+
<div class="loading"><img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url ?>/images/loading.gif"></div>
|
85 |
</td>
|
86 |
</tr>
|
87 |
|
97 |
<input id="check_<?php echo $row_data->id; ?>" name="check[<?php echo $row_data->id; ?>]" type="checkbox" />
|
98 |
</th>
|
99 |
|
100 |
+
<td class="column-primary" id="td_ip_<?php echo $row_data->id; ?>" data-colname="<?php _e('IP', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
101 |
|
102 |
<strong class="wd_ip_name_<?php echo $row_data->id; ?>">
|
103 |
<a class="pointer" id="ip<?php echo $row_data->id; ?>" onclick="fm_edit_ip(<?php echo $row_data->id; ?>)" title="Edit"><?php echo $row_data->ip; ?></a>
|
104 |
|
105 |
</strong>
|
106 |
+
<div class="loading"><img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url ?>/images/loading.gif"></div>
|
107 |
|
108 |
<div class="row-actions">
|
109 |
|
110 |
<span id="td_edit_<?php echo $row_data->id; ?>">
|
111 |
+
<a class="pointer" onclick="fm_edit_ip(<?php echo $row_data->id; ?>);"> <?php _e('Edit', WDFMInstance(self::PLUGIN)->prefix); ?> </a>
|
112 |
|
|
113 |
</span>
|
114 |
|
115 |
<span class="trash" id="td_delete_<?php echo $row_data->id; ?>">
|
116 |
+
<a class="pointer" onclick="if (!confirm('<?php echo addslashes(__('Do you want to delete selected item?', WDFMInstance(self::PLUGIN)->prefix)); ?>')) {return false;} fm_delete_ip(<?php echo $row_data->id; ?>) "><?php _e('Delete', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
117 |
</span>
|
118 |
</div>
|
119 |
</td>
|
122 |
}
|
123 |
}
|
124 |
else {
|
125 |
+
echo WDW_FM_Library(self::PLUGIN)->no_items('IPs');
|
126 |
}
|
127 |
?>
|
128 |
</tbody>
|
admin/views/Checkpaypal.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewCheckpaypal
|
5 |
*/
|
6 |
-
class FMViewCheckpaypal {
|
7 |
/**
|
8 |
* Payment information template.
|
9 |
*
|
@@ -22,75 +22,75 @@ class FMViewCheckpaypal {
|
|
22 |
?>
|
23 |
<table class="admintable" border="1">
|
24 |
<tr>
|
25 |
-
<td class="key"><?php _e('Currency',
|
26 |
<td><?php echo $currency; ?></td>
|
27 |
</tr>
|
28 |
<tr>
|
29 |
-
<td class="key"><?php _e('Date',
|
30 |
<td><?php echo $form_session->ord_last_modified; ?></td>
|
31 |
</tr>
|
32 |
<tr>
|
33 |
-
<td class="key"><?php _e('Status',
|
34 |
<td><?php echo $form_session->status; ?></td>
|
35 |
</tr>
|
36 |
<tr>
|
37 |
-
<td class="key"><?php _e('Full name',
|
38 |
<td><?php echo $form_session->full_name; ?></td>
|
39 |
</tr>
|
40 |
<tr>
|
41 |
-
<td class="key"><?php _e('Email',
|
42 |
<td><?php echo $form_session->email; ?></td>
|
43 |
</tr>
|
44 |
<tr>
|
45 |
-
<td class="key"><?php _e('Phone',
|
46 |
<td><?php echo $form_session->phone; ?></td>
|
47 |
</tr>
|
48 |
<tr>
|
49 |
-
<td class="key"><?php _e('Mobile phone',
|
50 |
<td><?php echo $form_session->mobile_phone; ?></td>
|
51 |
</tr>
|
52 |
<tr>
|
53 |
-
<td class="key"><?php _e('Fax',
|
54 |
<td><?php echo $form_session->fax; ?></td>
|
55 |
</tr>
|
56 |
<tr>
|
57 |
-
<td class="key"><?php _e('Address',
|
58 |
<td><?php echo $form_session->address; ?></td>
|
59 |
</tr>
|
60 |
<tr>
|
61 |
-
<td class="key"><?php _e('Payment info',
|
62 |
<td><?php echo $form_session->paypal_info; ?></td>
|
63 |
</tr>
|
64 |
<tr>
|
65 |
-
<td class="key"><?php _e('IPN',
|
66 |
<td><?php echo $form_session->ipn; ?></td>
|
67 |
</tr>
|
68 |
<tr>
|
69 |
-
<td class="key"><?php _e('tax',
|
70 |
<td><?php echo $form_session->tax; ?>%</td>
|
71 |
</tr>
|
72 |
<tr>
|
73 |
-
<td class="key"><?php _e('shipping',
|
74 |
<td><?php echo $form_session->shipping; ?></td>
|
75 |
</tr>
|
76 |
<tr>
|
77 |
-
<td class="key"><?php _e('read',
|
78 |
<td><?php echo $form_session->read; ?></td>
|
79 |
</tr>
|
80 |
<tr>
|
81 |
-
<td class="key"><b><?php _e('Item total',
|
82 |
<td><?php echo ($total - $tax - $shipping) . $currency; ?></td>
|
83 |
</tr>
|
84 |
<tr>
|
85 |
-
<td class="key"><b><?php _e('Tax',
|
86 |
<td> <?php echo $tax . $currency; ?></td>
|
87 |
</tr>
|
88 |
<tr>
|
89 |
-
<td class="key"><b><?php _e('Shipping and handling',
|
90 |
<td><?php echo $shipping . $currency; ?></td>
|
91 |
</tr>
|
92 |
<tr>
|
93 |
-
<td class="key"><b><?php _e('Total',
|
94 |
<td><?php echo $total . $currency; ?></td>
|
95 |
</tr>
|
96 |
</table>
|
3 |
/**
|
4 |
* Class FMViewCheckpaypal
|
5 |
*/
|
6 |
+
class FMViewCheckpaypal extends FMAdminView_fmc {
|
7 |
/**
|
8 |
* Payment information template.
|
9 |
*
|
22 |
?>
|
23 |
<table class="admintable" border="1">
|
24 |
<tr>
|
25 |
+
<td class="key"><?php _e('Currency', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
26 |
<td><?php echo $currency; ?></td>
|
27 |
</tr>
|
28 |
<tr>
|
29 |
+
<td class="key"><?php _e('Date', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
30 |
<td><?php echo $form_session->ord_last_modified; ?></td>
|
31 |
</tr>
|
32 |
<tr>
|
33 |
+
<td class="key"><?php _e('Status', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
34 |
<td><?php echo $form_session->status; ?></td>
|
35 |
</tr>
|
36 |
<tr>
|
37 |
+
<td class="key"><?php _e('Full name', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
38 |
<td><?php echo $form_session->full_name; ?></td>
|
39 |
</tr>
|
40 |
<tr>
|
41 |
+
<td class="key"><?php _e('Email', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
42 |
<td><?php echo $form_session->email; ?></td>
|
43 |
</tr>
|
44 |
<tr>
|
45 |
+
<td class="key"><?php _e('Phone', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
46 |
<td><?php echo $form_session->phone; ?></td>
|
47 |
</tr>
|
48 |
<tr>
|
49 |
+
<td class="key"><?php _e('Mobile phone', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
50 |
<td><?php echo $form_session->mobile_phone; ?></td>
|
51 |
</tr>
|
52 |
<tr>
|
53 |
+
<td class="key"><?php _e('Fax', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
54 |
<td><?php echo $form_session->fax; ?></td>
|
55 |
</tr>
|
56 |
<tr>
|
57 |
+
<td class="key"><?php _e('Address', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
58 |
<td><?php echo $form_session->address; ?></td>
|
59 |
</tr>
|
60 |
<tr>
|
61 |
+
<td class="key"><?php _e('Payment info', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
62 |
<td><?php echo $form_session->paypal_info; ?></td>
|
63 |
</tr>
|
64 |
<tr>
|
65 |
+
<td class="key"><?php _e('IPN', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
66 |
<td><?php echo $form_session->ipn; ?></td>
|
67 |
</tr>
|
68 |
<tr>
|
69 |
+
<td class="key"><?php _e('tax', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
70 |
<td><?php echo $form_session->tax; ?>%</td>
|
71 |
</tr>
|
72 |
<tr>
|
73 |
+
<td class="key"><?php _e('shipping', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
74 |
<td><?php echo $form_session->shipping; ?></td>
|
75 |
</tr>
|
76 |
<tr>
|
77 |
+
<td class="key"><?php _e('read', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
78 |
<td><?php echo $form_session->read; ?></td>
|
79 |
</tr>
|
80 |
<tr>
|
81 |
+
<td class="key"><b><?php _e('Item total', WDFMInstance(self::PLUGIN)->prefix); ?></b></td>
|
82 |
<td><?php echo ($total - $tax - $shipping) . $currency; ?></td>
|
83 |
</tr>
|
84 |
<tr>
|
85 |
+
<td class="key"><b><?php _e('Tax', WDFMInstance(self::PLUGIN)->prefix); ?></b></td>
|
86 |
<td> <?php echo $tax . $currency; ?></td>
|
87 |
</tr>
|
88 |
<tr>
|
89 |
+
<td class="key"><b><?php _e('Shipping and handling', WDFMInstance(self::PLUGIN)->prefix); ?></b></td>
|
90 |
<td><?php echo $shipping . $currency; ?></td>
|
91 |
</tr>
|
92 |
<tr>
|
93 |
+
<td class="key"><b><?php _e('Total', WDFMInstance(self::PLUGIN)->prefix); ?></b></td>
|
94 |
<td><?php echo $total . $currency; ?></td>
|
95 |
</tr>
|
96 |
</table>
|
admin/views/FMCaptcha.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
class FMViewFormmakerwdcaptcha_fmc {
|
4 |
|
5 |
/**
|
6 |
* Display.
|
@@ -8,7 +8,7 @@ class FMViewFormmakerwdcaptcha_fmc {
|
|
8 |
* @param array $params
|
9 |
*/
|
10 |
public function display( $params ) {
|
11 |
-
if (isset($_GET['action']) && esc_html($_GET['action']) == 'formmakerwdcaptcha' .
|
12 |
$i = (isset($_GET["i"]) ? esc_html($_GET["i"]) : '');
|
13 |
$r2 = (isset($_GET["r2"]) ? (int) $_GET["r2"] : 0);
|
14 |
$rrr = (isset($_GET["rrr"]) ? (int) $_GET["rrr"] : 0);
|
@@ -38,7 +38,7 @@ class FMViewFormmakerwdcaptcha_fmc {
|
|
38 |
|
39 |
$l = rand($cap_length_min, $cap_length_max);
|
40 |
$code = code_generic($l, $cap_digital, $cap_latin_char);
|
41 |
-
|
42 |
$_SESSION[$i . '_wd_captcha_code'] = md5($code);
|
43 |
$canvas = imagecreatetruecolor($cap_width, $cap_height);
|
44 |
$c = imagecolorallocate($canvas, rand(150, 255), rand(150, 255), rand(150, 255));
|
1 |
<?php
|
2 |
|
3 |
+
class FMViewFormmakerwdcaptcha_fmc extends FMAdminView_fmc {
|
4 |
|
5 |
/**
|
6 |
* Display.
|
8 |
* @param array $params
|
9 |
*/
|
10 |
public function display( $params ) {
|
11 |
+
if (isset($_GET['action']) && esc_html($_GET['action']) == 'formmakerwdcaptcha' . WDFMInstance(self::PLUGIN)->plugin_postfix) {
|
12 |
$i = (isset($_GET["i"]) ? esc_html($_GET["i"]) : '');
|
13 |
$r2 = (isset($_GET["r2"]) ? (int) $_GET["r2"] : 0);
|
14 |
$rrr = (isset($_GET["rrr"]) ? (int) $_GET["rrr"] : 0);
|
38 |
|
39 |
$l = rand($cap_length_min, $cap_length_max);
|
40 |
$code = code_generic($l, $cap_digital, $cap_latin_char);
|
41 |
+
WDW_FM_Library(self::PLUGIN)->start_session();
|
42 |
$_SESSION[$i . '_wd_captcha_code'] = md5($code);
|
43 |
$canvas = imagecreatetruecolor($cap_width, $cap_height);
|
44 |
$c = imagecolorallocate($canvas, rand(150, 255), rand(150, 255), rand(150, 255));
|
admin/views/FMEditCountryinPopup.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewFromeditcountryinpopup_fmc
|
5 |
*/
|
6 |
-
class FMViewFromeditcountryinpopup_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
@@ -51,21 +51,21 @@ class FMViewFromeditcountryinpopup_fmc {
|
|
51 |
<div class="country-list wp-core-ui">
|
52 |
<div class="select-remove">
|
53 |
<button class="button" onclick="toggleCheck(true); return false;">
|
54 |
-
<?php _e('Select all',
|
55 |
</button>
|
56 |
<button class="button" onclick="toggleCheck(false); return false;">
|
57 |
-
<?php _e('Remove all',
|
58 |
</button>
|
59 |
</div>
|
60 |
<div class="save-cancel">
|
61 |
<button class="button button-primary" onclick="save_list(); return false;">
|
62 |
-
<?php _e('Save',
|
63 |
</button>
|
64 |
</div>
|
65 |
<ul id="countries_list" class="ui-sortable" style="list-style: none; padding: 0px;"></ul>
|
66 |
</div>
|
67 |
<script>
|
68 |
-
var countries = '<?php echo addslashes(json_encode(
|
69 |
countries = JSON.parse(countries);
|
70 |
var select_ = window.parent.document.getElementById('<?php echo $field_id ?>_elementform_id_temp');
|
71 |
var n = select_.childNodes.length;
|
3 |
/**
|
4 |
* Class FMViewFromeditcountryinpopup_fmc
|
5 |
*/
|
6 |
+
class FMViewFromeditcountryinpopup_fmc extends FMAdminView_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
51 |
<div class="country-list wp-core-ui">
|
52 |
<div class="select-remove">
|
53 |
<button class="button" onclick="toggleCheck(true); return false;">
|
54 |
+
<?php _e('Select all', WDFMInstance(self::PLUGIN)->prefix); ?>
|
55 |
</button>
|
56 |
<button class="button" onclick="toggleCheck(false); return false;">
|
57 |
+
<?php _e('Remove all', WDFMInstance(self::PLUGIN)->prefix); ?>
|
58 |
</button>
|
59 |
</div>
|
60 |
<div class="save-cancel">
|
61 |
<button class="button button-primary" onclick="save_list(); return false;">
|
62 |
+
<?php _e('Save', WDFMInstance(self::PLUGIN)->prefix); ?>
|
63 |
</button>
|
64 |
</div>
|
65 |
<ul id="countries_list" class="ui-sortable" style="list-style: none; padding: 0px;"></ul>
|
66 |
</div>
|
67 |
<script>
|
68 |
+
var countries = '<?php echo addslashes(json_encode(WDW_FM_Library(self::PLUGIN)->get_countries())); ?>';
|
69 |
countries = JSON.parse(countries);
|
70 |
var select_ = window.parent.document.getElementById('<?php echo $field_id ?>_elementform_id_temp');
|
71 |
var n = select_.childNodes.length;
|
admin/views/FMIpinfoinPopup.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewFromipinfoinpopup_fmc
|
5 |
*/
|
6 |
-
class FMViewFromipinfoinpopup_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
@@ -40,31 +40,31 @@ class FMViewFromipinfoinpopup_fmc {
|
|
40 |
</style>
|
41 |
<table class="admintable">
|
42 |
<tr>
|
43 |
-
<td class="key"><b><?php _e('IP',
|
44 |
<td><?php echo $ip; ?></td>
|
45 |
</tr>
|
46 |
<tr>
|
47 |
-
<td class="key"><b><?php _e('City',
|
48 |
<td><?php echo $city; ?></td>
|
49 |
</tr>
|
50 |
<tr>
|
51 |
-
<td class="key"><b><?php _e('Country',
|
52 |
<td><?php echo $country . ' ' . $country_flag; ?></td>
|
53 |
</tr>
|
54 |
<tr>
|
55 |
-
<td class="key"><b><?php _e('CountryCode',
|
56 |
<td><?php echo $countryCode; ?></td>
|
57 |
</tr>
|
58 |
<tr>
|
59 |
-
<td class="key"><b><?php _e('Timezone',
|
60 |
<td><?php echo $timezone; ?></td>
|
61 |
</tr>
|
62 |
<tr>
|
63 |
-
<td class="key"><b><?php _e('Latitude',
|
64 |
<td><?php echo $lat; ?></td>
|
65 |
</tr>
|
66 |
<tr>
|
67 |
-
<td class="key"><b><?php _e('Longitude',
|
68 |
<td><?php echo $lon; ?></td>
|
69 |
</tr>
|
70 |
</table>
|
3 |
/**
|
4 |
* Class FMViewFromipinfoinpopup_fmc
|
5 |
*/
|
6 |
+
class FMViewFromipinfoinpopup_fmc extends FMAdminView_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
40 |
</style>
|
41 |
<table class="admintable">
|
42 |
<tr>
|
43 |
+
<td class="key"><b><?php _e('IP', WDFMInstance(self::PLUGIN)->prefix); ?>:</b></td>
|
44 |
<td><?php echo $ip; ?></td>
|
45 |
</tr>
|
46 |
<tr>
|
47 |
+
<td class="key"><b><?php _e('City', WDFMInstance(self::PLUGIN)->prefix); ?>:</b></td>
|
48 |
<td><?php echo $city; ?></td>
|
49 |
</tr>
|
50 |
<tr>
|
51 |
+
<td class="key"><b><?php _e('Country', WDFMInstance(self::PLUGIN)->prefix); ?>:</b></td>
|
52 |
<td><?php echo $country . ' ' . $country_flag; ?></td>
|
53 |
</tr>
|
54 |
<tr>
|
55 |
+
<td class="key"><b><?php _e('CountryCode', WDFMInstance(self::PLUGIN)->prefix); ?>:</b></td>
|
56 |
<td><?php echo $countryCode; ?></td>
|
57 |
</tr>
|
58 |
<tr>
|
59 |
+
<td class="key"><b><?php _e('Timezone', WDFMInstance(self::PLUGIN)->prefix); ?>:</b></td>
|
60 |
<td><?php echo $timezone; ?></td>
|
61 |
</tr>
|
62 |
<tr>
|
63 |
+
<td class="key"><b><?php _e('Latitude', WDFMInstance(self::PLUGIN)->prefix); ?>:</b></td>
|
64 |
<td><?php echo $lat; ?></td>
|
65 |
</tr>
|
66 |
<tr>
|
67 |
+
<td class="key"><b><?php _e('Longitude', WDFMInstance(self::PLUGIN)->prefix); ?>:</b></td>
|
68 |
<td><?php echo $lon; ?></td>
|
69 |
</tr>
|
70 |
</table>
|
admin/views/FMMapEditinPopup.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewFrommapeditinpopup_fmc
|
5 |
*/
|
6 |
-
class FMViewFrommapeditinpopup_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
@@ -11,21 +11,21 @@ class FMViewFrommapeditinpopup_fmc {
|
|
11 |
*/
|
12 |
public function display( $params ) {
|
13 |
wp_print_scripts('google-maps');
|
14 |
-
wp_print_scripts('
|
15 |
$long = $params['long'];
|
16 |
$lat = $params['lat'];
|
17 |
?>
|
18 |
<table style="margin:0px; padding:0px">
|
19 |
<tr>
|
20 |
-
<td><b><?php _e('Address:',
|
21 |
<td><input type="text" id="addrval0" style="border:0px; background:none" size="80" readonly /></td>
|
22 |
</tr>
|
23 |
<tr>
|
24 |
-
<td><b><?php _e('Longitude:',
|
25 |
<td><input type="text" id="longval0" style="border:0px; background:none" size="80" readonly /></td>
|
26 |
</tr>
|
27 |
<tr>
|
28 |
-
<td><b><?php _e('Latitude:',
|
29 |
<td><input type="text" id="latval0" style="border:0px; background:none" size="80" readonly /></td>
|
30 |
</tr>
|
31 |
</table>
|
3 |
/**
|
4 |
* Class FMViewFrommapeditinpopup_fmc
|
5 |
*/
|
6 |
+
class FMViewFrommapeditinpopup_fmc extends FMAdminView_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
11 |
*/
|
12 |
public function display( $params ) {
|
13 |
wp_print_scripts('google-maps');
|
14 |
+
wp_print_scripts(WDFMInstance(self::PLUGIN)->handle_prefix . '-gmap_form');
|
15 |
$long = $params['long'];
|
16 |
$lat = $params['lat'];
|
17 |
?>
|
18 |
<table style="margin:0px; padding:0px">
|
19 |
<tr>
|
20 |
+
<td><b><?php _e('Address:', WDFMInstance(self::PLUGIN)->prefix); ?></b></td>
|
21 |
<td><input type="text" id="addrval0" style="border:0px; background:none" size="80" readonly /></td>
|
22 |
</tr>
|
23 |
<tr>
|
24 |
+
<td><b><?php _e('Longitude:', WDFMInstance(self::PLUGIN)->prefix); ?></b></td>
|
25 |
<td><input type="text" id="longval0" style="border:0px; background:none" size="80" readonly /></td>
|
26 |
</tr>
|
27 |
<tr>
|
28 |
+
<td><b><?php _e('Latitude:', WDFMInstance(self::PLUGIN)->prefix); ?></b></td>
|
29 |
<td><input type="text" id="latval0" style="border:0px; background:none" size="80" readonly /></td>
|
30 |
</tr>
|
31 |
</table>
|
admin/views/FMMathCaptcha.php
CHANGED
@@ -3,12 +3,12 @@
|
|
3 |
/**
|
4 |
* Class FMViewFormmakerwdmathcaptcha_fmc
|
5 |
*/
|
6 |
-
class FMViewFormmakerwdmathcaptcha_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*/
|
10 |
public function display() {
|
11 |
-
if ( isset($_GET['action']) && esc_html($_GET['action']) == 'formmakerwdmathcaptcha' .
|
12 |
$i = (isset($_GET["i"]) ? esc_html($_GET["i"]) : '');
|
13 |
$r2 = (isset($_GET["r2"]) ? (int) $_GET["r2"] : 0);
|
14 |
$rrr = (isset($_GET["rrr"]) ? (int) $_GET["rrr"] : 0);
|
@@ -20,7 +20,7 @@ class FMViewFormmakerwdmathcaptcha_fmc {
|
|
20 |
$cap_height = 26;
|
21 |
$cap_quality = 100;
|
22 |
$code = $this->code_generic($operations_count, $operations);
|
23 |
-
|
24 |
$_SESSION[$i . '_wd_arithmetic_captcha_code'] = md5($code[1]);
|
25 |
$canvas = imagecreatetruecolor($cap_width, $cap_height);
|
26 |
$c = imagecolorallocate($canvas, rand(150, 255), rand(150, 255), rand(150, 255));
|
3 |
/**
|
4 |
* Class FMViewFormmakerwdmathcaptcha_fmc
|
5 |
*/
|
6 |
+
class FMViewFormmakerwdmathcaptcha_fmc extends FMAdminView_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*/
|
10 |
public function display() {
|
11 |
+
if ( isset($_GET['action']) && esc_html($_GET['action']) == 'formmakerwdmathcaptcha' . WDFMInstance(self::PLUGIN)->plugin_postfix ) {
|
12 |
$i = (isset($_GET["i"]) ? esc_html($_GET["i"]) : '');
|
13 |
$r2 = (isset($_GET["r2"]) ? (int) $_GET["r2"] : 0);
|
14 |
$rrr = (isset($_GET["rrr"]) ? (int) $_GET["rrr"] : 0);
|
20 |
$cap_height = 26;
|
21 |
$cap_quality = 100;
|
22 |
$code = $this->code_generic($operations_count, $operations);
|
23 |
+
WDW_FM_Library(self::PLUGIN)->start_session();
|
24 |
$_SESSION[$i . '_wd_arithmetic_captcha_code'] = md5($code[1]);
|
25 |
$canvas = imagecreatetruecolor($cap_width, $cap_height);
|
26 |
$c = imagecolorallocate($canvas, rand(150, 255), rand(150, 255), rand(150, 255));
|
admin/views/FMPaypalInfo.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewPaypal_info
|
5 |
*/
|
6 |
-
class FMViewPaypal_info {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
3 |
/**
|
4 |
* Class FMViewPaypal_info
|
5 |
*/
|
6 |
+
class FMViewPaypal_info extends FMAdminView {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
admin/views/FMProductOption.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewProduct_option
|
5 |
*/
|
6 |
-
class FMViewProduct_option {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
@@ -89,7 +89,7 @@ class FMViewProduct_option {
|
|
89 |
</div>
|
90 |
<div>
|
91 |
<label class="fm-property-label">Properties</label>
|
92 |
-
<img id="el_choices_add" src="<?php echo
|
93 |
</div>
|
94 |
<div style="margin-left:0px;" id="options"></div>
|
95 |
</div>
|
@@ -241,7 +241,7 @@ class FMViewProduct_option {
|
|
241 |
el_choices.style.cssText = "width:100px; margin:0; padding:4px; border: 1px solid #ccc; vertical-align: middle;";
|
242 |
var el_choices_remove = document.createElement('img');
|
243 |
el_choices_remove.setAttribute("id", "el_option" + j + "_remove");
|
244 |
-
el_choices_remove.setAttribute("src", '<?php echo
|
245 |
el_choices_remove.style.cssText = 'cursor:pointer; vertical-align:middle; margin:2px';
|
246 |
el_choices_remove.setAttribute("align", 'top');
|
247 |
el_choices_remove.setAttribute("onClick", "remove_option(" + j + "," + i + ")");
|
@@ -263,7 +263,7 @@ class FMViewProduct_option {
|
|
263 |
el_choices.style.cssText = "width:100px; margin:0; padding:4px; border: 1px solid #ccc; vertical-align: middle;";
|
264 |
var el_choices_remove = document.createElement('img');
|
265 |
el_choices_remove.setAttribute("id", "el_option" + j + "_remove");
|
266 |
-
el_choices_remove.setAttribute("src", '<?php echo
|
267 |
el_choices_remove.style.cssText = 'cursor:pointer; vertical-align:middle; margin:2px';
|
268 |
el_choices_remove.setAttribute("align", 'top');
|
269 |
el_choices_remove.setAttribute("onClick", "remove_option('" + j + "','" + num + "')");
|
3 |
/**
|
4 |
* Class FMViewProduct_option
|
5 |
*/
|
6 |
+
class FMViewProduct_option extends FMAdminView {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
89 |
</div>
|
90 |
<div>
|
91 |
<label class="fm-property-label">Properties</label>
|
92 |
+
<img id="el_choices_add" src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url . '/images/add.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . ''; ?>" style="vertical-align:middle; cursor: pointer;" title="add" onclick="add_choise_option()" />
|
93 |
</div>
|
94 |
<div style="margin-left:0px;" id="options"></div>
|
95 |
</div>
|
241 |
el_choices.style.cssText = "width:100px; margin:0; padding:4px; border: 1px solid #ccc; vertical-align: middle;";
|
242 |
var el_choices_remove = document.createElement('img');
|
243 |
el_choices_remove.setAttribute("id", "el_option" + j + "_remove");
|
244 |
+
el_choices_remove.setAttribute("src", '<?php echo WDFMInstance(self::PLUGIN)->plugin_url . '/images/delete.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . ''; ?>');
|
245 |
el_choices_remove.style.cssText = 'cursor:pointer; vertical-align:middle; margin:2px';
|
246 |
el_choices_remove.setAttribute("align", 'top');
|
247 |
el_choices_remove.setAttribute("onClick", "remove_option(" + j + "," + i + ")");
|
263 |
el_choices.style.cssText = "width:100px; margin:0; padding:4px; border: 1px solid #ccc; vertical-align: middle;";
|
264 |
var el_choices_remove = document.createElement('img');
|
265 |
el_choices_remove.setAttribute("id", "el_option" + j + "_remove");
|
266 |
+
el_choices_remove.setAttribute("src", '<?php echo WDFMInstance(self::PLUGIN)->plugin_url . '/images/delete.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . ''; ?>');
|
267 |
el_choices_remove.style.cssText = 'cursor:pointer; vertical-align:middle; margin:2px';
|
268 |
el_choices_remove.setAttribute("align", 'top');
|
269 |
el_choices_remove.setAttribute("onClick", "remove_option('" + j + "','" + num + "')");
|
admin/views/FMSelectDataFromDb.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewSelect_data_from_db_fmc
|
5 |
*/
|
6 |
-
class FMViewSelect_data_from_db_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
@@ -11,8 +11,8 @@ class FMViewSelect_data_from_db_fmc {
|
|
11 |
*/
|
12 |
public function display( $params ) {
|
13 |
wp_print_scripts('jquery');
|
14 |
-
wp_print_styles('
|
15 |
-
wp_print_styles('
|
16 |
$id = $params['id'];
|
17 |
$form_id = $params['form_id'];
|
18 |
$field_id = $params['field_id'];
|
@@ -29,7 +29,7 @@ class FMViewSelect_data_from_db_fmc {
|
|
29 |
jQuery.ajax({
|
30 |
type: "POST",
|
31 |
url: "<?php echo add_query_arg(array(
|
32 |
-
'action' => 'select_data_from_db' .
|
33 |
'form_id' => $form_id,
|
34 |
'field_type' => $field_type,
|
35 |
'task' => 'db_tables',
|
@@ -233,7 +233,7 @@ class FMViewSelect_data_from_db_fmc {
|
|
233 |
$cond .= '<option>' . $col->Field . '</option>';
|
234 |
}
|
235 |
$cond .= '</select>';
|
236 |
-
$cond .= '<select id="op_condid" style="width: 110px"><option value="=" selected="selected">=</option><option value="!=">!=</option><option value=">">></option><option value="<"><</option><option value=">=">>=</option><option value="<="><=</option><option value="%..%">Like</option><option value="%..">Starts with</option><option value="..%">Ends with</option></select><input id="val_condid" type="text" /><select id="andor_condid" style="visibility: hidden; width:70px;"><option value="AND">AND</option><option value="OR">OR</option></select><img src="' .
|
237 |
?>
|
238 |
<script>
|
239 |
var selected_field = '';
|
@@ -276,8 +276,8 @@ class FMViewSelect_data_from_db_fmc {
|
|
276 |
});
|
277 |
function save_query() {
|
278 |
str = '';
|
279 |
-
plugin_url = '<?php echo
|
280 |
-
plugin_version = '<?php echo
|
281 |
product_name = jQuery('#product_name').val();
|
282 |
product_price = jQuery('#product_price').val();
|
283 |
con_type = jQuery('input[name=con_type]:checked').val();
|
@@ -516,7 +516,7 @@ class FMViewSelect_data_from_db_fmc {
|
|
516 |
</select>
|
517 |
</div>
|
518 |
<div class="select-db-op where">
|
519 |
-
<img src="<?php echo
|
520 |
</div>
|
521 |
|
522 |
</div>
|
@@ -574,7 +574,7 @@ class FMViewSelect_data_from_db_fmc {
|
|
574 |
jQuery.ajax({
|
575 |
type: "POST",
|
576 |
url: "<?php echo add_query_arg(array(
|
577 |
-
'action' => 'select_data_from_db' .
|
578 |
'form_id' => $form_id,
|
579 |
'field_type' => $field_type,
|
580 |
'task' => 'db_table_struct_select',
|
3 |
/**
|
4 |
* Class FMViewSelect_data_from_db_fmc
|
5 |
*/
|
6 |
+
class FMViewSelect_data_from_db_fmc extends FMAdminView_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
11 |
*/
|
12 |
public function display( $params ) {
|
13 |
wp_print_scripts('jquery');
|
14 |
+
wp_print_styles(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
15 |
+
wp_print_styles(WDFMInstance(self::PLUGIN)->handle_prefix . '-jquery-ui');
|
16 |
$id = $params['id'];
|
17 |
$form_id = $params['form_id'];
|
18 |
$field_id = $params['field_id'];
|
29 |
jQuery.ajax({
|
30 |
type: "POST",
|
31 |
url: "<?php echo add_query_arg(array(
|
32 |
+
'action' => 'select_data_from_db' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
33 |
'form_id' => $form_id,
|
34 |
'field_type' => $field_type,
|
35 |
'task' => 'db_tables',
|
233 |
$cond .= '<option>' . $col->Field . '</option>';
|
234 |
}
|
235 |
$cond .= '</select>';
|
236 |
+
$cond .= '<select id="op_condid" style="width: 110px"><option value="=" selected="selected">=</option><option value="!=">!=</option><option value=">">></option><option value="<"><</option><option value=">=">>=</option><option value="<="><=</option><option value="%..%">Like</option><option value="%..">Starts with</option><option value="..%">Ends with</option></select><input id="val_condid" type="text" /><select id="andor_condid" style="visibility: hidden; width:70px;"><option value="AND">AND</option><option value="OR">OR</option></select><img src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/delete.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" onclick="delete_cond("condid")" style="vertical-align: middle;"></div>';
|
237 |
?>
|
238 |
<script>
|
239 |
var selected_field = '';
|
276 |
});
|
277 |
function save_query() {
|
278 |
str = '';
|
279 |
+
plugin_url = '<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>';
|
280 |
+
plugin_version = '<?php echo WDFMInstance(self::PLUGIN)->plugin_version; ?>';
|
281 |
product_name = jQuery('#product_name').val();
|
282 |
product_price = jQuery('#product_price').val();
|
283 |
con_type = jQuery('input[name=con_type]:checked').val();
|
516 |
</select>
|
517 |
</div>
|
518 |
<div class="select-db-op where">
|
519 |
+
<img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url . '/images/add_condition.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . ''; ?>" title="ADD" class="add_cond" />WHERE
|
520 |
</div>
|
521 |
|
522 |
</div>
|
574 |
jQuery.ajax({
|
575 |
type: "POST",
|
576 |
url: "<?php echo add_query_arg(array(
|
577 |
+
'action' => 'select_data_from_db' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
578 |
'form_id' => $form_id,
|
579 |
'field_type' => $field_type,
|
580 |
'task' => 'db_table_struct_select',
|
admin/views/FMShortocde.php
CHANGED
@@ -3,22 +3,26 @@
|
|
3 |
/**
|
4 |
* Class FMViewFMShortocde_fmc
|
5 |
*/
|
6 |
-
class FMViewFMShortocde_fmc {
|
7 |
/**
|
8 |
* FMViewFMShortocde constructor.
|
9 |
*/
|
10 |
public function __construct() {
|
11 |
-
wp_print_scripts('
|
12 |
|
13 |
wp_print_styles('wp-admin');
|
14 |
wp_print_styles('buttons');
|
15 |
|
16 |
-
wp_print_styles('
|
17 |
-
wp_print_scripts('jquery-ui-datepicker');
|
18 |
|
19 |
-
if (!
|
20 |
-
|
21 |
-
wp_print_styles('
|
|
|
|
|
|
|
|
|
|
|
22 |
}
|
23 |
}
|
24 |
|
@@ -35,12 +39,12 @@ class FMViewFMShortocde_fmc {
|
|
35 |
<div class="wd-box-content wd-box-content-shortcode">
|
36 |
<span class="wd-group">
|
37 |
<select name="form_maker_id">
|
38 |
-
<option value="0"><?php _e('-Select a Form-',
|
39 |
<?php
|
40 |
if ( $forms ) {
|
41 |
foreach ( $forms as $form ) {
|
42 |
?>
|
43 |
-
<option value="<?php echo $form->id; ?>" <?php if (!$form->published) { echo 'disabled="disabled"';} ?>><?php echo $form->title . ($form->published ? '' : ' - ' . __('Unpublished',
|
44 |
<?php
|
45 |
}
|
46 |
}
|
@@ -48,7 +52,7 @@ class FMViewFMShortocde_fmc {
|
|
48 |
</select>
|
49 |
</span>
|
50 |
<span class="wd-group wd-right">
|
51 |
-
<input class="wd-button button-primary" type="button" name="insert" value="<?php _e('Insert',
|
52 |
</span>
|
53 |
</div>
|
54 |
</div>
|
@@ -65,13 +69,11 @@ class FMViewFMShortocde_fmc {
|
|
65 |
*/
|
66 |
public function submissions( $forms ) {
|
67 |
?>
|
68 |
-
<body class="wp-core-ui" data-width="
|
69 |
<?php
|
70 |
-
if (
|
|
|
71 |
?>
|
72 |
-
<div class="wd-fixed-message">
|
73 |
-
<?php echo WDW_FMC_Library::message_id(0, __('Front end submissions are disabled in free version.', WDCFM()->prefix), 'error'); ?>
|
74 |
-
</div>
|
75 |
<div class="wd-fixed-conteiner"></div>
|
76 |
<?php
|
77 |
}
|
@@ -81,12 +83,12 @@ class FMViewFMShortocde_fmc {
|
|
81 |
<div class="wd-box-content wd-box-content-shortcode">
|
82 |
<span class="wd-group">
|
83 |
<select name="form_maker_id">
|
84 |
-
<option value="0"><?php _e('-Select a Form-',
|
85 |
<?php
|
86 |
if ( $forms ) {
|
87 |
foreach ( $forms as $form ) {
|
88 |
?>
|
89 |
-
<option value="<?php echo $form->id; ?>" <?php if (!$form->published) { echo 'disabled="disabled"';} ?>><?php echo $form->title . ($form->published ? '' : ' - ' . __('Unpublished',
|
90 |
<?php
|
91 |
}
|
92 |
}
|
@@ -94,10 +96,10 @@ class FMViewFMShortocde_fmc {
|
|
94 |
</select>
|
95 |
</span>
|
96 |
<span class="wd-group">
|
97 |
-
<label class="wd-label" for="public_key"><?php _e('Select Date Range',
|
98 |
-
<label for="startdate"><?php _e('From',
|
99 |
<input class="initial-width wd-datepicker" type="text" name="startdate" id="startdate" size="10" maxlength="10" value="" />
|
100 |
-
<label for="enddate"><?php _e('To',
|
101 |
<input class="initial-width wd-datepicker" type="text" name="enddate" id="enddate" size="10" maxlength="10" value="" />
|
102 |
</span>
|
103 |
</div>
|
@@ -107,43 +109,43 @@ class FMViewFMShortocde_fmc {
|
|
107 |
<div class="wd-table-col wd-table-col-50 wd-table-col-left">
|
108 |
<div class="wd-box-content wd-box-content-shortcode">
|
109 |
<span class="wd-group">
|
110 |
-
<label class="wd-label"><?php _e('Select fields',
|
111 |
<ul>
|
112 |
<li>
|
113 |
<input type="checkbox" checked="checked" id="submit_date" name="submit_date" value="submit_date" />
|
114 |
-
<label for="submit_date"><?php _e('Submit Date',
|
115 |
</li>
|
116 |
<li>
|
117 |
<input type="checkbox" checked="checked" id="submitter_ip" name="submitter_ip" value="submitter_ip" />
|
118 |
-
<label for="submitter_ip"><?php _e('Submitter\'s IP Address',
|
119 |
</li>
|
120 |
<li>
|
121 |
<input type="checkbox" checked="checked" id="username" name="username" value="username" />
|
122 |
-
<label for="username"><?php _e('Submitter\'s Username',
|
123 |
</li>
|
124 |
<li>
|
125 |
<input type="checkbox" checked="checked" id="useremail" name="useremail" value="useremail" />
|
126 |
-
<label for="useremail"><?php _e('Submitter\'s Email Address',
|
127 |
</li>
|
128 |
<li>
|
129 |
<input type="checkbox" checked="checked" id="form_fields" name="form_fields" value="form_fields" />
|
130 |
-
<label for="form_fields"><?php _e('Form Fields',
|
131 |
</li>
|
132 |
<p class="description">
|
133 |
-
<?php _e('You can hide specific form fields from Form General Options.',
|
134 |
</p>
|
135 |
</ul>
|
136 |
</span>
|
137 |
<span class="wd-group">
|
138 |
-
<label class="wd-label"><?php _e('Export to',
|
139 |
<ul>
|
140 |
<li>
|
141 |
<input type="checkbox" checked="checked" id="csv" name="csv" value="csv" />
|
142 |
-
<label for="csv"><?php _e('CSV',
|
143 |
</li>
|
144 |
<li>
|
145 |
<input type="checkbox" checked="checked" id="xml" name="xml" value="xml" />
|
146 |
-
<label for="xml"><?php _e('XML',
|
147 |
</li>
|
148 |
</ul>
|
149 |
</span>
|
@@ -152,39 +154,39 @@ class FMViewFMShortocde_fmc {
|
|
152 |
<div class="wd-table-col wd-table-col-50 wd-table-col-right">
|
153 |
<div class="wd-box-content wd-box-content-shortcode">
|
154 |
<span class="wd-group">
|
155 |
-
<label class="wd-label"><?php _e('Show',
|
156 |
<ul>
|
157 |
<li>
|
158 |
<input type="checkbox" checked="checked" id="title" name="title" value="title" />
|
159 |
-
<label for="title"><?php _e('Title',
|
160 |
</li>
|
161 |
<li>
|
162 |
<input type="checkbox" checked="checked" id="search" name="search" value="search" />
|
163 |
-
<label for="search"><?php _e('Search',
|
164 |
</li>
|
165 |
<li>
|
166 |
<input type="checkbox" checked="checked" id="ordering" name="ordering" value="ordering" />
|
167 |
-
<label for="ordering"><?php _e('Ordering',
|
168 |
</li>
|
169 |
<li>
|
170 |
<input type="checkbox" checked="checked" id="entries" name="entries" value="entries" />
|
171 |
-
<label for="entries"><?php _e('Entries',
|
172 |
</li>
|
173 |
<li>
|
174 |
<input type="checkbox" checked="checked" id="views" name="views" value="views" />
|
175 |
-
<label for="views"><?php _e('Views',
|
176 |
</li>
|
177 |
<li>
|
178 |
<input type="checkbox" checked="checked" id="conversion_rate" name="conversion_rate" value="conversion_rate" />
|
179 |
-
<label for="conversion_rate"><?php _e('Conversion Rate',
|
180 |
</li>
|
181 |
<li>
|
182 |
<input type="checkbox" checked="checked" id="pagination" name="pagination" value="pagination" />
|
183 |
-
<label for="pagination"><?php _e('Pagination',
|
184 |
</li>
|
185 |
<li>
|
186 |
<input type="checkbox" checked="checked" id="stats" name="stats" value="stats" />
|
187 |
-
<label for="stats"><?php _e('Statistics',
|
188 |
</li>
|
189 |
</ul>
|
190 |
</span>
|
@@ -195,7 +197,7 @@ class FMViewFMShortocde_fmc {
|
|
195 |
<div class="wd-table-col">
|
196 |
<div class="wd-box-content wd-box-content-shortcode">
|
197 |
<span class="wd-group wd-right">
|
198 |
-
<input class="wd-button button-primary" type="button" name="insert" value="<?php _e('Insert',
|
199 |
</span>
|
200 |
</div>
|
201 |
</div>
|
3 |
/**
|
4 |
* Class FMViewFMShortocde_fmc
|
5 |
*/
|
6 |
+
class FMViewFMShortocde_fmc extends FMAdminView_fmc {
|
7 |
/**
|
8 |
* FMViewFMShortocde constructor.
|
9 |
*/
|
10 |
public function __construct() {
|
11 |
+
wp_print_scripts(WDFMInstance(self::PLUGIN)->handle_prefix . '-shortcode' . WDFMInstance(self::PLUGIN)->menu_postfix);
|
12 |
|
13 |
wp_print_styles('wp-admin');
|
14 |
wp_print_styles('buttons');
|
15 |
|
16 |
+
wp_print_styles(WDFMInstance(self::PLUGIN)->handle_prefix . '-tables');
|
|
|
17 |
|
18 |
+
if (!WDFMInstance(self::PLUGIN)->is_free) {
|
19 |
+
wp_print_scripts('jquery-ui-datepicker');
|
20 |
+
wp_print_styles(WDFMInstance(self::PLUGIN)->handle_prefix . '-jquery-ui');
|
21 |
+
wp_print_styles(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
22 |
+
}
|
23 |
+
else {
|
24 |
+
wp_print_styles( WDFMInstance(self::PLUGIN)->handle_prefix . '-pricing' );
|
25 |
+
wp_print_styles( WDFMInstance(self::PLUGIN)->handle_prefix . '-roboto' );
|
26 |
}
|
27 |
}
|
28 |
|
39 |
<div class="wd-box-content wd-box-content-shortcode">
|
40 |
<span class="wd-group">
|
41 |
<select name="form_maker_id">
|
42 |
+
<option value="0"><?php _e('-Select a Form-', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
43 |
<?php
|
44 |
if ( $forms ) {
|
45 |
foreach ( $forms as $form ) {
|
46 |
?>
|
47 |
+
<option value="<?php echo $form->id; ?>" <?php if (!$form->published) { echo 'disabled="disabled"';} ?>><?php echo $form->title . ($form->published ? '' : ' - ' . __('Unpublished', WDFMInstance(self::PLUGIN)->prefix)); ?></option>
|
48 |
<?php
|
49 |
}
|
50 |
}
|
52 |
</select>
|
53 |
</span>
|
54 |
<span class="wd-group wd-right">
|
55 |
+
<input class="wd-button button-primary" type="button" name="insert" value="<?php _e('Insert', WDFMInstance(self::PLUGIN)->prefix); ?>" onclick="insert_shortcode('form')" />
|
56 |
</span>
|
57 |
</div>
|
58 |
</div>
|
69 |
*/
|
70 |
public function submissions( $forms ) {
|
71 |
?>
|
72 |
+
<body class="wp-core-ui" data-width="520" data-height="570" <?php echo (WDFMInstance(self::PLUGIN)->is_free ? 'style="overflow: hidden;"' : ''); ?>>
|
73 |
<?php
|
74 |
+
if ( WDFMInstance(self::PLUGIN)->is_free ) {
|
75 |
+
echo $this->free_message(__('Front end submissions are available in Premium version', WDFMInstance(self::PLUGIN)->prefix));
|
76 |
?>
|
|
|
|
|
|
|
77 |
<div class="wd-fixed-conteiner"></div>
|
78 |
<?php
|
79 |
}
|
83 |
<div class="wd-box-content wd-box-content-shortcode">
|
84 |
<span class="wd-group">
|
85 |
<select name="form_maker_id">
|
86 |
+
<option value="0"><?php _e('-Select a Form-', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
87 |
<?php
|
88 |
if ( $forms ) {
|
89 |
foreach ( $forms as $form ) {
|
90 |
?>
|
91 |
+
<option value="<?php echo $form->id; ?>" <?php if (!$form->published) { echo 'disabled="disabled"';} ?>><?php echo $form->title . ($form->published ? '' : ' - ' . __('Unpublished', WDFMInstance(self::PLUGIN)->prefix)); ?></option>
|
92 |
<?php
|
93 |
}
|
94 |
}
|
96 |
</select>
|
97 |
</span>
|
98 |
<span class="wd-group">
|
99 |
+
<label class="wd-label" for="public_key"><?php _e('Select Date Range', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
100 |
+
<label for="startdate"><?php _e('From', WDFMInstance(self::PLUGIN)->prefix); ?>:</label>
|
101 |
<input class="initial-width wd-datepicker" type="text" name="startdate" id="startdate" size="10" maxlength="10" value="" />
|
102 |
+
<label for="enddate"><?php _e('To', WDFMInstance(self::PLUGIN)->prefix); ?>:</label>
|
103 |
<input class="initial-width wd-datepicker" type="text" name="enddate" id="enddate" size="10" maxlength="10" value="" />
|
104 |
</span>
|
105 |
</div>
|
109 |
<div class="wd-table-col wd-table-col-50 wd-table-col-left">
|
110 |
<div class="wd-box-content wd-box-content-shortcode">
|
111 |
<span class="wd-group">
|
112 |
+
<label class="wd-label"><?php _e('Select fields', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
113 |
<ul>
|
114 |
<li>
|
115 |
<input type="checkbox" checked="checked" id="submit_date" name="submit_date" value="submit_date" />
|
116 |
+
<label for="submit_date"><?php _e('Submit Date', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
117 |
</li>
|
118 |
<li>
|
119 |
<input type="checkbox" checked="checked" id="submitter_ip" name="submitter_ip" value="submitter_ip" />
|
120 |
+
<label for="submitter_ip"><?php _e('Submitter\'s IP Address', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
121 |
</li>
|
122 |
<li>
|
123 |
<input type="checkbox" checked="checked" id="username" name="username" value="username" />
|
124 |
+
<label for="username"><?php _e('Submitter\'s Username', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
125 |
</li>
|
126 |
<li>
|
127 |
<input type="checkbox" checked="checked" id="useremail" name="useremail" value="useremail" />
|
128 |
+
<label for="useremail"><?php _e('Submitter\'s Email Address', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
129 |
</li>
|
130 |
<li>
|
131 |
<input type="checkbox" checked="checked" id="form_fields" name="form_fields" value="form_fields" />
|
132 |
+
<label for="form_fields"><?php _e('Form Fields', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
133 |
</li>
|
134 |
<p class="description">
|
135 |
+
<?php _e('You can hide specific form fields from Form General Options.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
136 |
</p>
|
137 |
</ul>
|
138 |
</span>
|
139 |
<span class="wd-group">
|
140 |
+
<label class="wd-label"><?php _e('Export to', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
141 |
<ul>
|
142 |
<li>
|
143 |
<input type="checkbox" checked="checked" id="csv" name="csv" value="csv" />
|
144 |
+
<label for="csv"><?php _e('CSV', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
145 |
</li>
|
146 |
<li>
|
147 |
<input type="checkbox" checked="checked" id="xml" name="xml" value="xml" />
|
148 |
+
<label for="xml"><?php _e('XML', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
149 |
</li>
|
150 |
</ul>
|
151 |
</span>
|
154 |
<div class="wd-table-col wd-table-col-50 wd-table-col-right">
|
155 |
<div class="wd-box-content wd-box-content-shortcode">
|
156 |
<span class="wd-group">
|
157 |
+
<label class="wd-label"><?php _e('Show', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
158 |
<ul>
|
159 |
<li>
|
160 |
<input type="checkbox" checked="checked" id="title" name="title" value="title" />
|
161 |
+
<label for="title"><?php _e('Title', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
162 |
</li>
|
163 |
<li>
|
164 |
<input type="checkbox" checked="checked" id="search" name="search" value="search" />
|
165 |
+
<label for="search"><?php _e('Search', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
166 |
</li>
|
167 |
<li>
|
168 |
<input type="checkbox" checked="checked" id="ordering" name="ordering" value="ordering" />
|
169 |
+
<label for="ordering"><?php _e('Ordering', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
170 |
</li>
|
171 |
<li>
|
172 |
<input type="checkbox" checked="checked" id="entries" name="entries" value="entries" />
|
173 |
+
<label for="entries"><?php _e('Entries', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
174 |
</li>
|
175 |
<li>
|
176 |
<input type="checkbox" checked="checked" id="views" name="views" value="views" />
|
177 |
+
<label for="views"><?php _e('Views', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
178 |
</li>
|
179 |
<li>
|
180 |
<input type="checkbox" checked="checked" id="conversion_rate" name="conversion_rate" value="conversion_rate" />
|
181 |
+
<label for="conversion_rate"><?php _e('Conversion Rate', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
182 |
</li>
|
183 |
<li>
|
184 |
<input type="checkbox" checked="checked" id="pagination" name="pagination" value="pagination" />
|
185 |
+
<label for="pagination"><?php _e('Pagination', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
186 |
</li>
|
187 |
<li>
|
188 |
<input type="checkbox" checked="checked" id="stats" name="stats" value="stats" />
|
189 |
+
<label for="stats"><?php _e('Statistics', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
190 |
</li>
|
191 |
</ul>
|
192 |
</span>
|
197 |
<div class="wd-table-col">
|
198 |
<div class="wd-box-content wd-box-content-shortcode">
|
199 |
<span class="wd-group wd-right">
|
200 |
+
<input class="wd-button button-primary" type="button" name="insert" value="<?php _e('Insert', WDFMInstance(self::PLUGIN)->prefix); ?>" onclick="insert_shortcode('submissions')" />
|
201 |
</span>
|
202 |
</div>
|
203 |
</div>
|
admin/views/FMShowMatrix.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewShow_matrix_fmc
|
5 |
*/
|
6 |
-
class FMViewShow_matrix_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
3 |
/**
|
4 |
* Class FMViewShow_matrix_fmc
|
5 |
*/
|
6 |
+
class FMViewShow_matrix_fmc extends FMAdminView_fmc {
|
7 |
/**
|
8 |
* Display.
|
9 |
*
|
admin/views/FMSqlMapping.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
class FMViewFormMakerSQLMapping_fmc {
|
4 |
public function __construct() {
|
5 |
wp_print_scripts('jquery');
|
6 |
wp_print_scripts('jquery-ui-tooltip');
|
7 |
-
wp_print_styles('
|
8 |
-
wp_print_styles('
|
9 |
wp_print_styles('dashicons');
|
10 |
}
|
11 |
|
@@ -82,7 +82,7 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
82 |
$cond .= '<option>' . str_replace("'", "SingleQuot", $col->Field) . '</option>';
|
83 |
}
|
84 |
$cond .= '</select>';
|
85 |
-
$cond .= '<select id="op_condid"><option value="=" selected="selected">=</option><option value="!=">!=</option><option value=">">></option><option value="<"><</option><option value=">=">>=</option><option value="<="><=</option><option value="%..%">Like</option><option value="%..">Starts with</option><option value="..%">Ends with</option></select><input id="val_condid" style="width:170px" type="text" /><select id="andor_condid" style="visibility: hidden;"><option value="AND">AND</option><option value="OR">OR</option></select><img src="' .
|
86 |
?>
|
87 |
<script>
|
88 |
jQuery(document).ready(function() {
|
@@ -235,7 +235,7 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
235 |
jQuery.ajax({
|
236 |
type: "POST",
|
237 |
url: "<?php echo add_query_arg(array(
|
238 |
-
'action' => 'FormMakerSQLMapping' .
|
239 |
'id' => $id,
|
240 |
'form_id' => $form_id,
|
241 |
'task' => 'update_query',
|
@@ -811,19 +811,19 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
811 |
$title = $col->Field;
|
812 |
$title .= "<ul style='padding-left: 17px;'>";
|
813 |
if ( $col->Type ) {
|
814 |
-
$title .= "<li>" . __('Type',
|
815 |
}
|
816 |
if ( $col->Null ) {
|
817 |
-
$title .= "<li>" . __('Null',
|
818 |
}
|
819 |
if ( $col->Key ) {
|
820 |
-
$title .= "<li>" . __('Key',
|
821 |
}
|
822 |
if ( $col->Default ) {
|
823 |
-
$title .= "<li>" . __('Default',
|
824 |
}
|
825 |
if ( $col->Extra ) {
|
826 |
-
$title .= "<li>" . __('Extra',
|
827 |
}
|
828 |
$title .= "</ul>";
|
829 |
?>
|
@@ -844,7 +844,7 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
844 |
}
|
845 |
}
|
846 |
if ( $con_method == 'delete' or $con_method == 'update' ) {
|
847 |
-
echo '<div class="select-db-op where"><img src="' .
|
848 |
if ( $wheres ) {
|
849 |
echo '<script>';
|
850 |
$wheres = explode('***where***', $wheres);
|
@@ -955,7 +955,7 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
955 |
jQuery.ajax({
|
956 |
type: "POST",
|
957 |
url: "<?php echo add_query_arg(array(
|
958 |
-
'action' => 'FormMakerSQLMapping' .
|
959 |
'id' => 0,
|
960 |
'form_id' => $form_id,
|
961 |
'task' => 'db_tables',
|
@@ -1176,7 +1176,7 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
1176 |
jQuery.ajax({
|
1177 |
type: "POST",
|
1178 |
url: "<?php echo add_query_arg(array(
|
1179 |
-
'action' => 'FormMakerSQLMapping' .
|
1180 |
'id' => 0,
|
1181 |
'form_id' => $form_id,
|
1182 |
'task' => 'db_table_struct',
|
@@ -1251,7 +1251,7 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
1251 |
$cond .= '<option>' . str_replace("'", "SingleQuot", $col->Field) . '</option>';
|
1252 |
}
|
1253 |
$cond .= '</select>';
|
1254 |
-
$cond .= '<select id="op_condid"><option value="=" selected="selected">=</option><option value="!=">!=</option><option value=">">></option><option value="<"><</option><option value=">=">>=</option><option value="<="><=</option><option value="%..%">Like</option><option value="%..">Starts with</option><option value="..%">Ends with</option></select><input id="val_condid" style="width:170px" type="text" /><select id="andor_condid" style="visibility: hidden;"><option value="AND">AND</option><option value="OR">OR</option></select><img src="' .
|
1255 |
?>
|
1256 |
<script>
|
1257 |
jQuery(document).ready(function() {
|
@@ -1394,7 +1394,7 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
1394 |
jQuery.ajax({
|
1395 |
type: "POST",
|
1396 |
url: "<?php echo add_query_arg(array(
|
1397 |
-
'action' => 'FormMakerSQLMapping' .
|
1398 |
'id' => 0,
|
1399 |
'form_id' => $form_id,
|
1400 |
'task' => 'save_query',
|
@@ -1763,19 +1763,19 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
1763 |
$title = $col->Field;
|
1764 |
$title .= "<ul style='padding-left: 17px;'>";
|
1765 |
if ( $col->Type ) {
|
1766 |
-
$title .= "<li>" . __('Type',
|
1767 |
}
|
1768 |
if ( $col->Null ) {
|
1769 |
-
$title .= "<li>" . __('Null',
|
1770 |
}
|
1771 |
if ( $col->Key ) {
|
1772 |
-
$title .= "<li>" . __('Key',
|
1773 |
}
|
1774 |
if ( $col->Default ) {
|
1775 |
-
$title .= "<li>" . __('Default',
|
1776 |
}
|
1777 |
if ( $col->Extra ) {
|
1778 |
-
$title .= "<li>" . __('Extra',
|
1779 |
}
|
1780 |
$title .= "</ul>";
|
1781 |
?>
|
@@ -1793,7 +1793,7 @@ class FMViewFormMakerSQLMapping_fmc {
|
|
1793 |
}
|
1794 |
}
|
1795 |
if ( $con_method == 'delete' or $con_method == 'update' ) {
|
1796 |
-
echo '<div class="select-db-op where"><img src="' .
|
1797 |
}
|
1798 |
?>
|
1799 |
</div>
|
1 |
<?php
|
2 |
|
3 |
+
class FMViewFormMakerSQLMapping_fmc extends FMAdminView_fmc {
|
4 |
public function __construct() {
|
5 |
wp_print_scripts('jquery');
|
6 |
wp_print_scripts('jquery-ui-tooltip');
|
7 |
+
wp_print_styles(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
8 |
+
wp_print_styles(WDFMInstance(self::PLUGIN)->handle_prefix . '-jquery-ui');
|
9 |
wp_print_styles('dashicons');
|
10 |
}
|
11 |
|
82 |
$cond .= '<option>' . str_replace("'", "SingleQuot", $col->Field) . '</option>';
|
83 |
}
|
84 |
$cond .= '</select>';
|
85 |
+
$cond .= '<select id="op_condid"><option value="=" selected="selected">=</option><option value="!=">!=</option><option value=">">></option><option value="<"><</option><option value=">=">>=</option><option value="<="><=</option><option value="%..%">Like</option><option value="%..">Starts with</option><option value="..%">Ends with</option></select><input id="val_condid" style="width:170px" type="text" /><select id="andor_condid" style="visibility: hidden;"><option value="AND">AND</option><option value="OR">OR</option></select><img src="' . WDFMInstance(self::PLUGIN)->plugin_dir . '/images/delete.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" onclick="delete_cond("condid")" style="vertical-align: middle;"></div>';
|
86 |
?>
|
87 |
<script>
|
88 |
jQuery(document).ready(function() {
|
235 |
jQuery.ajax({
|
236 |
type: "POST",
|
237 |
url: "<?php echo add_query_arg(array(
|
238 |
+
'action' => 'FormMakerSQLMapping' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
239 |
'id' => $id,
|
240 |
'form_id' => $form_id,
|
241 |
'task' => 'update_query',
|
811 |
$title = $col->Field;
|
812 |
$title .= "<ul style='padding-left: 17px;'>";
|
813 |
if ( $col->Type ) {
|
814 |
+
$title .= "<li>" . __('Type', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Type . "</li>";
|
815 |
}
|
816 |
if ( $col->Null ) {
|
817 |
+
$title .= "<li>" . __('Null', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Null . "</li>";
|
818 |
}
|
819 |
if ( $col->Key ) {
|
820 |
+
$title .= "<li>" . __('Key', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Key . "</li>";
|
821 |
}
|
822 |
if ( $col->Default ) {
|
823 |
+
$title .= "<li>" . __('Default', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Default . "</li>";
|
824 |
}
|
825 |
if ( $col->Extra ) {
|
826 |
+
$title .= "<li>" . __('Extra', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Extra . "</li>";
|
827 |
}
|
828 |
$title .= "</ul>";
|
829 |
?>
|
844 |
}
|
845 |
}
|
846 |
if ( $con_method == 'delete' or $con_method == 'update' ) {
|
847 |
+
echo '<div class="select-db-op where"><img src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/add_condition.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" title="ADD" class="add_cond"/>WHERE</div>';
|
848 |
if ( $wheres ) {
|
849 |
echo '<script>';
|
850 |
$wheres = explode('***where***', $wheres);
|
955 |
jQuery.ajax({
|
956 |
type: "POST",
|
957 |
url: "<?php echo add_query_arg(array(
|
958 |
+
'action' => 'FormMakerSQLMapping' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
959 |
'id' => 0,
|
960 |
'form_id' => $form_id,
|
961 |
'task' => 'db_tables',
|
1176 |
jQuery.ajax({
|
1177 |
type: "POST",
|
1178 |
url: "<?php echo add_query_arg(array(
|
1179 |
+
'action' => 'FormMakerSQLMapping' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
1180 |
'id' => 0,
|
1181 |
'form_id' => $form_id,
|
1182 |
'task' => 'db_table_struct',
|
1251 |
$cond .= '<option>' . str_replace("'", "SingleQuot", $col->Field) . '</option>';
|
1252 |
}
|
1253 |
$cond .= '</select>';
|
1254 |
+
$cond .= '<select id="op_condid"><option value="=" selected="selected">=</option><option value="!=">!=</option><option value=">">></option><option value="<"><</option><option value=">=">>=</option><option value="<="><=</option><option value="%..%">Like</option><option value="%..">Starts with</option><option value="..%">Ends with</option></select><input id="val_condid" style="width:170px" type="text" /><select id="andor_condid" style="visibility: hidden;"><option value="AND">AND</option><option value="OR">OR</option></select><img src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/delete.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" onclick="delete_cond("condid")" style="vertical-align: middle;"></div>';
|
1255 |
?>
|
1256 |
<script>
|
1257 |
jQuery(document).ready(function() {
|
1394 |
jQuery.ajax({
|
1395 |
type: "POST",
|
1396 |
url: "<?php echo add_query_arg(array(
|
1397 |
+
'action' => 'FormMakerSQLMapping' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
1398 |
'id' => 0,
|
1399 |
'form_id' => $form_id,
|
1400 |
'task' => 'save_query',
|
1763 |
$title = $col->Field;
|
1764 |
$title .= "<ul style='padding-left: 17px;'>";
|
1765 |
if ( $col->Type ) {
|
1766 |
+
$title .= "<li>" . __('Type', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Type . "</li>";
|
1767 |
}
|
1768 |
if ( $col->Null ) {
|
1769 |
+
$title .= "<li>" . __('Null', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Null . "</li>";
|
1770 |
}
|
1771 |
if ( $col->Key ) {
|
1772 |
+
$title .= "<li>" . __('Key', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Key . "</li>";
|
1773 |
}
|
1774 |
if ( $col->Default ) {
|
1775 |
+
$title .= "<li>" . __('Default', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Default . "</li>";
|
1776 |
}
|
1777 |
if ( $col->Extra ) {
|
1778 |
+
$title .= "<li>" . __('Extra', WDFMInstance(self::PLUGIN)->prefix) . " - " . $col->Extra . "</li>";
|
1779 |
}
|
1780 |
$title .= "</ul>";
|
1781 |
?>
|
1793 |
}
|
1794 |
}
|
1795 |
if ( $con_method == 'delete' or $con_method == 'update' ) {
|
1796 |
+
echo '<div class="select-db-op where"><img src="' . WDFMInstance(self::PLUGIN)->plugin_url . '/images/add_condition.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . '" title="ADD" class="add_cond"/>WHERE</div>';
|
1797 |
}
|
1798 |
?>
|
1799 |
</div>
|
admin/views/FormMakerSubmits.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/**
|
4 |
* Class FMViewFormMakerSubmits_fmc
|
5 |
*/
|
6 |
-
class FMViewFormMakerSubmits_fmc {
|
7 |
public function display( $params ) {
|
8 |
if ( isset($_GET['form_id']) && isset($_GET['group_id']) ) {
|
9 |
$rows = $params['rows'];
|
3 |
/**
|
4 |
* Class FMViewFormMakerSubmits_fmc
|
5 |
*/
|
6 |
+
class FMViewFormMakerSubmits_fmc extends FMAdminView_fmc {
|
7 |
public function display( $params ) {
|
8 |
if ( isset($_GET['form_id']) && isset($_GET['group_id']) ) {
|
9 |
$rows = $params['rows'];
|
admin/views/Licensing_fm.php
DELETED
@@ -1,70 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
/**
|
4 |
-
* Class FMViewLicensing_fmc
|
5 |
-
*/
|
6 |
-
class FMViewLicensing_fmc {
|
7 |
-
/**
|
8 |
-
* FMViewLicensing_fm constructor.
|
9 |
-
*/
|
10 |
-
public function __construct() {
|
11 |
-
wp_enqueue_style('fm-license' . WDCFM()->menu_postfix);
|
12 |
-
wp_enqueue_style('fm-style');
|
13 |
-
wp_enqueue_style('fm-tables');
|
14 |
-
wp_enqueue_script('fmc-admin');
|
15 |
-
}
|
16 |
-
|
17 |
-
public function display() {
|
18 |
-
?>
|
19 |
-
<div style="width:99%">
|
20 |
-
<div id="featurs_tables">
|
21 |
-
<div id="featurs_table1">
|
22 |
-
<span>File Upload Field</span>
|
23 |
-
<span>Google Map</span>
|
24 |
-
<span>PayPal Integration</span>
|
25 |
-
<span>Front-End Submissions</span>
|
26 |
-
<span>Multiple/Single Choice</span>
|
27 |
-
<span>Survey Tools</span>
|
28 |
-
<span>Time and Date Fields</span>
|
29 |
-
<span>Select Box</span>
|
30 |
-
<span>MySQL mapping</span>
|
31 |
-
</div>
|
32 |
-
<div id="featurs_table2">
|
33 |
-
<span>Free</span>
|
34 |
-
<span class="no"></span>
|
35 |
-
<span class="no"></span>
|
36 |
-
<span class="no"></span>
|
37 |
-
<span class="no"></span>
|
38 |
-
<span class="no"></span>
|
39 |
-
<span class="no"></span>
|
40 |
-
<span class="no"></span>
|
41 |
-
<span class="no"></span>
|
42 |
-
<span class="no"></span>
|
43 |
-
</div>
|
44 |
-
<div id="featurs_table3">
|
45 |
-
<span>Pro Version</span>
|
46 |
-
<span class="yes"></span>
|
47 |
-
<span class="yes"></span>
|
48 |
-
<span class="yes"></span>
|
49 |
-
<span class="yes"></span>
|
50 |
-
<span class="yes"></span>
|
51 |
-
<span class="yes"></span>
|
52 |
-
<span class="yes"></span>
|
53 |
-
<span class="yes"></span>
|
54 |
-
<span class="yes"></span>
|
55 |
-
</div>
|
56 |
-
</div>
|
57 |
-
<div style="float: left; clear: both;">
|
58 |
-
<a href="https://web-dorado.com/files/fromContactForm.php" class="button-primary" target="_blank">Purchase a
|
59 |
-
License</a>
|
60 |
-
<br/><br/>
|
61 |
-
<p>After purchasing the commercial version follow these steps:</p>
|
62 |
-
<ol>
|
63 |
-
<li>Deactivate Form Maker Plugin.</li>
|
64 |
-
<li>Delete Form Maker Plugin.</li>
|
65 |
-
<li>Install the downloaded commercial version of the plugin.</li>
|
66 |
-
</ol>
|
67 |
-
</div>
|
68 |
-
<?php
|
69 |
-
}
|
70 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
admin/views/Manage_fm.php
CHANGED
@@ -5,19 +5,19 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
5 |
* FMViewManage_fmc constructor.
|
6 |
*/
|
7 |
public function __construct() {
|
8 |
-
wp_enqueue_style('
|
9 |
-
wp_enqueue_style('
|
10 |
-
wp_enqueue_style('
|
11 |
-
wp_enqueue_style('
|
12 |
|
13 |
wp_enqueue_script('jquery');
|
14 |
wp_enqueue_script('jquery-ui-sortable');
|
15 |
-
wp_enqueue_script('
|
16 |
-
wp_enqueue_script('
|
17 |
/*$inline_styles = '#fm_admin_container .wdform_page .wdform_section .wdform_column.ui-sortable:empty:last-child:after {
|
18 |
-
content: "' . __('Drop a field here to create a column.',
|
19 |
}';
|
20 |
-
wp_add_inline_style('
|
21 |
}
|
22 |
|
23 |
/**
|
@@ -31,7 +31,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
31 |
$form_attr = array(
|
32 |
'id' => 'manage_form',
|
33 |
'class' =>'wd-form',
|
34 |
-
'action' => add_query_arg(array('page' => 'manage' .
|
35 |
);
|
36 |
echo $this->form(ob_get_clean(), $form_attr);
|
37 |
}
|
@@ -41,7 +41,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
41 |
*
|
42 |
* @return string Body html.
|
43 |
*/
|
44 |
-
public function body($params) {
|
45 |
$page = $params['page'];
|
46 |
$actions = $params['actions'];
|
47 |
$form_preview_link = $params['form_preview_link'];
|
@@ -53,10 +53,10 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
53 |
|
54 |
$page_url = add_query_arg(array(
|
55 |
'page' => $page,
|
56 |
-
|
57 |
), admin_url('admin.php'));
|
58 |
echo $this->title(array(
|
59 |
-
'title' => __('Forms',
|
60 |
'title_class' => 'wd-header',
|
61 |
'add_new_button' => array(
|
62 |
'href' => add_query_arg(array( 'page' => $page, 'task' => 'add' ), admin_url('admin.php')),
|
@@ -67,7 +67,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
67 |
<div class="tablenav top">
|
68 |
<?php
|
69 |
echo $this->bulk_actions($actions);
|
70 |
-
if (
|
71 |
echo $this->exp_imp_buttons();
|
72 |
}
|
73 |
echo $this->pagination($page_url, $total, $items_per_page);
|
@@ -78,14 +78,14 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
78 |
<thead>
|
79 |
<tr>
|
80 |
<td id="cb" class="manage-column column-cb check-column">
|
81 |
-
<label class="screen-reader-text" for="cb-select-all-1"><?php _e('Select all',
|
82 |
<input id="check_all" type="checkbox" />
|
83 |
</td>
|
84 |
-
<?php echo
|
85 |
-
<?php echo
|
86 |
-
<th class="col_count wd-left"><?php _e('Submissions',
|
87 |
-
<?php echo
|
88 |
-
<th class="col_function wd-center"><?php _e('PHP function',
|
89 |
</tr>
|
90 |
</thead>
|
91 |
<tbody>
|
@@ -105,7 +105,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
105 |
<th class="check-column">
|
106 |
<input id="check_<?php echo $row_data->id; ?>" name="check[<?php echo $row_data->id; ?>]" type="checkbox" class="form_title" data-id="<?php echo $row_data->id; ?>" />
|
107 |
</th>
|
108 |
-
<td class="column-primary" data-colname="<?php _e('Title',
|
109 |
<strong>
|
110 |
<?php
|
111 |
if ( !$old ) {
|
@@ -123,7 +123,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
123 |
if ( !$row_data->published ) {
|
124 |
?>
|
125 |
—
|
126 |
-
<span class="post-state"><?php _e('Unpublished',
|
127 |
<?php
|
128 |
}
|
129 |
?>
|
@@ -133,46 +133,46 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
133 |
if ( !$old ) {
|
134 |
?>
|
135 |
<span>
|
136 |
-
<a href="<?php echo $edit_url; ?>"><?php _e('Edit',
|
137 |
|
|
138 |
</span>
|
139 |
<?php
|
140 |
}
|
141 |
?>
|
142 |
<span>
|
143 |
-
<a href="<?php echo $duplicate_url; ?>"><?php _e('Duplicate',
|
144 |
|
|
145 |
</span>
|
146 |
<span>
|
147 |
-
<a href="<?php echo $publish_url; ?>"><?php echo ($row_data->published ? __('Unpublish',
|
148 |
|
|
149 |
</span>
|
150 |
<span class="trash">
|
151 |
-
<a onclick="if (!confirm('<?php echo addslashes(__('Do you want to delete selected item?',
|
152 |
|
|
153 |
</span>
|
154 |
<span>
|
155 |
-
<a href="<?php echo $preview_url; ?>" target="_blank"><?php _e('Preview',
|
156 |
</span>
|
157 |
</div>
|
158 |
<button class="toggle-row" type="button">
|
159 |
-
<span class="screen-reader-text"><?php _e('Show more details',
|
160 |
</button>
|
161 |
</td>
|
162 |
-
<td data-colname="<?php _e('Type',
|
163 |
<?php echo ucfirst($row_data->type); ?>
|
164 |
<div class="row-actions">
|
165 |
<span>
|
166 |
-
<a href="<?php echo add_query_arg(array('task' => 'display_options', 'current_id' => $row_data->id), $page_url); ?>"><?php _e('Set display options',
|
167 |
</span>
|
168 |
</div>
|
169 |
</td>
|
170 |
-
<td data-colname="<?php _e('Submissions',
|
171 |
<?php
|
172 |
if ($row_data->submission_count != 0) {
|
173 |
?>
|
174 |
-
<a title="<?php _e('View sumbissions',
|
175 |
-
'page' => 'submissions' .
|
176 |
'task' => 'display',
|
177 |
'current_id' => $row_data->id,
|
178 |
), admin_url('admin.php')); ?>">
|
@@ -186,18 +186,18 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
186 |
}
|
187 |
?>
|
188 |
</td>
|
189 |
-
<td data-colname="<?php _e('Shortcode',
|
190 |
-
<input type="text" value='[wd_contact_form
|
191 |
</td>
|
192 |
-
<td data-colname="<?php _e('PHP function',
|
193 |
-
<input type="text" value='<?php wd_contact_form_maker(
|
194 |
</td>
|
195 |
</tr>
|
196 |
<?php
|
197 |
}
|
198 |
}
|
199 |
else {
|
200 |
-
echo
|
201 |
}
|
202 |
?>
|
203 |
</tbody>
|
@@ -217,11 +217,14 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
217 |
}
|
218 |
|
219 |
public function edit($params) {
|
|
|
|
|
|
|
220 |
wp_enqueue_style('thickbox');
|
221 |
-
wp_enqueue_style('
|
222 |
-
wp_enqueue_style('
|
223 |
-
wp_enqueue_style('
|
224 |
-
wp_enqueue_style('
|
225 |
|
226 |
wp_enqueue_script('thickbox');
|
227 |
wp_enqueue_script('jquery-ui-widget');
|
@@ -229,27 +232,27 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
229 |
wp_enqueue_script('jquery-ui-spinner');
|
230 |
wp_enqueue_script('jquery-ui-datepicker');
|
231 |
if ( function_exists('wp_add_inline_script') ) { // Since Wordpress 4.5.0
|
232 |
-
wp_add_inline_script('jquery-ui-datepicker',
|
233 |
}
|
234 |
else {
|
235 |
-
echo '<script>' .
|
236 |
}
|
237 |
wp_enqueue_media();
|
238 |
wp_enqueue_script('google-maps');
|
239 |
-
wp_enqueue_script('
|
240 |
-
wp_enqueue_script('
|
241 |
-
wp_enqueue_script('
|
242 |
-
wp_enqueue_script('
|
243 |
-
wp_enqueue_script('
|
244 |
-
wp_enqueue_script('
|
245 |
-
wp_enqueue_script('
|
246 |
-
wp_enqueue_script('
|
247 |
-
wp_enqueue_script('
|
248 |
-
wp_enqueue_script('
|
249 |
-
wp_enqueue_script('
|
250 |
-
wp_enqueue_script('
|
251 |
-
wp_enqueue_script('
|
252 |
-
wp_enqueue_script('
|
253 |
|
254 |
$id = $params['id'];
|
255 |
$row = $params['row'];
|
@@ -288,23 +291,23 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
288 |
form_fields_initial = decodeURIComponent(form_fields_initial);
|
289 |
|
290 |
default_theme = '<?php echo $default_theme; ?>';
|
291 |
-
theme_edit_url = '<?php echo add_query_arg( array('page' => 'themes' .
|
292 |
jQuery(document).ready(function () {
|
293 |
set_theme();
|
294 |
});
|
295 |
</script>
|
296 |
-
<form class="wrap" id="manage_form" method="post" autocomplete="off" action="admin.php?page=manage<?php echo
|
297 |
<?php
|
298 |
// Generate message container by message id or directly by message.
|
299 |
-
$message_id =
|
300 |
-
$message =
|
301 |
-
echo
|
302 |
?>
|
303 |
-
<?php wp_nonce_field(
|
304 |
<h2 class="fm-h2-message"></h2>
|
305 |
<div class="fm-page-header">
|
306 |
<div class="wd-page-title wd-header">
|
307 |
-
<h1 class="wp-heading-inline"><?php _e('Form Title',
|
308 |
<input id="title" name="title" value="<?php echo $row->title; ?>" data-initial-value="<?php echo $row->title; ?>" class="fm-check-change" type="text" />
|
309 |
<div class="fm-page-actions">
|
310 |
<?php
|
@@ -312,40 +315,40 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
312 |
if ( $row->backup_id != "" ) {
|
313 |
$backup_id = $next_backup_id;
|
314 |
if ( $backup_id ) { ?>
|
315 |
-
<button class="button redo-button button-large" onclick="if (fm_check_required('title', '<?php _e('Form Title',
|
316 |
-
<?php _e('Redo',
|
317 |
</button>
|
318 |
<?php
|
319 |
}
|
320 |
$backup_id = $prev_backup_id;
|
321 |
if ( $backup_id ) { ?>
|
322 |
-
<button class="button undo-button button-large" onclick="if (fm_check_required('title', '<?php _e('Form Title',
|
323 |
<span></span>
|
324 |
-
<?php _e('Undo',
|
325 |
</button>
|
326 |
<?php
|
327 |
}
|
328 |
}
|
329 |
}
|
330 |
?>
|
331 |
-
<button class="button button-primary button-large" onclick="if (fm_check_required('title', '<?php _e('Form Title',
|
332 |
<?php
|
333 |
if ($row->title) {
|
334 |
-
_e('Update',
|
335 |
}
|
336 |
else {
|
337 |
-
_e('Publish',
|
338 |
}
|
339 |
?>
|
340 |
</button>
|
341 |
-
<button class="button preview-button button-large"<?php if (!$row->title) echo ' disabled="disabled"' ?> <?php echo ($row->title) ? 'onclick="window.open(\''. add_query_arg( array('wdform_id' => $id), $form_preview_link ) .'\', \'_blank\'); return false;"' : ''; ?>><?php _e('Preview',
|
342 |
</div>
|
343 |
</div>
|
344 |
<div class="fm-clear"></div>
|
345 |
</div>
|
346 |
<div class="fm-theme-banner">
|
347 |
<div class="fm-theme" style="float:left; position: relative">
|
348 |
-
<span><?php _e('Theme',
|
349 |
<select id="theme" name="theme" data-initial-value="<?php echo $row->theme; ?>" class="fm-check-change" onChange="set_theme()">
|
350 |
<optgroup label="New Themes">
|
351 |
<?php
|
@@ -365,20 +368,20 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
365 |
?>
|
366 |
</optgroup>
|
367 |
</select>
|
368 |
-
<a id="edit_css" class="pointer" onclick="window.open('<?php echo add_query_arg(array('current_id' => ($row->theme ? $row->theme : $default_theme),
|
369 |
-
<?php _e('Edit',
|
370 |
</a>
|
371 |
<br />
|
372 |
-
<div id="old_theme_notice" style="display: none;"><div class="error inline"><p><?php _e('The theme you have selected is outdated. Please choose one from New Themes section.',
|
373 |
</div>
|
374 |
<div class="fm-page-actions">
|
375 |
<?php if( $id ){ ?>
|
376 |
-
<a class="button button-primary" href="<?php echo $params['form_options_url']; ?>"><?php _e('Form Options',
|
377 |
-
<a class="button" href="<?php echo $params['display_options_url']; ?>"><?php _e('Display Options',
|
378 |
<?php
|
379 |
if ( !empty($params['advanced_layout_url']) ) {
|
380 |
?>
|
381 |
-
<a class="button" href="<?php echo $params['advanced_layout_url']; ?>"><?php _e('Advanced Layout',
|
382 |
<?php
|
383 |
}
|
384 |
}
|
@@ -386,26 +389,27 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
386 |
</div>
|
387 |
</div>
|
388 |
<div class="fm-clear"></div>
|
389 |
-
<?php echo $this->add_fields(); ?>
|
|
|
390 |
<?php if (!function_exists('the_editor')) { ?>
|
391 |
<iframe id="tinymce" style="display: none;"></iframe>
|
392 |
<?php } ?>
|
393 |
<div class="meta-box-sortables" style="margin-top:30px;">
|
394 |
<div id="postexcerpt" class="postbox closed" >
|
395 |
<button type="button" class="button-link handlediv" aria-expanded="true">
|
396 |
-
<span class="screen-reader-text"><?php _e('Toggle panel: Form Header',
|
397 |
<span class="toggle-indicator" aria-hidden="true"></span>
|
398 |
</button>
|
399 |
-
<h2 class="hndle"><span><?php _e('Form Header',
|
400 |
<div class="inside">
|
401 |
<div id="fm-header-content" class="panel-content">
|
402 |
<div>
|
403 |
<div class="fm-row">
|
404 |
-
<label><?php _e('Title:',
|
405 |
<input type="text" id="header_title" name="header_title" class="fm-check-change" value="<?php echo $row->header_title; ?>" data-initial-value="<?php echo $row->header_title; ?>" />
|
406 |
</div>
|
407 |
<div class="fm-row">
|
408 |
-
<label><?php _e('Description:',
|
409 |
<div id="description_editor" style="display: inline-block; vertical-align: middle;">
|
410 |
<input type="hidden" id="header_description_initial_value" value="<?php echo rawurlencode($row->header_description); ?>" />
|
411 |
<?php if (user_can_richedit()) {
|
@@ -421,9 +425,9 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
421 |
</div>
|
422 |
<div>
|
423 |
<div class="fm-row">
|
424 |
-
<label><?php _e('Image:',
|
425 |
<input type="text" id="header_image_url" name="header_image_url" class="fm-check-change" value="<?php echo $row->header_image_url; ?>" data-initial-value="<?php echo $row->header_image_url; ?>" />
|
426 |
-
<button class="button add-button medium" onclick="fmOpenMediaUploader(event); return false;"><?php _e('Add Image',
|
427 |
<?php $header_bg = $row->header_image_url ? 'background-image: url('.$row->header_image_url.'); background-position: center;' : ''; ?>
|
428 |
<div id="header_image" class="header_img<?php if (!$row->header_image_url) echo ' fm-hide'; ?>" style="<?php echo $header_bg; ?>">
|
429 |
<button type="button" id="remove_header_img" onclick="fmRemoveHeaderImage(event); return false;">
|
@@ -432,7 +436,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
432 |
</div>
|
433 |
</div>
|
434 |
<div class="fm-row">
|
435 |
-
<label><?php _e('Image Animation:',
|
436 |
<select name="header_image_animation" class="fm-check-change" data-initial-value="<?php echo $row->header_image_animation; ?>">
|
437 |
<?php
|
438 |
foreach($animation_effects as $anim_key => $animation_effect){
|
@@ -443,7 +447,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
443 |
</select>
|
444 |
</div>
|
445 |
<div class="fm-row">
|
446 |
-
<label for="header_hide_image"><?php _e('Hide Image on Mobile:',
|
447 |
<input type="checkbox" id="header_hide_image" name="header_hide_image" value="1" data-initial-value="<?php echo $row->header_hide_image; ?>" <?php echo $row->header_hide_image == '1' ? 'checked="checked"' : '' ?> />
|
448 |
</div>
|
449 |
</div>
|
@@ -454,7 +458,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
454 |
<div class="fm-edit-content">
|
455 |
<div class="fm-drag-and-drop">
|
456 |
<div>
|
457 |
-
<label for="enable_sortable"><?php _e('Enable Drag & Drop',
|
458 |
<button name="sortable" id="enable_sortable" class="fm-checkbox-radio-button <?php echo $row->sortable == 1 ? 'fm-yes' : 'fm-no' ?>" onclick="enable_drag(this); return false;" value="<?php echo $row->sortable; ?>">
|
459 |
<span></span>
|
460 |
</button>
|
@@ -474,13 +478,13 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
474 |
<div id="add_field" class="ui-sortable-handle">
|
475 |
<div class="first-time-use">
|
476 |
<span class="first-time-use-close dashicons dashicons-no-alt"></span>
|
477 |
-
<?php _e('Drag icon to the form to add a field.',
|
478 |
</div>
|
479 |
|
480 |
<div type="type_text" class="wdform_field">
|
481 |
<div class="add-new-button button-primary" onclick="popup_ready(); Enable(); return false;">
|
482 |
<span class="dashicons dashicons-move"></span>
|
483 |
-
<?php _e('New Field',
|
484 |
</div>
|
485 |
</div>
|
486 |
</div>
|
@@ -508,62 +512,62 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
508 |
<?php
|
509 |
}
|
510 |
|
511 |
-
public function add_fields() {
|
512 |
-
$pro_fields1 = array('file_upload', '
|
513 |
-
$pro_fields2 = array('file_upload', 'paypal', 'checkbox', 'radio', '
|
514 |
$fields = array(
|
515 |
-
__('BASIC FIELDS',
|
516 |
-
array('type' => 'text', 'subtype' => 'text', 'title' => __('Single Line Text',
|
517 |
-
array('type' => 'text', 'subtype' => 'textarea', 'title' => __('Paragraph Text',
|
518 |
-
array('type' => 'survey', 'subtype' => 'spinner', 'title' => __('Number',
|
519 |
-
array('type' => 'time_and_date', 'subtype' => 'date_new', 'title' => __('Date',
|
520 |
-
array('type' => 'select', 'subtype' => 'own_select', 'title' => __('Select',
|
521 |
-
array('type' => 'radio', 'subtype' => '', 'title' => __('Single Choice',
|
522 |
-
array('type' => 'checkbox', 'subtype' => '', 'title' => __('Multiple Choice',
|
523 |
-
array('type' => 'captcha', 'subtype' => 'recaptcha', 'title' => __('Recaptcha',
|
524 |
-
array('type' => 'button', 'subtype' => 'submit_reset', 'title' => __('Submit',
|
525 |
-
|
526 |
-
|
527 |
-
__('USER INFO FIELDS',
|
528 |
-
array('type' => 'text', 'subtype' => 'name', 'title' => __('Name',
|
529 |
-
array('type' => 'text', 'subtype' => 'submitter_mail', 'title' => __('Email',
|
530 |
-
array('type' => 'text', 'subtype' => 'phone_new', 'title' => __('Phone',
|
531 |
-
array('type' => 'text', 'subtype' => 'address', 'title' => __('Address',
|
532 |
-
array('type' => 'text', 'subtype' => 'mark_map', 'title' => __('Mark on Map',
|
533 |
-
array('type' => 'select', 'subtype' => 'country', 'title' => __('Country List',
|
534 |
-
array('type' => 'time_and_date', 'subtype' => 'date_fields', 'title' => __('Date of Birth',
|
535 |
),
|
536 |
-
__('LAYOUT FIELDS',
|
537 |
-
array('type' => 'editor', 'subtype' => '', 'title' => __('HTML',
|
538 |
-
array('type' => 'section_break', 'subtype' => '', 'title' => __('Section',
|
539 |
-
array('type' => 'page_break', 'subtype' => '', 'title' => __('Page',
|
540 |
),
|
541 |
-
__('ADVANCED',
|
542 |
-
array('type' => 'file_upload', 'subtype' => '', 'title' => __('File Upload',
|
543 |
-
array('type' => 'map', 'subtype' => '', 'title' => __('Map',
|
544 |
-
array('type' => 'time_and_date', 'subtype' => 'time', 'title' => __('Time',
|
545 |
-
array('type' => 'text', 'subtype' => 'send_copy', 'title' => __('Receive Copy',
|
546 |
-
array('type' => 'time_and_date', 'subtype' => 'date_range', 'title' => __('Date Range',
|
547 |
-
array('type' => 'survey', 'subtype' => 'star_rating', 'title' => __('Stars',
|
548 |
-
array('type' => 'survey', 'subtype' => 'scale_rating', 'title' => __('Rating',
|
549 |
-
array('type' => 'survey', 'subtype' => 'slider', 'title' => __('Slider',
|
550 |
-
array('type' => 'survey', 'subtype' => 'range', 'title' => __('Range',
|
551 |
-
array('type' => 'survey', 'subtype' => 'grading', 'title' => __('Grades',
|
552 |
-
array('type' => 'survey', 'subtype' => 'matrix', 'title' => __('Table of Fields',
|
553 |
-
array('type' => 'text', 'subtype' => 'hidden', 'title' => __('Hidden Input',
|
554 |
-
array('type' => 'button', 'subtype' => 'button', 'title' => __('Custom Button',
|
555 |
-
array('type' => 'text', 'subtype' => 'password', 'title' => __('Password',
|
556 |
-
array('type' => 'text', 'subtype' => 'phone', 'title' => __('Phone-Area Code',
|
557 |
-
array('type' => 'captcha', 'subtype' => 'arithmetic_captcha', 'title' => __('Arithmetic Captcha',
|
558 |
),
|
559 |
-
__('PAYMENT',
|
560 |
-
array('type' => 'paypal', 'subtype' => 'paypal_price_new', 'title' => __('Price',
|
561 |
-
array('type' => 'paypal', 'subtype' => 'paypal_select', 'title' => __('Payment Select',
|
562 |
-
array('type' => 'paypal', 'subtype' => 'paypal_radio', 'title' => __('Payment Single Choice',
|
563 |
-
array('type' => 'paypal', 'subtype' => 'paypal_checkbox', 'title' => __('Payment Multiple Choice',
|
564 |
-
array('type' => 'paypal', 'subtype' => 'paypal_shipping', 'title' => __('Shipping',
|
565 |
-
array('type' => 'paypal', 'subtype' => 'paypal_total', 'title' => __('Total',
|
566 |
-
array('type' => 'paypal', 'subtype' => 'stripe', 'title' => __('Stripe',
|
567 |
),
|
568 |
);
|
569 |
ob_start();
|
@@ -571,33 +575,33 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
571 |
<div class="add-popup js">
|
572 |
<div class="popup-header">
|
573 |
<span class="popup-title">
|
574 |
-
<?php _e('Add field',
|
575 |
</span>
|
576 |
-
<span title="<?php _e('Close',
|
577 |
</div>
|
578 |
<div class="popup-body meta-box-sortables">
|
579 |
<div class="popup-body-col field_types">
|
580 |
-
|
581 |
-
|
582 |
-
|
583 |
-
|
584 |
</span>
|
585 |
-
|
586 |
<button class="button-link handlediv" type="button" aria-expanded="true">
|
587 |
<span class="screen-reader-text">Toggle panel</span>
|
588 |
<span class="toggle-indicator" aria-hidden="true"></span>
|
589 |
</button>
|
590 |
<h2 class="hndle">
|
591 |
-
<span><?php _e('Filtered fields',
|
592 |
</h2>
|
593 |
<div class="inside"></div>
|
594 |
</div>
|
595 |
<?php
|
596 |
foreach ($fields as $section => $field) {
|
597 |
?>
|
598 |
-
<div class="postbox<?php echo $section != __('BASIC FIELDS',
|
599 |
<button class="button-link handlediv" type="button" aria-expanded="true">
|
600 |
-
<span class="screen-reader-text"><?php echo __('Toggle panel:',
|
601 |
<span class="toggle-indicator" aria-hidden="false"></span>
|
602 |
</button>
|
603 |
<h2 class="hndle">
|
@@ -607,7 +611,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
607 |
<?php
|
608 |
foreach ($field as $button) {
|
609 |
?>
|
610 |
-
<button class="<?php echo ((
|
611 |
<span class="field-type-button wd<?php echo ($button['subtype'] == '' ? $button['type'] : $button['subtype']); ?>"></span>
|
612 |
<?php echo $button['title']; ?>
|
613 |
</button>
|
@@ -621,24 +625,45 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
621 |
?>
|
622 |
</div>
|
623 |
</div>
|
624 |
-
<div
|
625 |
-
|
626 |
-
|
627 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
628 |
<div id="add-button-cont" class="add-button-cont">
|
629 |
<button class="button button-primary button-hero wd-add-button" onclick="add(0, false); return false;">
|
630 |
-
<?php _e('Add',
|
631 |
</button>
|
632 |
</div>
|
633 |
<div id="show_table">
|
634 |
</div>
|
635 |
</div>
|
|
|
636 |
</div>
|
637 |
<input type="hidden" id="old" />
|
638 |
<input type="hidden" id="old_selected" />
|
639 |
<input type="hidden" id="element_type" />
|
640 |
<input type="hidden" id="editing_id" />
|
641 |
-
<input type="hidden" value="<?php echo
|
642 |
<div id="main_editor" style="position: fixed; display: none; z-index: 140;">
|
643 |
<?php if ( user_can_richedit() ) {
|
644 |
wp_editor('', 'form_maker_editor', array(
|
@@ -659,12 +684,12 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
659 |
return ob_get_clean();
|
660 |
}
|
661 |
|
662 |
-
public function form_options( $params ) {
|
663 |
wp_enqueue_style('thickbox');
|
664 |
-
wp_enqueue_style('
|
665 |
-
wp_enqueue_style('
|
666 |
-
wp_enqueue_style('
|
667 |
-
wp_enqueue_style('
|
668 |
|
669 |
wp_enqueue_script('thickbox');
|
670 |
wp_enqueue_script('jquery-ui-widget');
|
@@ -672,26 +697,26 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
672 |
wp_enqueue_script('jquery-ui-spinner');
|
673 |
wp_enqueue_script('jquery-ui-datepicker');
|
674 |
if ( function_exists('wp_add_inline_script') ) { // Since Wordpress 4.5.0
|
675 |
-
wp_add_inline_script('jquery-ui-datepicker',
|
676 |
}
|
677 |
else {
|
678 |
-
echo '<script>' .
|
679 |
}
|
680 |
wp_enqueue_media();
|
681 |
wp_enqueue_script('google-maps');
|
682 |
-
wp_enqueue_script('
|
683 |
-
wp_enqueue_script('
|
684 |
-
wp_enqueue_script('
|
685 |
-
wp_enqueue_script('
|
686 |
-
wp_enqueue_script('
|
687 |
-
wp_enqueue_script('
|
688 |
-
wp_enqueue_script('
|
689 |
-
wp_enqueue_script('
|
690 |
-
wp_enqueue_script('
|
691 |
-
wp_enqueue_script('
|
692 |
-
wp_enqueue_script('
|
693 |
-
wp_enqueue_script('
|
694 |
-
wp_enqueue_script('
|
695 |
|
696 |
$id = $params['id'];
|
697 |
$page = $params['page'];
|
@@ -703,7 +728,7 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
703 |
$form_attr = array(
|
704 |
'id' => 'adminForm',
|
705 |
'name' => 'adminForm',
|
706 |
-
'class' =>
|
707 |
'current_id' => $id,
|
708 |
'action' => add_query_arg( array('page' => $page, 'current_id' => $id ), $page_url),
|
709 |
);
|
@@ -718,79 +743,80 @@ class FMViewManage_fmc extends FMAdminView_fmc {
|
|
718 |
* @return string Body html.
|
719 |
*/
|
720 |
private function body_form_options( $params ) {
|
721 |
-
$id = $params['id'];
|
722 |
-
$page = $params['page'];
|
723 |
-
$page_title = $params['page_title'];
|
724 |
-
$page_url = $params['page_url'];
|
725 |
-
$back_url = $params['back_url'];
|
726 |
-
$fieldset_id = $params['fieldset_id'];
|
727 |
-
$addons = $params['addons'];
|
728 |
-
$row = $params['row'];
|
729 |
-
$themes = $params['themes'];
|
730 |
-
$default_theme = $params['default_theme'];
|
731 |
-
$queries = $params['queries'];
|
732 |
-
$userGroups = $params['userGroups'];
|
733 |
-
$fields = $params['fields'];
|
734 |
-
$fields_count = $params['fields_count'];
|
735 |
-
$stripe_addon = $params['stripe_addon'];
|
736 |
-
$payment_method = $params['payment_method'];
|
737 |
-
$label_label = $params['label_label'];
|
738 |
-
$label_type = $params['label_type'];
|
739 |
-
echo $this->title(array(
|
740 |
-
|
741 |
-
|
742 |
-
|
743 |
-
|
744 |
-
$buttons = array(
|
745 |
-
|
746 |
-
|
747 |
-
|
748 |
-
|
749 |
-
|
750 |
-
|
751 |
-
|
752 |
-
|
753 |
-
|
754 |
-
|
755 |
-
|
756 |
-
|
757 |
-
);
|
758 |
-
echo $this->buttons($buttons);
|
759 |
-
$label_titles_for_submissions = array();
|
760 |
-
$labels_id_for_submissions = array();
|
761 |
-
$payment_info = $params['payment_info'];
|
762 |
-
$labels_for_submissions = $params['labels_for_submissions'];
|
763 |
-
if ( $labels_for_submissions ) {
|
764 |
-
|
765 |
-
|
766 |
-
}
|
767 |
-
$stats_labels_ids = $params['stats_labels_ids'];
|
768 |
-
$stats_labels = $params['stats_labels'];
|
769 |
-
?>
|
770 |
<div class="fm-clear"></div>
|
|
|
771 |
<div class="submenu-box">
|
772 |
<div class="submenu-pad">
|
773 |
<ul id="submenu" class="configuration">
|
774 |
<li>
|
775 |
-
<a id="general" class="fm_fieldset_tab" onclick="form_maker_options_tabs('general')" href="#"><?php _e('General Options',
|
776 |
</li>
|
777 |
<li>
|
778 |
-
<a id="emailTab" class="fm_fieldset_tab" onclick="form_maker_options_tabs('emailTab')" href="#"><?php _e('Email Options',
|
779 |
</li>
|
780 |
<li>
|
781 |
-
<a id="actions" class="fm_fieldset_tab" onclick="form_maker_options_tabs('actions')" href="#"><?php _e('Actions after Submission',
|
782 |
</li>
|
783 |
<li>
|
784 |
-
<a id="payment" class="fm_fieldset_tab" onclick="form_maker_options_tabs('payment')" href="#"><?php _e('Payment Options',
|
785 |
</li>
|
786 |
<li>
|
787 |
-
<a id="javascript" class="fm_fieldset_tab" onclick="form_maker_options_tabs('javascript'); codemirror_for_javascript();" href="#"><?php _e('JavaScript',
|
788 |
</li>
|
789 |
<li>
|
790 |
-
<a id="conditions" class="fm_fieldset_tab" onclick="form_maker_options_tabs('conditions')" href="#"><?php _e('Conditional Fields',
|
791 |
</li>
|
792 |
<li>
|
793 |
-
<a id="mapping" class="fm_fieldset_tab" onclick="form_maker_options_tabs('mapping')" href="#"><?php _e('MySQL Mapping',
|
794 |
</li>
|
795 |
<?php
|
796 |
if ( !empty($addons['tabs']) ) {
|
@@ -814,60 +840,58 @@ $stats_labels = $params['stats_labels'];
|
|
814 |
<div class="wd-box-section">
|
815 |
<div class="wd-box-content">
|
816 |
<span class="wd-group">
|
817 |
-
<label class="wd-label"><?php _e('Published',
|
818 |
<input type="radio" name="published" <?php echo $row->published == 1 ? 'checked="checked"' : '' ?> id="fm_go-published-1" class="wd-radio" value="1">
|
819 |
-
<label class="wd-label-radio" for="fm_go-published-1"><?php _e('Yes',
|
820 |
<input type="radio" name="published" <?php echo $row->published == 0 ? 'checked="checked"' : '' ?> id="fm_go-published-0" class="wd-radio" value="0">
|
821 |
-
<label class="wd-label-radio" for="fm_go-published-0"><?php _e('No',
|
822 |
</span>
|
823 |
<span class="wd-group">
|
824 |
-
<label class="wd-label"><?php _e('Save data(to database)',
|
825 |
<input type="radio" name="savedb" <?php echo $row->savedb == 1 ? 'checked="checked"' : '' ?> id="fm_go-savedb-1" class="wd-radio" value="1">
|
826 |
-
<label class="wd-label-radio" for="fm_go-savedb-1"><?php _e('Yes',
|
827 |
<input type="radio" name="savedb" <?php echo $row->savedb == 0 ? 'checked="checked"' : '' ?> id="fm_go-savedb-0" class="wd-radio" value="0">
|
828 |
-
<label class="wd-label-radio" for="fm_go-savedb-0"><?php _e('No',
|
829 |
-
<p class="description"><?php _e('IMPORTANT! If you disable this option, the information submitted through this form will not be saved in the database and will not be displayed on the Submissions page.',
|
830 |
-
|
831 |
<span class="wd-group theme-wrap">
|
832 |
-
<label class="wd-label"><?php _e('Theme',
|
833 |
<select id="theme" name="theme" onChange="set_theme()">
|
834 |
-
<optgroup label="<?php _e('New Themes',
|
835 |
-
<option value="0" <?php echo $row->theme && $row->theme == 0 ? 'selected' : '' ?> data-version="2"><?php _e('Inherit From Website Theme',
|
836 |
-
|
837 |
-
|
838 |
-
|
839 |
-
|
840 |
-
|
841 |
-
|
842 |
-
|
843 |
-
|
844 |
-
|
845 |
-
<
|
846 |
-
|
847 |
-
<option value="<?php echo $theme->id; ?>" <?php echo(($theme->id == $row->theme) ? 'selected' : ''); ?> data-version="<?php echo $theme->version; ?>"><?php echo $theme->title; ?></option>
|
848 |
-
<?php } ?>
|
849 |
</optgroup>
|
850 |
</select>
|
851 |
<a id="edit_css" class="options-edit-button" onclick="window.open('<?php echo add_query_arg(array(
|
852 |
'current_id' => ($row->theme && $row->theme != '0' ? $row->theme : $default_theme),
|
853 |
-
|
854 |
-
), admin_url('admin.php?page=themes' .
|
855 |
-
<div id="old_theme_notice" class="error inline" style="display: none;"><p><?php _e('The theme you have selected is outdated. Please choose one from New Themes section.',
|
856 |
-
<p class="description"><?php _e('The appearance of your forms is controlled by the theme you select with this option. Press Edit button to open and modify your form theme.',
|
857 |
|
858 |
</span>
|
859 |
<span class="wd-group">
|
860 |
-
<label class="wd-label" for="requiredmark"><?php _e('Required fields mark',
|
861 |
<input type="text" id="requiredmark" name="requiredmark" value="<?php echo $row->requiredmark; ?>">
|
862 |
-
<p class="description"><?php _e('Use this option to change the mark for required fields of your form.',
|
863 |
</span>
|
864 |
<span class="wd-group">
|
865 |
-
<label class="wd-label"><?php _e('Save Uploads',
|
866 |
<input type="radio" name="save_uploads" <?php echo $row->save_uploads == 1 ? 'checked="checked"' : '' ?> id="fm_go-save_uploads-1" class="wd-radio" value="1">
|
867 |
-
<label class="wd-label-radio" for="fm_go-save_uploads-1"><?php _e('Yes',
|
868 |
<input type="radio" name="save_uploads" <?php echo $row->save_uploads == 0 ? 'checked="checked"' : '' ?> id="fm_go-save_uploads-0" class="wd-radio" value="0">
|
869 |
-
<label class="wd-label-radio" for="fm_go-save_uploads-0"><?php _e('No',
|
870 |
-
<p class="description"><?php _e('IMPORTANT! If you disable this option, the files uploaded through your form will not be saved on your site. The files will still be sent to emails and saved in Google Drive or Dropbox, if configured.',
|
871 |
</span>
|
872 |
</div>
|
873 |
</div>
|
@@ -875,63 +899,68 @@ $stats_labels = $params['stats_labels'];
|
|
875 |
<div class="wd-table-col wd-table-col-50 wd-table-col-right">
|
876 |
<div class="wd-box-section">
|
877 |
<div class="wd-box-content">
|
878 |
-
|
879 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
880 |
<?php
|
881 |
-
|
882 |
-
$i = 0;
|
883 |
-
|
884 |
-
echo "\
|
885 |
-
|
886 |
-
|
887 |
-
|
888 |
-
echo ' onchange="acces_level(' . count($userGroups) . ')" /><label for="user_' . $i . '">' . $uG["name"] . '</label><br>';
|
889 |
-
$i++;
|
890 |
}
|
891 |
?>
|
892 |
-
|
893 |
-
|
894 |
-
|
895 |
-
|
896 |
-
<?php if ( count($label_titles_for_submissions) ) { ?>
|
897 |
-
<span class="wd-group">
|
898 |
-
<label class="wd-label"><?php _e('Fields to hide in frontend submissions', WDCFM()->prefix); ?></label>
|
899 |
-
<ul id="form_fields">
|
900 |
-
<li>
|
901 |
-
<input type="checkbox" name="all_fields" id="all_fields" onclick="checkAllByParentId('form_fields'); checked_labels('filed_label')" value="submit_id,<?php echo implode(',', $labels_id_for_submissions) . "," . ($payment_info ? "payment_info" : ""); ?>" />
|
902 |
-
<label for="all_fields"><?php _e('Select All', WDCFM()->prefix); ?></label>
|
903 |
-
</li>
|
904 |
-
<?php
|
905 |
-
echo "<li><input type=\"checkbox\" id=\"submit_id\" name=\"submit_id\" value=\"submit_id\" class=\"filed_label\" onclick=\"checked_labels('filed_label')\"><label for=\"submit_id\">ID</label></li>";
|
906 |
-
for ( $i = 0, $n = count($label_titles_for_submissions); $i < $n; $i++ ) {
|
907 |
-
$field_label = $label_titles_for_submissions[$i];
|
908 |
-
echo "<li><input type=\"checkbox\" id=\"filed_label" . $i . "\" name=\"filed_label" . $i . "\" value=\"" . $labels_id_for_submissions[$i] . "\" class=\"filed_label\" onclick=\"checked_labels('filed_label')\"><label for=\"filed_label" . $i . "\">" . (strlen($field_label) > 80 ? substr($field_label, 0, 80) . '...' : $field_label) . "</label></li>";
|
909 |
-
}
|
910 |
-
if ( $payment_info ) {
|
911 |
-
echo "<li><input type=\"checkbox\" id=\"payment_info\" name=\"payment_info\" value=\"payment_info\" class=\"filed_label\" onclick=\"checked_labels('filed_label')\"><label for=\"payment_info\">Payment Info</label></li>";
|
912 |
-
}
|
913 |
-
?>
|
914 |
-
</ul>
|
915 |
-
<input type="hidden" name="frontend_submit_fields" value="<?php echo $row->frontend_submit_fields ?>" id="frontend_submit_fields" />
|
916 |
-
<p class="description"><?php _e('Select fields of the form and Stats Fields which will not to be displayed within front-end submissions, when you publish them.', WDCFM()->prefix); ?></p>
|
917 |
-
</span>
|
918 |
<?php if ( $stats_labels ) { ?>
|
919 |
<span class="wd-group">
|
920 |
-
|
921 |
-
|
922 |
-
|
923 |
-
|
924 |
-
|
925 |
-
|
926 |
-
|
927 |
-
|
928 |
-
|
929 |
-
|
930 |
-
|
931 |
-
|
932 |
-
|
933 |
-
|
934 |
-
|
935 |
</span>
|
936 |
<?php }
|
937 |
} ?>
|
@@ -946,13 +975,13 @@ $stats_labels = $params['stats_labels'];
|
|
946 |
<div class="wd-box-section">
|
947 |
<div class="wd-box-content">
|
948 |
<div class="wd-group">
|
949 |
-
<label class="wd-label"><?php _e('Send E-mail',
|
950 |
<input type="radio" name="sendemail" <?php echo $row->sendemail == 1 ? 'checked="checked"' : '' ?> id="fm_sendemail-1" class="wd-radio" value="1" onchange="fm_toggle_email_options(true)" />
|
951 |
-
<label class="wd-label-radio" for="fm_sendemail-1"><?php _e('Yes',
|
952 |
<input type="radio" name="sendemail" <?php echo $row->sendemail == 0 ? 'checked="checked"' : '' ?> id="fm_sendemail-0" class="wd-radio" value="0" onchange="fm_toggle_email_options(false)" />
|
953 |
-
<label class="wd-label-radio" for="fm_sendemail-0"><?php _e('No',
|
954 |
-
<p class="description"><?php _e('Enable this setting to send submitted information to administrators
|
955 |
-
<p class="description fm_email_options"><?php _e('In case you cannot find the submission email in your Inbox, make sure to check the Spam folder as well.',
|
956 |
</div>
|
957 |
</div>
|
958 |
</div>
|
@@ -963,14 +992,14 @@ $stats_labels = $params['stats_labels'];
|
|
963 |
<div class="wd-table-col wd-table-col-50 wd-table-col-left">
|
964 |
<div class="wd-box-section">
|
965 |
<div class="wd-box-title">
|
966 |
-
<strong><?php _e('Email to Administrator',
|
967 |
</div>
|
968 |
<div class="wd-box-content">
|
969 |
-
<div class="wd-group">
|
970 |
-
<label class="wd-label" for="mailToAdd"><?php _e('Email to send submissions to',
|
971 |
-
<input type="text" id="mailToAdd" name="mailToAdd"
|
972 |
<input type="hidden" id="mail" name="mail" value="<?php echo $row->mail . ($row->mail && (substr($row->mail, -1) != ',') ? ',' : ''); ?>" />
|
973 |
-
<span class="dashicons dashicons-
|
974 |
<div id="cfm_mail_div">
|
975 |
<?php
|
976 |
$mail_array = explode(',', $row->mail);
|
@@ -978,75 +1007,25 @@ $stats_labels = $params['stats_labels'];
|
|
978 |
if ( $mail && $mail != ',' ) {
|
979 |
?>
|
980 |
<p class="fm_mail_input">
|
981 |
-
<span class="mail_name"><?php echo $mail; ?></span><span class="dashicons dashicons-trash" onclick="fm_delete_mail(this, '<?php echo $mail; ?>')" title="<?php _e('Delete Email',
|
982 |
</p>
|
983 |
<?php
|
984 |
}
|
985 |
}
|
986 |
?>
|
987 |
</div>
|
988 |
-
<p class="description"><?php _e('Specify the email address(es), to which submitted form information will be sent. For multiple email addresses separate with commas.',
|
989 |
</div>
|
990 |
-
<div class="wd-group">
|
991 |
-
<label class="wd-label" for="mail_subject"><?php _e('Subject',
|
992 |
-
<input type="text" id="mail_subject" name="mail_subject" value="<?php echo $row->mail_subject
|
993 |
-
<span class="dashicons dashicons-
|
994 |
-
|
995 |
-
$choise = "'mail_subject'";
|
996 |
-
echo '<div style="position:relative; top:-3px;"><div id="mail_subject_labels" class="email_labels" style="display:none;">';
|
997 |
-
for ( $i = 0; $i < count($label_label); $i++ ) {
|
998 |
-
if ( $label_type[$i] == "type_submit_reset" || $label_type[$i] == "type_editor" || $label_type[$i] == "type_map" || $label_type[$i] == "type_mark_map" || $label_type[$i] == "type_captcha" || $label_type[$i] == "type_recaptcha" || $label_type[$i] == "type_button" || $label_type[$i] == "type_file_upload" || $label_type[$i] == "type_send_copy" || $label_type[$i] == "type_matrix" ) {
|
999 |
-
continue;
|
1000 |
-
}
|
1001 |
-
$param = htmlspecialchars(addslashes($label_label[$i]));
|
1002 |
-
$fld_label = $param;
|
1003 |
-
if ( strlen($fld_label) > 30 ) {
|
1004 |
-
$fld_label = wordwrap(htmlspecialchars(addslashes($label_label[$i])), 30);
|
1005 |
-
$fld_label = explode("\n", $fld_label);
|
1006 |
-
$fld_label = $fld_label[0] . ' ...';
|
1007 |
-
}
|
1008 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'" . $param . "'); document.getElementById('mail_subject_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">" . $fld_label . "</a>";
|
1009 |
-
}
|
1010 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'subid'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Submission ID</a>";
|
1011 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'username'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Username</a>";
|
1012 |
-
echo '</div></div>';
|
1013 |
-
?>
|
1014 |
-
<p class="description"><?php _e('Add a custom subject for the submission email. Click the Plus (+) button to select a form field, the value of which will be set as the subject. In case it’s left blank, Form Title will be set as the subject of submission emails.', WDCFM()->prefix); ?></p>
|
1015 |
</div>
|
1016 |
<div class="wd-group">
|
1017 |
-
<label class="wd-label" for="script_mail"><?php _e('Custom Text in Email For Administrator',
|
1018 |
-
<div class="
|
1019 |
-
|
1020 |
-
<input class="button" type="button" value="All fields list" onClick="insertAtCursor(<?php echo $choise; ?>, 'all')" />
|
1021 |
-
<input class="button" type="button" value="Submission ID" onClick="insertAtCursor(<?php echo $choise; ?>,'subid')" />
|
1022 |
-
<input class="button" type="button" value="Ip" onClick="insertAtCursor(<?php echo $choise; ?>,'ip')" />
|
1023 |
-
<input class="button" type="button" value="Username" onClick="insertAtCursor(<?php echo $choise; ?>,'username')" />
|
1024 |
-
<input class="button" type="button" value="User Email" onClick="insertAtCursor(<?php echo $choise; ?>,'useremail')" />
|
1025 |
-
<?php
|
1026 |
-
for ( $i = 0; $i < count($label_label); $i++ ) {
|
1027 |
-
if ( $label_type[$i] == "type_submit_reset" || $label_type[$i] == "type_editor" || $label_type[$i] == "type_map" || $label_type[$i] == "type_mark_map" || $label_type[$i] == "type_captcha" || $label_type[$i] == "type_recaptcha" || $label_type[$i] == "type_button" || $label_type[$i] == "type_send_copy" ) {
|
1028 |
-
continue;
|
1029 |
-
}
|
1030 |
-
$param = htmlspecialchars(addslashes($label_label[$i]));
|
1031 |
-
$fld_label = $param;
|
1032 |
-
if ( strlen($fld_label) > 30 ) {
|
1033 |
-
$fld_label = wordwrap(htmlspecialchars(addslashes($label_label[$i])), 30);
|
1034 |
-
$fld_label = explode("\n", $fld_label);
|
1035 |
-
$fld_label = $fld_label[0] . ' ...';
|
1036 |
-
}
|
1037 |
-
if ( $label_type[$i] == "type_file_upload" ) {
|
1038 |
-
?>
|
1039 |
-
<input class="button" type="button" value="<?php echo $fld_label . '(as image)'; ?>" onClick="insertAtCursor(<?php echo $choise; ?>, '<?php echo $param; ?>')" />
|
1040 |
-
<input class="button" type="button" value="<?php echo $fld_label . '(as link)'; ?>" onClick="insertAtCursor(<?php echo $choise; ?>, '<?php echo $param . '(link)'; ?>')" />
|
1041 |
-
<?php
|
1042 |
-
}
|
1043 |
-
else {
|
1044 |
-
?>
|
1045 |
-
<input class="button" type="button" value="<?php echo $fld_label; ?>" onClick="insertAtCursor(<?php echo $choise; ?>, '<?php echo $param; ?>')" />
|
1046 |
-
<?php
|
1047 |
-
}
|
1048 |
-
}
|
1049 |
-
?>
|
1050 |
</div>
|
1051 |
<?php
|
1052 |
if ( user_can_richedit() ) {
|
@@ -1063,19 +1042,19 @@ $stats_labels = $params['stats_labels'];
|
|
1063 |
<?php
|
1064 |
}
|
1065 |
?>
|
1066 |
-
<p class="description"><?php _e('Write custom content to the email message which is sent to administrator. Include All Fields List to forward all submitted information, or click on fields buttons to use individual field values in the content.',
|
1067 |
</div>
|
1068 |
<div class="postbox closed">
|
1069 |
<button class="button-link handlediv" type="button" aria-expanded="true">
|
1070 |
-
<span class="screen-reader-text"><?php _e('Toggle panel:',
|
1071 |
<span class="toggle-indicator" aria-hidden="false"></span>
|
1072 |
</button>
|
1073 |
<h2 class="hndle">
|
1074 |
-
<span><?php _e('Advanced',
|
1075 |
</h2>
|
1076 |
<div class="inside">
|
1077 |
<div class="wd-group">
|
1078 |
-
<label class="wd-label"><?php _e('Email From',
|
1079 |
<?php
|
1080 |
$is_other = TRUE;
|
1081 |
for ( $i = 0; $i < $fields_count - 1; $i++ ) {
|
@@ -1096,43 +1075,20 @@ $stats_labels = $params['stats_labels'];
|
|
1096 |
}
|
1097 |
?>
|
1098 |
<input style="<?php echo ($fields_count == 1) ? 'display:none;' : ''; ?>" class="wd-radio" type="radio" id="other" name="from_mail" value="other" <?php echo ($is_other) ? 'checked="checked"' : ''; ?> onclick="wdshow('mail_from_other_wrap')" />
|
1099 |
-
<label style="<?php echo ($fields_count == 1) ? 'display:none;' : ''; ?>" class="wd-label-radio" for="other"><?php _e('Other',
|
1100 |
<p style="display: <?php echo ($is_other) ? 'block;' : 'none;'; ?>" id="mail_from_other_wrap">
|
1101 |
<input type="text" name="mail_from_other" id="mail_from_other" value="<?php echo ($is_other) ? $row->from_mail : ''; ?>" />
|
1102 |
</p>
|
1103 |
-
<p class="description"><?php _e('Specify the email address from which the administrator will receive the email.',
|
1104 |
</div>
|
1105 |
-
<div class="wd-group">
|
1106 |
-
<label class="wd-label" for="from_name"><?php _e('From Name',
|
1107 |
-
<input type="text" name="from_name" value="<?php echo $row->from_name; ?>" id="from_name"
|
1108 |
-
<span class="dashicons dashicons-
|
1109 |
-
<
|
1110 |
-
<div id="mail_from_labels" class="email_labels" style="display:none;">
|
1111 |
-
<?php
|
1112 |
-
$choise = "'from_name'";
|
1113 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'username'); document.getElementById('mail_from_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Username</a>";
|
1114 |
-
for ( $i = 0; $i < count($label_label); $i++ ) {
|
1115 |
-
if ( $label_type[$i] == "type_submit_reset" || $label_type[$i] == "type_editor" || $label_type[$i] == "type_map" || $label_type[$i] == "type_mark_map" || $label_type[$i] == "type_captcha" || $label_type[$i] == "type_recaptcha" || $label_type[$i] == "type_button" || $label_type[$i] == "type_file_upload" || $label_type[$i] == "type_send_copy" || $label_type[$i] == "type_matrix" ) {
|
1116 |
-
continue;
|
1117 |
-
}
|
1118 |
-
$param = htmlspecialchars(addslashes($label_label[$i]));
|
1119 |
-
$fld_label = $param;
|
1120 |
-
if ( strlen($fld_label) > 30 ) {
|
1121 |
-
$fld_label = wordwrap(htmlspecialchars(addslashes($label_label[$i])), 30);
|
1122 |
-
$fld_label = explode("\n", $fld_label);
|
1123 |
-
$fld_label = $fld_label[0] . ' ...';
|
1124 |
-
}
|
1125 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'" . $param . "'); document.getElementById('mail_from_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">" . $fld_label . "</a>";
|
1126 |
-
}
|
1127 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'subid'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Submission ID</a>";
|
1128 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'username'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Username</a>";
|
1129 |
-
?>
|
1130 |
-
</div>
|
1131 |
-
</div>
|
1132 |
-
<p class="description"><?php _e('Set the name which is shown as the sender’s name in submission or confirmation emails. Press the Plus (+) button to select a field value.', WDCFM()->prefix); ?></p>
|
1133 |
</div>
|
1134 |
<div class="wd-group">
|
1135 |
-
<label class="wd-label" for="from_name"><?php _e('Reply to (if different from "Email From")',
|
1136 |
<?php
|
1137 |
$is_other = TRUE;
|
1138 |
for ( $i = 0; $i < $fields_count - 1; $i++ ) {
|
@@ -1153,45 +1109,45 @@ $stats_labels = $params['stats_labels'];
|
|
1153 |
}
|
1154 |
?>
|
1155 |
<input style="<?php echo ($fields_count == 1) ? 'display: none;' : ''; ?>" class="wd-radio" type="radio" id="other1" name="reply_to" value="other" <?php echo ($is_other) ? 'checked="checked"' : ''; ?> onclick="wdshow('reply_to_other_wrap')" />
|
1156 |
-
<label style="<?php echo ($fields_count == 1) ? 'display: none;' : ''; ?>" class="wd-label-radio" for="other1"><?php _e('Other',
|
1157 |
<p style="display: <?php echo ($is_other) ? 'block;' : 'none;'; ?>" id="reply_to_other_wrap">
|
1158 |
<input type="text" name="reply_to_other" value="<?php echo ($is_other && $row->reply_to) ? $row->reply_to : ''; ?>" id="reply_to_other" />
|
1159 |
</p>
|
1160 |
-
<p class="description"><?php _e('Specify an alternative email address, to which the administrator will be able to reply upon receiving the message.',
|
1161 |
</div>
|
1162 |
<div class="wd-group">
|
1163 |
-
<label class="wd-label" for="mail_cc"><?php _e('CC',
|
1164 |
<input type="text" id="mail_cc" name="mail_cc" value="<?php echo $row->mail_cc ?>" />
|
1165 |
-
<p class="description"><?php _e('Provide additional email addresses to send the submission or confirmation email to. The receiver will be able to view all other recipients.',
|
1166 |
</div>
|
1167 |
<div class="wd-group">
|
1168 |
-
<label class="wd-label" for="mail_bcc"><?php _e('BCC',
|
1169 |
<input type="text" id="mail_bcc" name="mail_bcc" value="<?php echo $row->mail_bcc ?>" />
|
1170 |
-
<p class="description"><?php _e('Write additional email addresses to send the submission or confirmation email to. The receiver will not be able to view other recipients.',
|
1171 |
</div>
|
1172 |
<div class="wd-group">
|
1173 |
-
<label class="wd-label"><?php _e('Mode',
|
1174 |
<input type="radio" name="mail_mode" <?php echo $row->mail_mode == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_mode-1" class="wd-radio" value="1">
|
1175 |
-
<label class="wd-label-radio" for="fm_mo_mail_mode-1"><?php _e('HTML',
|
1176 |
<input type="radio" name="mail_mode" <?php echo $row->mail_mode == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_mode-0" class="wd-radio" value="0">
|
1177 |
-
<label class="wd-label-radio" for="fm_mo_mail_mode-0"><?php _e('Text',
|
1178 |
-
<p class="description"><?php _e('Select the layout of the submission email, Text or HTML.',
|
1179 |
</div>
|
1180 |
<div class="wd-group">
|
1181 |
-
<label class="wd-label"><?php _e('Attach File',
|
1182 |
<input type="radio" name="mail_attachment" <?php echo $row->mail_attachment == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_attachment-1" class="wd-radio" value="1">
|
1183 |
-
<label class="wd-label-radio" for="fm_mo_mail_attachment-1"><?php _e('Yes',
|
1184 |
<input type="radio" name="mail_attachment" <?php echo $row->mail_attachment == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_attachment-0" class="wd-radio" value="0">
|
1185 |
-
<label class="wd-label-radio" for="fm_mo_mail_attachment-0"><?php _e('No',
|
1186 |
-
<p class="description"><?php _e('If you have File Upload fields on your form, enable this setting to attach uploaded files to submission or confirmation email.',
|
1187 |
</div>
|
1188 |
<div class="wd-group">
|
1189 |
-
<label class="wd-label"><?php _e('Email empty fields',
|
1190 |
<input type="radio" name="mail_emptyfields" <?php echo $row->mail_emptyfields == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_emptyfields-1" class="wd-radio" value="1">
|
1191 |
-
<label class="wd-label-radio" for="fm_mo_mail_emptyfields-1"><?php _e('Yes',
|
1192 |
<input type="radio" name="mail_emptyfields" <?php echo $row->mail_emptyfields == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_emptyfields-0" class="wd-radio" value="0">
|
1193 |
-
<label class="wd-label-radio" for="fm_mo_mail_emptyfields-0"><?php _e('No',
|
1194 |
-
<p class="description"><?php _e('Disable this setting, in case you do not want to include form fields, which are left empty by the submitter.',
|
1195 |
</div>
|
1196 |
</div>
|
1197 |
</div>
|
@@ -1201,16 +1157,16 @@ $stats_labels = $params['stats_labels'];
|
|
1201 |
<div class="wd-table-col wd-table-col-50 wd-table-col-right">
|
1202 |
<div class="wd-box-section">
|
1203 |
<div class="wd-box-title">
|
1204 |
-
<strong><?php _e('Email to User',
|
1205 |
</div>
|
1206 |
<div class="wd-box-content">
|
1207 |
<div class="wd-group">
|
1208 |
-
<label class="wd-label"><?php _e('Send to',
|
1209 |
<?php
|
1210 |
$fields = explode('*:*id*:*type_submitter_mail*:*type*:*', $row->form_fields);
|
1211 |
$fields_count = count($fields);
|
1212 |
if ( $fields_count == 1 ) {
|
1213 |
-
_e('There is no email field',
|
1214 |
}
|
1215 |
else {
|
1216 |
for ( $i = 0; $i < $fields_count - 1; $i++ ) {
|
@@ -1223,71 +1179,18 @@ $stats_labels = $params['stats_labels'];
|
|
1223 |
}
|
1224 |
}
|
1225 |
?>
|
1226 |
-
<p class="description"><?php _e('Use this setting to select the email field of your form, to which the submissions will be sent.',
|
1227 |
</div>
|
1228 |
-
<div class="wd-group">
|
1229 |
-
<label class="wd-label" for="mail_subject_user"><?php _e('Subject',
|
1230 |
-
<input type="text" name="mail_subject_user" value="<?php echo $row->mail_subject_user ?>" id="mail_subject_user" class="mail_subject_user" />
|
1231 |
-
<span class="dashicons dashicons-
|
1232 |
-
<
|
1233 |
-
<div id="mail_subject_user_labels" class="email_labels" style="display:none;">
|
1234 |
-
<?php
|
1235 |
-
$choise = "'mail_subject_user'";
|
1236 |
-
for ( $i = 0; $i < count($label_label); $i++ ) {
|
1237 |
-
if ( $label_type[$i] == "type_submit_reset" || $label_type[$i] == "type_editor" || $label_type[$i] == "type_map" || $label_type[$i] == "type_mark_map" || $label_type[$i] == "type_captcha" || $label_type[$i] == "type_recaptcha" || $label_type[$i] == "type_button" || $label_type[$i] == "type_file_upload" || $label_type[$i] == "type_send_copy" ) {
|
1238 |
-
continue;
|
1239 |
-
}
|
1240 |
-
$param = htmlspecialchars(addslashes($label_label[$i]));
|
1241 |
-
$fld_label = $param;
|
1242 |
-
if ( strlen($fld_label) > 30 ) {
|
1243 |
-
$fld_label = wordwrap(htmlspecialchars(addslashes($label_label[$i])), 30);
|
1244 |
-
$fld_label = explode("\n", $fld_label);
|
1245 |
-
$fld_label = $fld_label[0] . ' ...';
|
1246 |
-
}
|
1247 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'" . $param . "'); document.getElementById('mail_subject_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">" . $fld_label . "</a>";
|
1248 |
-
}
|
1249 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'subid'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Submission ID</a>";
|
1250 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'username'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Username</a>";
|
1251 |
-
?>
|
1252 |
-
</div>
|
1253 |
-
</div>
|
1254 |
-
<p class="description"><?php _e('Add a custom subject for the submission email. Click the Plus (+) button to select a form field, the value of which will be set as the subject. In case it’s left blank, Form Title will be set as the subject of submission emails.', WDCFM()->prefix); ?></p>
|
1255 |
</div>
|
1256 |
<div class="wd-group">
|
1257 |
-
<label class="wd-label" for="script_mail_user"><?php _e('Custom Text in Email For User',
|
1258 |
-
<div class="
|
1259 |
-
|
1260 |
-
<input class="button" type="button" value="All fields list" onClick="insertAtCursor(<?php echo $choise; ?>, 'all')" />
|
1261 |
-
<input class="button" type="button" value="Submission ID" onClick="insertAtCursor(<?php echo $choise; ?>,'subid')" />
|
1262 |
-
<input class="button" type="button" value="Ip" onClick="insertAtCursor(<?php echo $choise; ?>,'ip')" />
|
1263 |
-
<input class="button" type="button" value="Username" onClick="insertAtCursor(<?php echo $choise; ?>,'username')" />
|
1264 |
-
<input class="button" type="button" value="User Email" onClick="insertAtCursor(<?php echo $choise; ?>,'useremail')" />
|
1265 |
-
<?php
|
1266 |
-
for ( $i = 0; $i < count($label_label); $i++ ) {
|
1267 |
-
if ( $label_type[$i] == "type_submit_reset" || $label_type[$i] == "type_editor" || $label_type[$i] == "type_map" || $label_type[$i] == "type_mark_map" || $label_type[$i] == "type_captcha" || $label_type[$i] == "type_recaptcha" || $label_type[$i] == "type_button" || $label_type[$i] == "type_send_copy" ) {
|
1268 |
-
continue;
|
1269 |
-
}
|
1270 |
-
$param = htmlspecialchars(addslashes($label_label[$i]));
|
1271 |
-
$fld_label = $param;
|
1272 |
-
if ( strlen($fld_label) > 30 ) {
|
1273 |
-
$fld_label = wordwrap(htmlspecialchars(addslashes($label_label[$i])), 30);
|
1274 |
-
$fld_label = explode("\n", $fld_label);
|
1275 |
-
$fld_label = $fld_label[0] . ' ...';
|
1276 |
-
}
|
1277 |
-
if ( $label_type[$i] == "type_file_upload" ) {
|
1278 |
-
?>
|
1279 |
-
<input class="button" type="button" value="<?php echo $fld_label . '(as image)'; ?>" onClick="insertAtCursor(<?php echo $choise; ?>, '<?php echo $param; ?>')" />
|
1280 |
-
<input class="button" type="button" value="<?php echo $fld_label . '(as link)'; ?>" onClick="insertAtCursor(<?php echo $choise; ?>, '<?php echo $param . '(link)'; ?>')" />
|
1281 |
-
<?php
|
1282 |
-
}
|
1283 |
-
else {
|
1284 |
-
?>
|
1285 |
-
<input class="button" type="button" value="<?php echo $fld_label; ?>" onClick="insertAtCursor(<?php echo $choise; ?>, '<?php echo $param; ?>')" />
|
1286 |
-
<?php
|
1287 |
-
}
|
1288 |
-
}
|
1289 |
-
?>
|
1290 |
-
<input <?php echo($row->mail_verify == 0 ? 'style="display:none;"' : ''); ?> class="button verification_div" type="button" value="Verification link" onClick="insertAtCursor(<?php echo $choise; ?>,'Verification link')" />
|
1291 |
</div>
|
1292 |
<?php
|
1293 |
if ( user_can_richedit() ) {
|
@@ -1304,98 +1207,76 @@ $stats_labels = $params['stats_labels'];
|
|
1304 |
<?php
|
1305 |
}
|
1306 |
?>
|
1307 |
-
<p class="description"><?php _e('Write custom content to the email message which is sent to submitter. Include All Fields List to forward all submitted information, or click on fields buttons to use individual field values in the content.',
|
1308 |
</div>
|
1309 |
<div class="postbox closed">
|
1310 |
<button class="button-link handlediv" type="button" aria-expanded="true">
|
1311 |
-
<span class="screen-reader-text"><?php _e('Toggle panel:',
|
1312 |
<span class="toggle-indicator" aria-hidden="false"></span>
|
1313 |
</button>
|
1314 |
<h2 class="hndle">
|
1315 |
-
<span><?php _e('Advanced',
|
1316 |
</h2>
|
1317 |
<div class="inside">
|
1318 |
<div class="wd-group">
|
1319 |
-
<label class="wd-label" for="mail_from_user"><?php _e('Email From',
|
1320 |
<input type="text" id="mail_from_user" name="mail_from_user" value="<?php echo $row->mail_from_user; ?>" />
|
1321 |
-
<p class="description"><?php _e('Specify the email address from which the submitter will receive the email.',
|
1322 |
</div>
|
1323 |
-
<div class="wd-group">
|
1324 |
-
<label class="wd-label" for="mail_from_name_user"><?php _e('From Name',
|
1325 |
-
<input type="text" name="mail_from_name_user" value="<?php echo $row->mail_from_name_user; ?>" id="mail_from_name_user"
|
1326 |
-
<span class="dashicons dashicons-
|
1327 |
-
<
|
1328 |
-
<div id="mail_from_name_user_labels" class="email_labels" style="display:none;">
|
1329 |
-
<?php
|
1330 |
-
$choise = "'mail_from_name_user'";
|
1331 |
-
for ( $i = 0; $i < count($label_label); $i++ ) {
|
1332 |
-
if ( $label_type[$i] == "type_submit_reset" || $label_type[$i] == "type_editor" || $label_type[$i] == "type_map" || $label_type[$i] == "type_mark_map" || $label_type[$i] == "type_captcha" || $label_type[$i] == "type_recaptcha" || $label_type[$i] == "type_button" || $label_type[$i] == "type_file_upload" || $label_type[$i] == "type_send_copy" ) {
|
1333 |
-
continue;
|
1334 |
-
}
|
1335 |
-
$param = htmlspecialchars(addslashes($label_label[$i]));
|
1336 |
-
$fld_label = $param;
|
1337 |
-
if ( strlen($fld_label) > 30 ) {
|
1338 |
-
$fld_label = wordwrap(htmlspecialchars(addslashes($label_label[$i])), 30);
|
1339 |
-
$fld_label = explode("\n", $fld_label);
|
1340 |
-
$fld_label = $fld_label[0] . ' ...';
|
1341 |
-
}
|
1342 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'" . $param . "'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">" . $fld_label . "</a>";
|
1343 |
-
}
|
1344 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'subid'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Submission ID</a>";
|
1345 |
-
echo "<a onClick=\"insertAtCursor(" . $choise . ",'username'); document.getElementById('mail_from_name_user_labels').style.display='none';\" style=\"display:block; text-decoration:none;\">Username</a>";
|
1346 |
-
?>
|
1347 |
-
</div>
|
1348 |
-
</div>
|
1349 |
-
<p class="description"><?php _e('Set the name which is shown as the sender’s name in submission or confirmation emails. Press the Plus (+) button to select a field value.', WDCFM()->prefix); ?></p>
|
1350 |
</div>
|
1351 |
<div class="wd-group">
|
1352 |
-
<label class="wd-label" for="reply_to_user"><?php _e('Reply to (if different from "Email From")',
|
1353 |
<input type="text" name="reply_to_user" value="<?php echo $row->reply_to_user; ?>" id="reply_to_user" />
|
1354 |
-
<p class="description"><?php _e('Specify an alternative email address, to which the submitter will be able to reply upon receiving the message.',
|
1355 |
</div>
|
1356 |
<div class="wd-group">
|
1357 |
-
<label class="wd-label" for="mail_cc_user"><?php _e('CC',
|
1358 |
<input type="text" name="mail_cc_user" value="<?php echo $row->mail_cc_user ?>" id="mail_cc_user" />
|
1359 |
-
<p class="description"><?php _e('Provide additional email addresses to send the submission or confirmation email to. The receiver will be able to view all other recipients.',
|
1360 |
</div>
|
1361 |
<div class="wd-group">
|
1362 |
-
<label class="wd-label" for="mail_bcc_user"><?php _e('BCC',
|
1363 |
<input type="text" name="mail_bcc_user" value="<?php echo $row->mail_bcc_user ?>" id="mail_bcc_user" />
|
1364 |
-
<p class="description"><?php _e('Write additional email addresses to send the submission or confirmation email to. The receiver will not be able to view other recipients.',
|
1365 |
</div>
|
1366 |
<div class="wd-group">
|
1367 |
-
<label class="wd-label"><?php _e('Mode',
|
1368 |
<input type="radio" name="mail_mode_user" <?php echo $row->mail_mode_user == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_mode_user-1" class="wd-radio" value="1">
|
1369 |
-
<label class="wd-label-radio" for="fm_mo_mail_mode_user-1"><?php _e('HTML',
|
1370 |
<input type="radio" name="mail_mode_user" <?php echo $row->mail_mode_user == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_mode_user-0" class="wd-radio" value="0">
|
1371 |
-
<label class="wd-label-radio" for="fm_mo_mail_mode_user-0"><?php _e('Text',
|
1372 |
-
<p class="description"><?php _e('Select the layout of the submission email, Text or HTML.',
|
1373 |
</div>
|
1374 |
<div class="wd-group">
|
1375 |
-
<label class="wd-label"><?php _e('Attach File',
|
1376 |
<input type="radio" name="mail_attachment_user" <?php echo $row->mail_attachment_user == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_attachment_user-1" class="wd-radio" value="1">
|
1377 |
-
<label class="wd-label-radio" for="fm_mo_mail_attachment_user-1"><?php _e('Yes',
|
1378 |
<input type="radio" name="mail_attachment_user" <?php echo $row->mail_attachment_user == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_attachment_user-0" class="wd-radio" value="0">
|
1379 |
-
<label class="wd-label-radio" for="fm_mo_mail_attachment_user-0"><?php _e('No',
|
1380 |
-
<p class="description"><?php _e('If you have File Upload fields on your form, enable this setting to attach uploaded files to submission or confirmation email.',
|
1381 |
</div>
|
1382 |
<div class="wd-group">
|
1383 |
-
<label class="wd-label"><?php _e('Email verification',
|
1384 |
<input type="radio" name="mail_verify" <?php echo $row->mail_verify == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_verify-1" onclick="wdshow('expire_link')" class="wd-radio" value="1">
|
1385 |
-
<label class="wd-label-radio" for="fm_mo_mail_verify-1"><?php _e('Yes',
|
1386 |
<input type="radio" name="mail_verify" <?php echo $row->mail_verify == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_verify-0" onclick="wdhide('expire_link')" class="wd-radio" value="0">
|
1387 |
-
<label class="wd-label-radio" for="fm_mo_mail_verify-0"><?php _e('No',
|
1388 |
-
<p class="description"><?php _e('Activate this option, in case you would like the users to verify their email addresses. If it’s enabled, the user email will contain a verification link.',
|
1389 |
</div>
|
1390 |
<div class="wd-group" <?php echo($row->mail_verify == 0 ? 'style="display:none;"' : '') ?> id="expire_link">
|
1391 |
-
<label class="wd-label" for="mail_verify_expiretime"><?php _e('Verification link expires in',
|
1392 |
<input class="inputbox" type="text" name="mail_verify_expiretime" maxlength="10" value="<?php echo($row->mail_verify_expiretime ? $row->mail_verify_expiretime : 0); ?>" onkeypress="return check_isnum_point(event)" id="mail_verify_expiretime">
|
1393 |
-
<small><?php _e(' -- hours (0 - never expires).',
|
1394 |
<a target="_blank" href="<?php echo add_query_arg(array(
|
1395 |
'post' => $params["mail_ver_id"],
|
1396 |
'action' => 'edit',
|
1397 |
-
), admin_url('post.php')); ?>"><?php _e('Edit post',
|
1398 |
-
<p class="description"><?php _e('Use this option to specify a time period (hours), during which the user will be able to verify their email address.',
|
1399 |
</div>
|
1400 |
</div>
|
1401 |
</div>
|
@@ -1410,25 +1291,25 @@ $stats_labels = $params['stats_labels'];
|
|
1410 |
<div class="wd-box-section">
|
1411 |
<div class="wd-box-content">
|
1412 |
<span class="wd-group">
|
1413 |
-
<label class="wd-label"><?php _e('Action type',
|
1414 |
<input type="radio" name="submit_text_type" id="text_type_none" onclick="set_type('none')" value="1" <?php echo ($row->submit_text_type != 2 && $row->submit_text_type != 3 && $row->submit_text_type != 4 && $row->submit_text_type != 5) ? "checked" : ""; ?> />
|
1415 |
-
<label for="text_type_none"><?php _e('Stay on Form',
|
1416 |
<br>
|
1417 |
<input type="radio" name="submit_text_type" id="text_type_post" onclick="set_type('post')" value="2" <?php echo ($row->submit_text_type == 2) ? "checked" : ""; ?> />
|
1418 |
-
<label for="text_type_post"><?php _e('Post',
|
1419 |
<br>
|
1420 |
<input type="radio" name="submit_text_type" id="text_type_page" onclick="set_type('page')" value="5" <?php echo ($row->submit_text_type == 5) ? "checked" : ""; ?> />
|
1421 |
-
<label for="text_type_page"><?php _e('Page',
|
1422 |
<br>
|
1423 |
<input type="radio" name="submit_text_type" id="text_type_custom_text" onclick="set_type('custom_text')" value="3" <?php echo ($row->submit_text_type == 3) ? "checked" : ""; ?> />
|
1424 |
-
<label for="text_type_custom_text"><?php _e('Custom Text',
|
1425 |
<br>
|
1426 |
<input type="radio" name="submit_text_type" id="text_type_url" onclick="set_type('url')" value="4" <?php echo ($row->submit_text_type == 4) ? "checked" : ""; ?> />
|
1427 |
-
<label for="text_type_url"><?php _e('URL',
|
1428 |
</span>
|
1429 |
<span class="wd-group">
|
1430 |
<div id="post" <?php echo(($row->submit_text_type != 2) ? 'style="display:none"' : ''); ?>>
|
1431 |
-
<label class="wd-label"><?php _e('Post',
|
1432 |
<select id="post_name" name="post_name">
|
1433 |
<option value="0">- Select Post -</option>
|
1434 |
<?php
|
@@ -1445,7 +1326,7 @@ $stats_labels = $params['stats_labels'];
|
|
1445 |
</select>
|
1446 |
</div>
|
1447 |
<div id="page" <?php echo(($row->submit_text_type != 5) ? 'style="display:none"' : ''); ?>>
|
1448 |
-
<label class="wd-label"><?php _e('Page',
|
1449 |
<select id="page_name" name="page_name">
|
1450 |
<option value="0">- Select Page -</option>
|
1451 |
<?php
|
@@ -1461,32 +1342,10 @@ $stats_labels = $params['stats_labels'];
|
|
1461 |
</select>
|
1462 |
</div>
|
1463 |
<div id="custom_text" <?php echo(($row->submit_text_type != 3) ? 'style="display: none;"' : ''); ?>>
|
1464 |
-
<label class="wd-label"><?php _e('Text',
|
1465 |
-
<div class="
|
1466 |
-
|
1467 |
-
|
1468 |
-
<input class="button" type="button" value="Ip" onClick="insertAtCursor(<?php echo $choise; ?>,'ip')" />
|
1469 |
-
<input class="button" type="button" value="User Id" onClick="insertAtCursor(<?php echo $choise; ?>, 'userid')" />
|
1470 |
-
<input class="button" type="button" value="Username" onClick="insertAtCursor(<?php echo $choise; ?>,'username')" />
|
1471 |
-
<input class="button" type="button" value="User Email" onClick="insertAtCursor(<?php echo $choise; ?>,'useremail')" />
|
1472 |
-
<?php
|
1473 |
-
for ( $i = 0; $i < count($label_label); $i++ ) {
|
1474 |
-
if ( $label_type[$i] == "type_submit_reset" || $label_type[$i] == "type_editor" || $label_type[$i] == "type_map" || $label_type[$i] == "type_mark_map" || $label_type[$i] == "type_captcha" || $label_type[$i] == "type_recaptcha" || $label_type[$i] == "type_button" || $label_type[$i] == "type_send_copy" || $label_type[$i] == "type_file_upload" ) {
|
1475 |
-
continue;
|
1476 |
-
}
|
1477 |
-
$param = htmlspecialchars(addslashes($label_label[$i]));
|
1478 |
-
$fld_label = $param;
|
1479 |
-
if ( strlen($fld_label) > 30 ) {
|
1480 |
-
$fld_label = wordwrap(htmlspecialchars(addslashes($label_label[$i])), 30);
|
1481 |
-
$fld_label = explode("\n", $fld_label);
|
1482 |
-
$fld_label = $fld_label[0] . ' ...';
|
1483 |
-
}
|
1484 |
-
?>
|
1485 |
-
<input class="button" type="button" value="<?php echo $fld_label; ?>" onClick="insertAtCursor(<?php echo $choise; ?>, '<?php echo $param; ?>')" />
|
1486 |
-
<?php
|
1487 |
-
}
|
1488 |
-
?>
|
1489 |
-
</div>
|
1490 |
<?php
|
1491 |
if ( user_can_richedit() ) {
|
1492 |
wp_editor($row->submit_text, 'submit_text', array(
|
@@ -1506,7 +1365,7 @@ $stats_labels = $params['stats_labels'];
|
|
1506 |
?>
|
1507 |
</div>
|
1508 |
<div id="url" <?php echo(($row->submit_text_type != 4) ? 'style="display:none"' : ''); ?>>
|
1509 |
-
<label class="wd-label"><?php _e('URL',
|
1510 |
<input type="text" id="url" name="url" value="<?php echo $row->url; ?>" />
|
1511 |
</div>
|
1512 |
</span>
|
@@ -1515,25 +1374,29 @@ $stats_labels = $params['stats_labels'];
|
|
1515 |
</div>
|
1516 |
</div>
|
1517 |
</div>
|
1518 |
-
|
1519 |
<div id="payment_fieldset" class="adminform fm_fieldset_deactive">
|
1520 |
<div class="wd-table">
|
1521 |
<div class="wd-table-col-70">
|
1522 |
<div class="wd-box-section">
|
1523 |
<div class="wd-box-content">
|
1524 |
<div class="wd-group">
|
1525 |
-
<label class="wd-label"><?php _e('Payment Method',
|
1526 |
<input type="radio" name="paypal_mode" id="paypal_mode0" value="none" class="wd-radio" <?php echo ($payment_method == "none") ? "checked" : ""; ?> onchange="fm_change_payment_method('none');" />
|
1527 |
-
<label for="paypal_mode0"><?php _e('None',
|
1528 |
<input type="radio" name="paypal_mode" id="paypal_mode1" value="paypal" class="wd-radio" <?php echo ($payment_method == "paypal") ? "checked" : ""; ?> onchange="fm_change_payment_method('paypal');" />
|
1529 |
-
<label for="paypal_mode1"><?php _e('Paypal',
|
1530 |
<input type="radio" name="paypal_mode" id="paypal_mode2" value="stripe" <?php echo ($payment_method == "stripe") ? "checked" : ""; ?> class="wd-radio" onchange="fm_change_payment_method('stripe');" />
|
1531 |
-
<label for="paypal_mode2"><?php _e('Stripe',
|
1532 |
</div>
|
1533 |
<div class="fm_payment_option">
|
1534 |
-
|
1535 |
-
|
1536 |
-
|
|
|
|
|
|
|
|
|
|
|
1537 |
<option value="USD" <?php echo(($row->payment_currency == 'USD') ? 'selected' : ''); ?>>$ • U.S. Dollar</option>
|
1538 |
<option value="EUR" <?php echo(($row->payment_currency == 'EUR') ? 'selected' : ''); ?>>€ • Euro</option>
|
1539 |
<option value="GBP" <?php echo(($row->payment_currency == 'GBP') ? 'selected' : ''); ?>>£ • Pound Sterling</option>
|
@@ -1558,34 +1421,43 @@ $stats_labels = $params['stats_labels'];
|
|
1558 |
<option value="PHP" <?php echo(($row->payment_currency == 'PHP') ? 'selected' : ''); ?>>₱ • Philippine Peso</option>
|
1559 |
<option value="THB" <?php echo(($row->payment_currency == 'THB') ? 'selected' : ''); ?>>฿ • Thai Bahtv</option>
|
1560 |
</select>
|
1561 |
-
<p class="description"><?php _e('Choose the currency to be used for the payments made through your form.',
|
1562 |
</div>
|
1563 |
-
<div class="wd-group">
|
1564 |
-
<label class="wd-label" for="tax"><?php _e('Tax',
|
1565 |
-
<input type="text" name="tax" id="tax" value="<?php echo $row->tax; ?>" class="text_area" onKeyPress="return check_isnum_point(event)"
|
1566 |
-
<p class="description"><?php _e('Specify the percentage of the tax. It will be calculated from the total payment amount of your form.',
|
1567 |
</div>
|
1568 |
-
<div class="wd-group">
|
1569 |
-
<label class="wd-label"><?php _e('Checkout Mode',
|
1570 |
-
<input type="radio" name="checkout_mode" <?php echo $row->checkout_mode == 1 ? 'checked="checked"' : '' ?> id="checkout_mode-1" class="wd-radio" value="1"
|
1571 |
-
<label class="wd-label-radio" for="checkout_mode-1"><?php _e('Production',
|
1572 |
-
<input type="radio" name="checkout_mode" <?php echo $row->checkout_mode == 0 ? 'checked="checked"' : '' ?> id="checkout_mode-0" class="wd-radio" value="0"
|
1573 |
-
<label class="wd-label-radio" for="checkout_mode-0"><?php _e('Testmode',
|
1574 |
</div>
|
1575 |
-
<div class="wd-group">
|
1576 |
-
<label class="wd-label" for="paypal_email"><?php _e('Paypal email',
|
1577 |
-
<input type="text" name="paypal_email" id="paypal_email" value="<?php echo $row->paypal_email; ?>" class="text_area"
|
1578 |
-
<p class="description"><?php _e('Provide the email address of a valid PayPal account. It will receive the payments made through your form.',
|
1579 |
</div>
|
1580 |
</div>
|
1581 |
<div class="fm_payment_option_stripe">
|
1582 |
<?php
|
1583 |
if ( $stripe_addon['enable'] && !empty($stripe_addon['html']) ) {
|
1584 |
-
|
|
|
|
|
|
|
|
|
|
|
1585 |
}
|
1586 |
else {
|
1587 |
-
|
1588 |
-
|
|
|
|
|
|
|
|
|
1589 |
}
|
1590 |
?>
|
1591 |
</div>
|
@@ -1713,9 +1585,9 @@ $stats_labels = $params['stats_labels'];
|
|
1713 |
<div class="wd-box-section">
|
1714 |
<div class="wd-box-content">
|
1715 |
<div class="wd-group" id="conditions_fieldset_wrap">
|
1716 |
-
<p class="description"><?php _e('Press Add Condition button to configure the first condition of your form. Show/Hide select box represents the action which will be completed, if all or any of the condition statements are fulfilled. Use the second drop-down menu to select the field which will be shown or hidden. Click the little Plus (+) icon to add the statement of your form condition.',
|
1717 |
<div style="text-align: right;">
|
1718 |
-
|
1719 |
</div>
|
1720 |
<?php
|
1721 |
for ( $k = 0; $k < $count_of_conditions; $k++ ) {
|
@@ -1725,10 +1597,10 @@ $stats_labels = $params['stats_labels'];
|
|
1725 |
<select id="show_hide<?php echo $k; ?>" name="show_hide<?php echo $k; ?>" class="fm_condition_show_hide">
|
1726 |
<option value="1" <?php if ( $show_hide[$k] == 1 ) {
|
1727 |
echo 'selected="selected"';
|
1728 |
-
} ?>><?php _e('Show',
|
1729 |
<option value="0" <?php if ( $show_hide[$k] == 0 ) {
|
1730 |
echo 'selected="selected"';
|
1731 |
-
} ?>><?php _e('Hide',
|
1732 |
</select>
|
1733 |
<select id="fields<?php echo $k; ?>" name="fields<?php echo $k; ?>" class="fm_condition_fields">
|
1734 |
<?php
|
@@ -1747,12 +1619,12 @@ $stats_labels = $params['stats_labels'];
|
|
1747 |
<select id="all_any<?php echo $k; ?>" name="all_any<?php echo $k; ?>" class="fm_condition_all_any">
|
1748 |
<option value="and" <?php if ( $all_any[$k] == "and" ) {
|
1749 |
echo 'selected="selected"';
|
1750 |
-
} ?>><?php _e('all',
|
1751 |
<option value="or" <?php if ( $all_any[$k] == "or" ) {
|
1752 |
echo 'selected="selected"';
|
1753 |
-
} ?>><?php _e('any',
|
1754 |
</select>
|
1755 |
-
<span style="display: inline-block; width: 100%; max-width: 235px;"><?php _e('of the following match:',
|
1756 |
<span class="dashicons dashicons-trash" onclick="delete_condition('<?php echo $k; ?>')"></span>
|
1757 |
<span class="dashicons dashicons-plus-alt" onclick="add_condition_fields(<?php echo $k; ?>,'<?php echo $chose_ids; ?>', '<?php echo htmlspecialchars(addslashes($chose_labels)); ?>', '<?php echo $chose_types; ?>', '<?php echo htmlspecialchars(addslashes($chose_paramss)); ?>')"></span>
|
1758 |
</div>
|
@@ -1870,7 +1742,7 @@ $stats_labels = $params['stats_labels'];
|
|
1870 |
}
|
1871 |
}
|
1872 |
if ( $types[$key_select_or_input] == "type_address" ) {
|
1873 |
-
$w_countries =
|
1874 |
$w_options = '';
|
1875 |
foreach ( $w_countries as $w_country ) {
|
1876 |
if ( in_array($w_country, $multiselect) ) {
|
@@ -1921,8 +1793,8 @@ $stats_labels = $params['stats_labels'];
|
|
1921 |
|
1922 |
<div id="mapping_fieldset" class="adminform fm_fieldset_deactive">
|
1923 |
<?php
|
1924 |
-
if (
|
1925 |
-
echo
|
1926 |
}
|
1927 |
else {
|
1928 |
?>
|
@@ -1931,30 +1803,30 @@ $stats_labels = $params['stats_labels'];
|
|
1931 |
<div class="wd-box-section">
|
1932 |
<div class="wd-box-content">
|
1933 |
<div class="wd-group">
|
1934 |
-
<p class="description"><?php _e('WordPress Form Maker stores the submitted information into [prefix]_formmaker_submits MySQL database table of your website by default. With MySQL Mapping functionality of Form Maker you can insert this data into any local or remote table of your choice, or perform other queries based on submitted values. Press Add Query button to configure the first query for this form.',
|
1935 |
<div style="text-align: right; padding-bottom: 20px;">
|
1936 |
<button id="add_query" class="wd-button button-primary" onclick="tb_show('', '<?php echo add_query_arg(array(
|
1937 |
-
'action' => 'FormMakerSQLMapping' .
|
1938 |
'id' => 0,
|
1939 |
'form_id' => $row->id,
|
1940 |
'width' => '1000',
|
1941 |
'height' => '500',
|
1942 |
'TB_iframe' => '1'
|
1943 |
-
), admin_url('admin-ajax.php')); ?>'); return false;"><?php _e('Add Query',
|
1944 |
</div>
|
1945 |
<?php if ( $queries ) { ?>
|
1946 |
<table class="wp-list-table widefat fixed posts table_content">
|
1947 |
<thead>
|
1948 |
<tr>
|
1949 |
-
<th style="width:86%;" class="table_large_col"><?php _e('Query',
|
1950 |
-
<th style="width:14%;" class="table_large_col"><?php _e('Delete',
|
1951 |
</tr>
|
1952 |
</thead>
|
1953 |
<?php
|
1954 |
for ( $i = 0, $n = count($queries); $i < $n; $i++ ) {
|
1955 |
$query = $queries[$i];
|
1956 |
$link = add_query_arg(array(
|
1957 |
-
'action' => 'FormMakerSQLMapping' .
|
1958 |
'id' => $query->id,
|
1959 |
'form_id' => $row->id,
|
1960 |
'width' => '1000',
|
@@ -2008,7 +1880,7 @@ $stats_labels = $params['stats_labels'];
|
|
2008 |
<script>
|
2009 |
default_theme = '<?php echo $default_theme; ?>';
|
2010 |
payment_method = '<?php echo $payment_method; ?>';
|
2011 |
-
theme_edit_url = '<?php echo add_query_arg( array('page' => 'themes' .
|
2012 |
|
2013 |
jQuery(document).ready( function () {
|
2014 |
set_theme();
|
@@ -2016,6 +1888,58 @@ $stats_labels = $params['stats_labels'];
|
|
2016 |
</script>
|
2017 |
<?php
|
2018 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2019 |
|
2020 |
/**
|
2021 |
* Form layout.
|
@@ -2024,20 +1948,20 @@ $stats_labels = $params['stats_labels'];
|
|
2024 |
*
|
2025 |
*/
|
2026 |
public function form_layout( $params ) {
|
2027 |
-
wp_enqueue_style('
|
2028 |
-
wp_enqueue_style('
|
2029 |
|
2030 |
-
wp_enqueue_script('
|
2031 |
-
wp_enqueue_script('
|
2032 |
-
wp_enqueue_script('
|
2033 |
-
wp_enqueue_script('
|
2034 |
-
wp_enqueue_script('
|
2035 |
-
wp_enqueue_script('
|
2036 |
-
wp_enqueue_script('
|
2037 |
-
wp_enqueue_script('
|
2038 |
-
wp_enqueue_script('
|
2039 |
-
wp_enqueue_script('
|
2040 |
-
wp_enqueue_script('
|
2041 |
|
2042 |
$id = $params['id'];
|
2043 |
$page = $params['page'];
|
@@ -2053,13 +1977,13 @@ $stats_labels = $params['stats_labels'];
|
|
2053 |
);
|
2054 |
$buttons = array(
|
2055 |
'save' => array(
|
2056 |
-
'title' => __('Update',
|
2057 |
'value' => 'save',
|
2058 |
'onclick' => 'fm_apply_advanced_layout(\'apply_layout\');',
|
2059 |
'class' => 'button-primary'
|
2060 |
),
|
2061 |
'back' => array(
|
2062 |
-
'title' => __('Back to Form',
|
2063 |
'value' => 'back',
|
2064 |
'onclick' => 'window.open(\''. $back_url .'\', \'_self\'); return false;',
|
2065 |
'class' => 'button'
|
@@ -2073,9 +1997,9 @@ $stats_labels = $params['stats_labels'];
|
|
2073 |
|
2074 |
// Pass the content to form.
|
2075 |
$form_attr = array(
|
2076 |
-
'id' =>
|
2077 |
'name' => 'adminForm',
|
2078 |
-
'class' =>
|
2079 |
'current_id' => $id,
|
2080 |
'enctype' => 'multipart/form-data',
|
2081 |
'action' => add_query_arg( array('page' => $page, 'current_id' => $id ), $page_url),
|
@@ -2100,16 +2024,16 @@ $stats_labels = $params['stats_labels'];
|
|
2100 |
<div class="wd-table-col-100">
|
2101 |
<div class="wd-box-section">
|
2102 |
<div class="wd-box-content">
|
2103 |
-
<p><?php _e('To customize the layout of the form fields uncheck the Auto-Generate Layout box and edit the HTML.',
|
2104 |
-
<p><?php _e('You can change positioning, add in-line styles and etc. Click on the provided buttons to add the corresponding field.',
|
2105 |
-
<p><?php _e('This will add the following line:',
|
2106 |
-
<b><span class="cm-tag"><div</span> <span class="cm-attribute">wdid</span>=<span class="cm-string">"example_id"</span> <span class="cm-attribute">class</span>=<span class="cm-string">"wdform_row"</span><span class="cm-tag">></span>%example_id - Example%<span class="cm-tag"></div></span></b> , where <b><span class="cm-tag"><div></span></b> <?php _e('is used to set a row.',
|
2107 |
<p>
|
2108 |
-
<b style="color:red"><?php _e('Notice',
|
2109 |
-
<?php _e('Make sure not to publish the same field twice. This will cause malfunctioning of the form.',
|
2110 |
</p>
|
2111 |
<div class="wd-group">
|
2112 |
-
<label class="wd-label autogen_layout_label" for="autogen_layout"><?php _e('Auto Generate Layout?',
|
2113 |
<input type="checkbox" value="1" name="autogen_layout" id="autogen_layout" <?php echo (($row->autogen_layout) ? 'checked="checked"' : ''); ?> />
|
2114 |
</div>
|
2115 |
<div class="wd-group">
|
@@ -2124,7 +2048,7 @@ $stats_labels = $params['stats_labels'];
|
|
2124 |
}
|
2125 |
?>
|
2126 |
</div>
|
2127 |
-
<span class="button button-hero fm_auto_format_button" onclick="autoFormat()"><strong><?php _e('Apply Source Formatting',
|
2128 |
<textarea id="source" name="source" style="display: none;"></textarea>
|
2129 |
<input type="hidden" name="custom_front" id="custom_front" value="" />
|
2130 |
</div>
|
@@ -2146,7 +2070,6 @@ $stats_labels = $params['stats_labels'];
|
|
2146 |
$page = $params['page'];
|
2147 |
$page_url = $params['page_url'];
|
2148 |
|
2149 |
-
|
2150 |
if($fieldset_id != "embedded") $row->type = $fieldset_id;
|
2151 |
|
2152 |
ob_start();
|
@@ -2156,7 +2079,7 @@ $stats_labels = $params['stats_labels'];
|
|
2156 |
$form_attr = array(
|
2157 |
'id' => 'adminForm',
|
2158 |
'name' => 'adminForm',
|
2159 |
-
'class' =>
|
2160 |
'current_id' => $id,
|
2161 |
'action' => add_query_arg( array('page' => $page, 'current_id' => $id ), $page_url),
|
2162 |
);
|
@@ -2179,13 +2102,13 @@ $stats_labels = $params['stats_labels'];
|
|
2179 |
|
2180 |
$buttons = array(
|
2181 |
'save' => array(
|
2182 |
-
'title' => __('Update',
|
2183 |
'value' => 'save',
|
2184 |
'onclick' => 'fm_apply_options(\'apply_display_options\');',
|
2185 |
'class' => 'button-primary',
|
2186 |
),
|
2187 |
'back' => array(
|
2188 |
-
'title' => __('Back to Form',
|
2189 |
'value' => 'back',
|
2190 |
'onclick' => 'window.open(\''. $back_url .'\', \'_self\'); return false;',
|
2191 |
'class' => 'button',
|
@@ -2205,7 +2128,7 @@ $stats_labels = $params['stats_labels'];
|
|
2205 |
<div class="wd-box-content">
|
2206 |
<span>
|
2207 |
<div class="fm-row fm-form-types">
|
2208 |
-
<label class="wd-label"><?php _e('Form Type',
|
2209 |
<label>
|
2210 |
<input type="radio" name="form_type" value="embedded" onclick="change_form_type('embedded'); change_hide_show('fm-embedded');"
|
2211 |
<?php echo $row->type == 'embedded' ? 'checked="checked"' : '' ?>>
|
@@ -2241,15 +2164,15 @@ $stats_labels = $params['stats_labels'];
|
|
2241 |
<div class="wd-box-section">
|
2242 |
<div class="wd-box-content">
|
2243 |
<span class="wd-group fm-embedded <?php echo $row->type == 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2244 |
-
<label class="wd-label"><?php _e('Form Placement',
|
2245 |
<div id="fm-embedded-element">
|
2246 |
-
<p><?php _e('Use',
|
2247 |
-
<input type="text" value='[Form id="
|
2248 |
-
<p><?php _e('shortcode to display the form.',
|
2249 |
</div>
|
2250 |
</span>
|
2251 |
<span class="wd-group fm-popover <?php echo $row->type == 'popover' ? 'fm-show' : 'fm-hide' ?>">
|
2252 |
-
<label class="wd-label"><?php _e('Animation Effect',
|
2253 |
<select id="popover_animate_effect" name="popover_animate_effect">
|
2254 |
<?php
|
2255 |
foreach($animation_effects as $anim_key => $animation_effect){
|
@@ -2260,119 +2183,119 @@ $stats_labels = $params['stats_labels'];
|
|
2260 |
</select>
|
2261 |
</span>
|
2262 |
<span class="wd-group fm-popover <?php echo $row->type != 'popover' ? 'fm-hide' : 'fm-show'; ?>">
|
2263 |
-
<label class="wd-label"><?php _e('Loading Delay',
|
2264 |
<input type="number" name="popover_loading_delay" value="<?php echo $row->popover_loading_delay; ?>" /> seconds
|
2265 |
<div>
|
2266 |
-
<?php _e('Define the amount of time before the form popup appears after the page loads.',
|
2267 |
-
<?php _e('Set 0 for no delay.',
|
2268 |
</div>
|
2269 |
</span>
|
2270 |
<span class="wd-group fm-popover <?php echo $row->type == 'popover' ? 'fm-show' : 'fm-hide' ?>">
|
2271 |
-
<label class="wd-label"><?php _e('Frequency',
|
2272 |
<input type="number" name="popover_frequency" value="<?php echo $row->popover_frequency; ?>" /> days
|
2273 |
<div>
|
2274 |
-
<?php _e('Display the popup to the same visitor (who has closed the popup/submitted the form) after this period.',
|
2275 |
-
<?php _e('Set the value to 0 to always show.',
|
2276 |
</div>
|
2277 |
</span>
|
2278 |
<span class="wd-group fm-topbar <?php echo $row->type == 'topbar' ? 'fm-show' : 'fm-hide' ?>">
|
2279 |
-
<label class="wd-label"><?php _e('Position',
|
2280 |
<input type="radio" name="topbar_position" <?php echo $row->topbar_position == 1 ? 'checked="checked"' : '' ?> id="fm_do-topbarpos-1" class="wd-radio" value="1">
|
2281 |
-
<label class="wd-label-radio" for="fm_do-topbarpos-1"><?php _e('Top',
|
2282 |
<input type="radio" name="topbar_position" <?php echo $row->topbar_position == 0 ? 'checked="checked"' : '' ?> id="fm_do-topbarpos-0" class="wd-radio" value="0">
|
2283 |
-
<label class="wd-label-radio" for="fm_do-topbarpos-0"><?php _e('Bottom',
|
2284 |
</span>
|
2285 |
<span class="wd-group fm-topbar topbar_remain_top <?php echo $row->type != 'topbar' ? 'fm-hide' : ($row->topbar_position == 1 ? 'fm-show' : 'fm-hide') ?>">
|
2286 |
-
<label class="wd-label"><?php _e('Remain at top when scrolling',
|
2287 |
<input type="radio" name="topbar_remain_top" <?php echo $row->topbar_remain_top == 1 ? 'checked="checked"' : '' ?> id="fm_do-remaintop-1" class="wd-radio" value="1">
|
2288 |
-
<label class="wd-label-radio" for="fm_do-remaintop-1"><?php _e('Yes',
|
2289 |
<input type="radio" name="topbar_remain_top" <?php echo $row->topbar_remain_top == 0 ? 'checked="checked"' : '' ?> id="fm_do-remaintop-0" class="wd-radio" value="0">
|
2290 |
-
<label class="wd-label-radio" for="fm_do-remaintop-0"><?php _e('No',
|
2291 |
</span>
|
2292 |
<span class="wd-group fm-topbar <?php echo $row->type == 'topbar' ? 'fm-show' : 'fm-hide' ?>">
|
2293 |
-
<label class="wd-label"><?php _e('Allow Closing the bar',
|
2294 |
<input type="radio" name="topbar_closing" <?php echo $row->topbar_closing == 1 ? 'checked="checked"' : '' ?> id="fm_do-topbarclosing-1" class="wd-radio" value="1">
|
2295 |
-
<label class="wd-label-radio" for="fm_do-topbarclosing-1"><?php _e('Yes',
|
2296 |
<input type="radio" name="topbar_closing" <?php echo $row->topbar_closing == 0 ? 'checked="checked"' : '' ?> id="fm_do-topbarclosing-0" class="wd-radio" value="0">
|
2297 |
-
<label class="wd-label-radio" for="fm_do-topbarclosing-0"><?php _e('No',
|
2298 |
</span>
|
2299 |
<span class="wd-group fm-topbar topbar_hide_duration <?php echo $row->type != 'topbar' ? 'fm-hide' : 'fm-show' ?>">
|
2300 |
-
<label class="wd-label"><?php _e('Frequency',
|
2301 |
<input type="number" name="topbar_hide_duration" value="<?php echo $row->topbar_hide_duration; ?>"/>days
|
2302 |
<div>
|
2303 |
-
<?php _e('Display the topbar to the same visitor (who has closed the popup/submitted the form) after this period.',
|
2304 |
-
<?php _e('Set the value to 0 to always show.',
|
2305 |
</div>
|
2306 |
</span>
|
2307 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2308 |
-
<label class="wd-label"><?php _e('Position',
|
2309 |
<input type="radio" name="scrollbox_position" <?php echo $row->scrollbox_position == 0 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxposition-0" class="wd-radio" value="0">
|
2310 |
-
<label class="wd-label-radio" for="fm_do-scrollboxposition-0"><?php _e('Left',
|
2311 |
<input type="radio" name="scrollbox_position" <?php echo $row->scrollbox_position == 1 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxposition-1" class="wd-radio" value="1">
|
2312 |
-
<label class="wd-label-radio" for="fm_do-scrollboxposition-1"><?php _e('Right',
|
2313 |
</span>
|
2314 |
<span class="wd-group fm-scrollbox <?php echo $row->type != 'scrollbox' ? 'fm-hide' : 'fm-show'; ?>">
|
2315 |
-
<label class="wd-label"><?php _e('Loading Delay',
|
2316 |
<input type="number" name="scrollbox_loading_delay" value="<?php echo $row->scrollbox_loading_delay; ?>" /> seconds
|
2317 |
<div>
|
2318 |
-
<?php _e('Define the amount of time before the form scrollbox appears after the page loads. Set 0 for no delay.',
|
2319 |
</div>
|
2320 |
</span>
|
2321 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2322 |
-
<label class="wd-label"><?php _e('Frequency',
|
2323 |
<input type="number" name="scrollbox_hide_duration" value="<?php echo $row->scrollbox_hide_duration; ?>"/>days
|
2324 |
<div>
|
2325 |
-
<?php _e('Display the scrollbox to the same visitor (who has closed the popup/submitted the form) after this period.',
|
2326 |
-
<?php _e('Set the value to 0 to always show.',
|
2327 |
</div>
|
2328 |
</span>
|
2329 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox <?php echo $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2330 |
-
<label class="wd-label"><?php _e('Always show for administrator',
|
2331 |
<input type="radio" name="show_for_admin" <?php echo $row->show_for_admin == 1 ? 'checked="checked"' : '' ?> id="fm_do-showforadmin-1" class="wd-radio" value="1">
|
2332 |
-
<label class="wd-label-radio" for="fm_do-showforadmin-1"><?php _e('Yes',
|
2333 |
<input type="radio" name="show_for_admin" <?php echo $row->show_for_admin == 0 ? 'checked="checked"' : '' ?> id="fm_do-showforadmin-0" class="wd-radio" value="0">
|
2334 |
-
<label class="wd-label-radio" for="fm_do-showforadmin-0"><?php _e('No',
|
2335 |
<div>
|
2336 |
-
<?php _e('If this option is enabled, website admins will always see the form.',
|
2337 |
</div>
|
2338 |
</span>
|
2339 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2340 |
-
<label class="wd-label"><?php _e('Trigger Point',
|
2341 |
<input type="number" name="scrollbox_trigger_point" value="<?php echo $row->scrollbox_trigger_point; ?>"/>%
|
2342 |
<div>
|
2343 |
-
<?php _e('Set the percentage of the page height, where the scrollbox form will appear after scrolling down.',
|
2344 |
</div>
|
2345 |
</span>
|
2346 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2347 |
-
<label class="wd-label"><?php _e('Allow Closing the bar',
|
2348 |
<input type="radio" name="scrollbox_closing" <?php echo $row->scrollbox_closing == 1 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxclosing-1" class="wd-radio" value="1">
|
2349 |
-
<label class="wd-label-radio" for="fm_do-scrollboxclosing-1"><?php _e('Yes',
|
2350 |
<input type="radio" name="scrollbox_closing" <?php echo $row->scrollbox_closing == 0 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxclosing-0" class="wd-radio" value="0">
|
2351 |
-
<label class="wd-label-radio" for="fm_do-scrollboxclosing-0"><?php _e('No',
|
2352 |
</span>
|
2353 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2354 |
-
<label class="wd-label"><?php _e('Allow Minimize',
|
2355 |
<input type="radio" name="scrollbox_minimize" <?php echo $row->scrollbox_minimize == 1 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxminimize-1" class="wd-radio" value="1">
|
2356 |
-
<label class="wd-label-radio" for="fm_do-scrollboxminimize-1"><?php _e('Yes',
|
2357 |
<input type="radio" name="scrollbox_minimize" <?php echo $row->scrollbox_minimize == 0 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxminimize-0" class="wd-radio" value="0">
|
2358 |
-
<label class="wd-label-radio" for="fm_do-scrollboxminimize-0"><?php _e('No',
|
2359 |
</span>
|
2360 |
<span class="wd-group fm-scrollbox minimize_text <?php echo $row->type == 'scrollbox' && $row->scrollbox_minimize == 1 ? 'fm-show' : 'fm-hide' ?>">
|
2361 |
-
<label class="wd-label"><?php _e('Minimize Text',
|
2362 |
<input type="text" name="scrollbox_minimize_text" value="<?php echo $row->scrollbox_minimize_text; ?>"/>
|
2363 |
</span>
|
2364 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2365 |
-
<label class="wd-label"><?php _e('Auto Hide',
|
2366 |
<input type="radio" name="scrollbox_auto_hide" <?php echo $row->scrollbox_auto_hide == 1 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxautohide-1" class="wd-radio" value="1">
|
2367 |
-
<label class="wd-label-radio" for="fm_do-scrollboxautohide-1"><?php _e('Yes',
|
2368 |
<input type="radio" name="scrollbox_auto_hide" <?php echo $row->scrollbox_auto_hide == 0 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxautohide-0" class="wd-radio" value="0">
|
2369 |
-
<label class="wd-label-radio" for="fm_do-scrollboxautohide-0"><?php _e('No',
|
2370 |
<div>
|
2371 |
-
<?php _e('Hide the scrollbox form again when visitor scrolls back up.',
|
2372 |
</div>
|
2373 |
</span>
|
2374 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox <?php echo $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2375 |
-
<label class="wd-label"><?php _e('Display on',
|
2376 |
<ul class="pp_display pp_display_on"><?php
|
2377 |
$posts_and_pages = $params['posts_and_pages'];
|
2378 |
$stat_types = array('everything' => 'All', 'home' => 'Homepage', 'archive' => 'Archives');
|
@@ -2398,7 +2321,7 @@ $stats_labels = $params['stats_labels'];
|
|
2398 |
</ul>
|
2399 |
</span>
|
2400 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox fm-cat-show <?php echo $row->type != 'embedded' && $show_cats ? 'fm-show' : 'fm-hide' ?>">
|
2401 |
-
<label class="wd-label"><?php _e("Display on these categories' posts",
|
2402 |
<ul class="pp_display pp_display_on_categories"><?php
|
2403 |
$categories = $params['categories'];
|
2404 |
$selected_categories = $params['selected_categories'];
|
@@ -2418,12 +2341,12 @@ $stats_labels = $params['stats_labels'];
|
|
2418 |
<input type="hidden" name="current_categories" value="<?php echo $current_categories; ?>"/>
|
2419 |
</span>
|
2420 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox fm-posts-show <?php echo (in_array('everything', $selected_types) || in_array('post', $selected_types)) && $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2421 |
-
<label class="wd-label"><?php _e('Display on these posts',
|
2422 |
<div class="fm-mini-heading">
|
2423 |
-
<?php _e('Click on input area to view the list of posts.',
|
2424 |
-
<?php _e('If left empty the form will appear on all posts.',
|
2425 |
</div>
|
2426 |
-
<p><?php _e('Posts defined below will override all settings above.',
|
2427 |
<ul class="fm-pp">
|
2428 |
<li class="pp_selected"><?php if($row->posts_include){
|
2429 |
$posts_include = explode(',', $row->posts_include);
|
@@ -2448,12 +2371,12 @@ $stats_labels = $params['stats_labels'];
|
|
2448 |
</ul>
|
2449 |
</span>
|
2450 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox fm-pages-show <?php echo (in_array('everything', $selected_types) || in_array('page', $selected_types)) && $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2451 |
-
<label class="wd-label"><?php _e('Display on these pages',
|
2452 |
<div class="fm-mini-heading">
|
2453 |
-
<?php _e('Click on input area to view the list of pages. ',
|
2454 |
-
<?php _e('If left empty the form will appear on all pages.',
|
2455 |
</div>
|
2456 |
-
<p><?php _e('Pages defined below will override all settings above.',
|
2457 |
<ul class="fm-pp">
|
2458 |
<li class="pp_selected"><?php if($row->pages_include){
|
2459 |
$pages_include = explode(',', $row->pages_include);
|
@@ -2477,11 +2400,11 @@ $stats_labels = $params['stats_labels'];
|
|
2477 |
</ul>
|
2478 |
</span>
|
2479 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox <?php echo $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2480 |
-
<label class="wd-label"><?php _e('Hide on Mobile',
|
2481 |
<input type="radio" name="hide_mobile" <?php echo $row->hide_mobile == 1 ? 'checked="checked"' : '' ?> id="fm_do-hidemobile-1" class="wd-radio" value="1">
|
2482 |
-
<label class="wd-label-radio" for="fm_do-hidemobile-1"><?php _e('Yes',
|
2483 |
<input type="radio" name="hide_mobile" <?php echo $row->hide_mobile == 0 ? 'checked="checked"' : '' ?> id="fm_do-hidemobile-0" class="wd-radio" value="0">
|
2484 |
-
<label class="wd-label-radio" for="fm_do-hidemobile-0"><?php _e('No',
|
2485 |
</span>
|
2486 |
</div>
|
2487 |
</div>
|
5 |
* FMViewManage_fmc constructor.
|
6 |
*/
|
7 |
public function __construct() {
|
8 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-tables');
|
9 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-first');
|
10 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
11 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-layout');
|
12 |
|
13 |
wp_enqueue_script('jquery');
|
14 |
wp_enqueue_script('jquery-ui-sortable');
|
15 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-admin');
|
16 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-manage');
|
17 |
/*$inline_styles = '#fm_admin_container .wdform_page .wdform_section .wdform_column.ui-sortable:empty:last-child:after {
|
18 |
+
content: "' . __('Drop a field here to create a column.', WDFMInstance(self::PLUGIN)->prefix) . '";
|
19 |
}';
|
20 |
+
wp_add_inline_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style', $inline_styles);*/
|
21 |
}
|
22 |
|
23 |
/**
|
31 |
$form_attr = array(
|
32 |
'id' => 'manage_form',
|
33 |
'class' =>'wd-form',
|
34 |
+
'action' => add_query_arg(array('page' => 'manage' . WDFMInstance(self::PLUGIN)->menu_postfix), 'admin.php'),
|
35 |
);
|
36 |
echo $this->form(ob_get_clean(), $form_attr);
|
37 |
}
|
41 |
*
|
42 |
* @return string Body html.
|
43 |
*/
|
44 |
+
public function body( $params ) {
|
45 |
$page = $params['page'];
|
46 |
$actions = $params['actions'];
|
47 |
$form_preview_link = $params['form_preview_link'];
|
53 |
|
54 |
$page_url = add_query_arg(array(
|
55 |
'page' => $page,
|
56 |
+
WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce),
|
57 |
), admin_url('admin.php'));
|
58 |
echo $this->title(array(
|
59 |
+
'title' => __('Forms', WDFMInstance(self::PLUGIN)->prefix),
|
60 |
'title_class' => 'wd-header',
|
61 |
'add_new_button' => array(
|
62 |
'href' => add_query_arg(array( 'page' => $page, 'task' => 'add' ), admin_url('admin.php')),
|
67 |
<div class="tablenav top">
|
68 |
<?php
|
69 |
echo $this->bulk_actions($actions);
|
70 |
+
if (WDFMInstance(self::PLUGIN)->is_free != 2) {
|
71 |
echo $this->exp_imp_buttons();
|
72 |
}
|
73 |
echo $this->pagination($page_url, $total, $items_per_page);
|
78 |
<thead>
|
79 |
<tr>
|
80 |
<td id="cb" class="manage-column column-cb check-column">
|
81 |
+
<label class="screen-reader-text" for="cb-select-all-1"><?php _e('Select all', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
82 |
<input id="check_all" type="checkbox" />
|
83 |
</td>
|
84 |
+
<?php echo WDW_FM_Library(self::PLUGIN)->ordering('title', $orderby, $order, __('Title', WDFMInstance(self::PLUGIN)->prefix), $page_url, 'col_title column-primary wd-left'); ?>
|
85 |
+
<?php echo WDW_FM_Library(self::PLUGIN)->ordering('type', $orderby, $order, __('Type', WDFMInstance(self::PLUGIN)->prefix), $page_url, 'col_type wd-left'); ?>
|
86 |
+
<th class="col_count wd-left"><?php _e('Submissions', WDFMInstance(self::PLUGIN)->prefix); ?></th>
|
87 |
+
<?php echo WDW_FM_Library(self::PLUGIN)->ordering('id', $orderby, $order, __('Shortcode', WDFMInstance(self::PLUGIN)->prefix), $page_url, 'wd-center'); ?>
|
88 |
+
<th class="col_function wd-center"><?php _e('PHP function', WDFMInstance(self::PLUGIN)->prefix); ?></th>
|
89 |
</tr>
|
90 |
</thead>
|
91 |
<tbody>
|
105 |
<th class="check-column">
|
106 |
<input id="check_<?php echo $row_data->id; ?>" name="check[<?php echo $row_data->id; ?>]" type="checkbox" class="form_title" data-id="<?php echo $row_data->id; ?>" />
|
107 |
</th>
|
108 |
+
<td class="column-primary" data-colname="<?php _e('Title', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
109 |
<strong>
|
110 |
<?php
|
111 |
if ( !$old ) {
|
123 |
if ( !$row_data->published ) {
|
124 |
?>
|
125 |
—
|
126 |
+
<span class="post-state"><?php _e('Unpublished', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
127 |
<?php
|
128 |
}
|
129 |
?>
|
133 |
if ( !$old ) {
|
134 |
?>
|
135 |
<span>
|
136 |
+
<a href="<?php echo $edit_url; ?>"><?php _e('Edit', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
137 |
|
|
138 |
</span>
|
139 |
<?php
|
140 |
}
|
141 |
?>
|
142 |
<span>
|
143 |
+
<a href="<?php echo $duplicate_url; ?>"><?php _e('Duplicate', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
144 |
|
|
145 |
</span>
|
146 |
<span>
|
147 |
+
<a href="<?php echo $publish_url; ?>"><?php echo ($row_data->published ? __('Unpublish', WDFMInstance(self::PLUGIN)->prefix) : __('Publish', WDFMInstance(self::PLUGIN)->prefix)); ?></a>
|
148 |
|
|
149 |
</span>
|
150 |
<span class="trash">
|
151 |
+
<a onclick="if (!confirm('<?php echo addslashes(__('Do you want to delete selected item?', WDFMInstance(self::PLUGIN)->prefix)); ?>')) {return false;}" href="<?php echo $delete_url; ?>"><?php _e('Delete', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
152 |
|
|
153 |
</span>
|
154 |
<span>
|
155 |
+
<a href="<?php echo $preview_url; ?>" target="_blank"><?php _e('Preview', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
156 |
</span>
|
157 |
</div>
|
158 |
<button class="toggle-row" type="button">
|
159 |
+
<span class="screen-reader-text"><?php _e('Show more details', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
160 |
</button>
|
161 |
</td>
|
162 |
+
<td data-colname="<?php _e('Type', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
163 |
<?php echo ucfirst($row_data->type); ?>
|
164 |
<div class="row-actions">
|
165 |
<span>
|
166 |
+
<a href="<?php echo add_query_arg(array('task' => 'display_options', 'current_id' => $row_data->id), $page_url); ?>"><?php _e('Set display options', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
167 |
</span>
|
168 |
</div>
|
169 |
</td>
|
170 |
+
<td data-colname="<?php _e('Submissions', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
171 |
<?php
|
172 |
if ($row_data->submission_count != 0) {
|
173 |
?>
|
174 |
+
<a title="<?php _e('View sumbissions', WDFMInstance(self::PLUGIN)->prefix); ?>" target="_blank" href="<?php echo add_query_arg(array(
|
175 |
+
'page' => 'submissions' . WDFMInstance(self::PLUGIN)->menu_postfix,
|
176 |
'task' => 'display',
|
177 |
'current_id' => $row_data->id,
|
178 |
), admin_url('admin.php')); ?>">
|
186 |
}
|
187 |
?>
|
188 |
</td>
|
189 |
+
<td data-colname="<?php _e('Shortcode', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
190 |
+
<input type="text" value='<?php echo (WDFMInstance(self::PLUGIN)->is_free == 2 ? '[wd_contact_form id="' . $row_data->id . '"]' : '[Form id="' . $row_data->id . '"]'); ?>' onclick="fm_select_value(this)" size="12" readonly="readonly" />
|
191 |
</td>
|
192 |
+
<td data-colname="<?php _e('PHP function', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
193 |
+
<input type="text" value='<?php echo (WDFMInstance(self::PLUGIN)->is_free == 2 ? '<?php wd_contact_form_maker(' . $row_data->id . ', "' . $row_data->type . '"); ?>' : '<?php wd_form_maker(' . $row_data->id . ', "' . $row_data->type . '"); ?>'); ?>' onclick="fm_select_value(this)" readonly="readonly" />
|
194 |
</td>
|
195 |
</tr>
|
196 |
<?php
|
197 |
}
|
198 |
}
|
199 |
else {
|
200 |
+
echo WDW_FM_Library(self::PLUGIN)->no_items('forms');
|
201 |
}
|
202 |
?>
|
203 |
</tbody>
|
217 |
}
|
218 |
|
219 |
public function edit($params) {
|
220 |
+
// TODO: Change this function to standard.
|
221 |
+
echo $this->topbar();
|
222 |
+
|
223 |
wp_enqueue_style('thickbox');
|
224 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-phone_field_css');
|
225 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-jquery-ui');
|
226 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-codemirror');
|
227 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-colorpicker');
|
228 |
|
229 |
wp_enqueue_script('thickbox');
|
230 |
wp_enqueue_script('jquery-ui-widget');
|
232 |
wp_enqueue_script('jquery-ui-spinner');
|
233 |
wp_enqueue_script('jquery-ui-datepicker');
|
234 |
if ( function_exists('wp_add_inline_script') ) { // Since Wordpress 4.5.0
|
235 |
+
wp_add_inline_script('jquery-ui-datepicker', WDW_FM_Library(self::PLUGIN)->localize_ui_datepicker());
|
236 |
}
|
237 |
else {
|
238 |
+
echo '<script>' . WDW_FM_Library(self::PLUGIN)->localize_ui_datepicker() . '</script>';
|
239 |
}
|
240 |
wp_enqueue_media();
|
241 |
wp_enqueue_script('google-maps');
|
242 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-gmap_form');
|
243 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-phone_field');
|
244 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-formmaker_div');
|
245 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-codemirror');
|
246 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-formatting');
|
247 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-clike');
|
248 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-css');
|
249 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-javascript');
|
250 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-xml');
|
251 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-php');
|
252 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-htmlmixed');
|
253 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-colorpicker');
|
254 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-manage-edit');
|
255 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-add-fields');
|
256 |
|
257 |
$id = $params['id'];
|
258 |
$row = $params['row'];
|
291 |
form_fields_initial = decodeURIComponent(form_fields_initial);
|
292 |
|
293 |
default_theme = '<?php echo $default_theme; ?>';
|
294 |
+
theme_edit_url = '<?php echo add_query_arg( array('page' => 'themes' . WDFMInstance(self::PLUGIN)->menu_postfix, 'task' =>'edit'), $page_url); ?>';
|
295 |
jQuery(document).ready(function () {
|
296 |
set_theme();
|
297 |
});
|
298 |
</script>
|
299 |
+
<form class="wrap" id="manage_form" method="post" autocomplete="off" action="admin.php?page=manage<?php echo WDFMInstance(self::PLUGIN)->menu_postfix; ?>">
|
300 |
<?php
|
301 |
// Generate message container by message id or directly by message.
|
302 |
+
$message_id = WDW_FM_Library(self::PLUGIN)->get('message', 0);
|
303 |
+
$message = WDW_FM_Library(self::PLUGIN)->get('msg', '');
|
304 |
+
echo WDW_FM_Library(self::PLUGIN)->message_id($message_id, $message);
|
305 |
?>
|
306 |
+
<?php wp_nonce_field(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce); ?>
|
307 |
<h2 class="fm-h2-message"></h2>
|
308 |
<div class="fm-page-header">
|
309 |
<div class="wd-page-title wd-header">
|
310 |
+
<h1 class="wp-heading-inline"><?php _e('Form Title', WDFMInstance(self::PLUGIN)->prefix); ?></h1>
|
311 |
<input id="title" name="title" value="<?php echo $row->title; ?>" data-initial-value="<?php echo $row->title; ?>" class="fm-check-change" type="text" />
|
312 |
<div class="fm-page-actions">
|
313 |
<?php
|
315 |
if ( $row->backup_id != "" ) {
|
316 |
$backup_id = $next_backup_id;
|
317 |
if ( $backup_id ) { ?>
|
318 |
+
<button class="button redo-button button-large" onclick="if (fm_check_required('title', '<?php _e('Form Title', WDFMInstance(self::PLUGIN)->prefix); ?>') || !FormManageSubmitButton()) {return false;}; jQuery('#saving_text').html('<?php _e('Redo', WDFMInstance(self::PLUGIN)->prefix); ?>');fm_set_input_value('task', 'redo');">
|
319 |
+
<?php _e('Redo', WDFMInstance(self::PLUGIN)->prefix); ?>
|
320 |
</button>
|
321 |
<?php
|
322 |
}
|
323 |
$backup_id = $prev_backup_id;
|
324 |
if ( $backup_id ) { ?>
|
325 |
+
<button class="button undo-button button-large" onclick="if (fm_check_required('title', '<?php _e('Form Title', WDFMInstance(self::PLUGIN)->prefix); ?>') || !FormManageSubmitButton()) {return false;}; jQuery('#saving_text').html('<?php _e('Undo', WDFMInstance(self::PLUGIN)->prefix); ?>');fm_set_input_value('task', 'undo');">
|
326 |
<span></span>
|
327 |
+
<?php _e('Undo', WDFMInstance(self::PLUGIN)->prefix); ?>
|
328 |
</button>
|
329 |
<?php
|
330 |
}
|
331 |
}
|
332 |
}
|
333 |
?>
|
334 |
+
<button class="button button-primary button-large" onclick="if (fm_check_required('title', '<?php _e('Form Title', WDFMInstance(self::PLUGIN)->prefix); ?>') || !FormManageSubmitButton()) {return false;}; fm_set_input_value('task', 'apply');">
|
335 |
<?php
|
336 |
if ($row->title) {
|
337 |
+
_e('Update', WDFMInstance(self::PLUGIN)->prefix);
|
338 |
}
|
339 |
else {
|
340 |
+
_e('Publish', WDFMInstance(self::PLUGIN)->prefix);
|
341 |
}
|
342 |
?>
|
343 |
</button>
|
344 |
+
<button class="button preview-button button-large"<?php if (!$row->title) echo ' disabled="disabled"' ?> <?php echo ($row->title) ? 'onclick="window.open(\''. add_query_arg( array('wdform_id' => $id), $form_preview_link ) .'\', \'_blank\'); return false;"' : ''; ?>><?php _e('Preview', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
345 |
</div>
|
346 |
</div>
|
347 |
<div class="fm-clear"></div>
|
348 |
</div>
|
349 |
<div class="fm-theme-banner">
|
350 |
<div class="fm-theme" style="float:left; position: relative">
|
351 |
+
<span><?php _e('Theme', WDFMInstance(self::PLUGIN)->prefix); ?>: </span>
|
352 |
<select id="theme" name="theme" data-initial-value="<?php echo $row->theme; ?>" class="fm-check-change" onChange="set_theme()">
|
353 |
<optgroup label="New Themes">
|
354 |
<?php
|
368 |
?>
|
369 |
</optgroup>
|
370 |
</select>
|
371 |
+
<a id="edit_css" class="pointer" onclick="window.open('<?php echo add_query_arg(array('current_id' => ($row->theme ? $row->theme : $default_theme), WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce)), admin_url('admin.php?page=themes' . WDFMInstance(self::PLUGIN)->menu_postfix . '&task=edit')); ?>'); return false;">
|
372 |
+
<?php _e('Edit', WDFMInstance(self::PLUGIN)->prefix); ?>
|
373 |
</a>
|
374 |
<br />
|
375 |
+
<div id="old_theme_notice" style="display: none;"><div class="error inline"><p><?php _e('The theme you have selected is outdated. Please choose one from New Themes section.', WDFMInstance(self::PLUGIN)->prefix); ?></p></div></div>
|
376 |
</div>
|
377 |
<div class="fm-page-actions">
|
378 |
<?php if( $id ){ ?>
|
379 |
+
<a class="button button-primary" href="<?php echo $params['form_options_url']; ?>"><?php _e('Form Options', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
380 |
+
<a class="button" href="<?php echo $params['display_options_url']; ?>"><?php _e('Display Options', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
381 |
<?php
|
382 |
if ( !empty($params['advanced_layout_url']) ) {
|
383 |
?>
|
384 |
+
<a class="button" href="<?php echo $params['advanced_layout_url']; ?>"><?php _e('Advanced Layout', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
385 |
<?php
|
386 |
}
|
387 |
}
|
389 |
</div>
|
390 |
</div>
|
391 |
<div class="fm-clear"></div>
|
392 |
+
<?php echo $this->add_fields($params); ?>
|
393 |
+
<?php echo $this->limitation_alert(); ?>
|
394 |
<?php if (!function_exists('the_editor')) { ?>
|
395 |
<iframe id="tinymce" style="display: none;"></iframe>
|
396 |
<?php } ?>
|
397 |
<div class="meta-box-sortables" style="margin-top:30px;">
|
398 |
<div id="postexcerpt" class="postbox closed" >
|
399 |
<button type="button" class="button-link handlediv" aria-expanded="true">
|
400 |
+
<span class="screen-reader-text"><?php _e('Toggle panel: Form Header', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
401 |
<span class="toggle-indicator" aria-hidden="true"></span>
|
402 |
</button>
|
403 |
+
<h2 class="hndle"><span><?php _e('Form Header', WDFMInstance(self::PLUGIN)->prefix); ?></span></h2>
|
404 |
<div class="inside">
|
405 |
<div id="fm-header-content" class="panel-content">
|
406 |
<div>
|
407 |
<div class="fm-row">
|
408 |
+
<label><?php _e('Title:', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
409 |
<input type="text" id="header_title" name="header_title" class="fm-check-change" value="<?php echo $row->header_title; ?>" data-initial-value="<?php echo $row->header_title; ?>" />
|
410 |
</div>
|
411 |
<div class="fm-row">
|
412 |
+
<label><?php _e('Description:', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
413 |
<div id="description_editor" style="display: inline-block; vertical-align: middle;">
|
414 |
<input type="hidden" id="header_description_initial_value" value="<?php echo rawurlencode($row->header_description); ?>" />
|
415 |
<?php if (user_can_richedit()) {
|
425 |
</div>
|
426 |
<div>
|
427 |
<div class="fm-row">
|
428 |
+
<label><?php _e('Image:', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
429 |
<input type="text" id="header_image_url" name="header_image_url" class="fm-check-change" value="<?php echo $row->header_image_url; ?>" data-initial-value="<?php echo $row->header_image_url; ?>" />
|
430 |
+
<button class="button add-button medium" onclick="fmOpenMediaUploader(event); return false;"><?php _e('Add Image', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
431 |
<?php $header_bg = $row->header_image_url ? 'background-image: url('.$row->header_image_url.'); background-position: center;' : ''; ?>
|
432 |
<div id="header_image" class="header_img<?php if (!$row->header_image_url) echo ' fm-hide'; ?>" style="<?php echo $header_bg; ?>">
|
433 |
<button type="button" id="remove_header_img" onclick="fmRemoveHeaderImage(event); return false;">
|
436 |
</div>
|
437 |
</div>
|
438 |
<div class="fm-row">
|
439 |
+
<label><?php _e('Image Animation:', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
440 |
<select name="header_image_animation" class="fm-check-change" data-initial-value="<?php echo $row->header_image_animation; ?>">
|
441 |
<?php
|
442 |
foreach($animation_effects as $anim_key => $animation_effect){
|
447 |
</select>
|
448 |
</div>
|
449 |
<div class="fm-row">
|
450 |
+
<label for="header_hide_image"><?php _e('Hide Image on Mobile:', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
451 |
<input type="checkbox" id="header_hide_image" name="header_hide_image" value="1" data-initial-value="<?php echo $row->header_hide_image; ?>" <?php echo $row->header_hide_image == '1' ? 'checked="checked"' : '' ?> />
|
452 |
</div>
|
453 |
</div>
|
458 |
<div class="fm-edit-content">
|
459 |
<div class="fm-drag-and-drop">
|
460 |
<div>
|
461 |
+
<label for="enable_sortable"><?php _e('Enable Drag & Drop', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
462 |
<button name="sortable" id="enable_sortable" class="fm-checkbox-radio-button <?php echo $row->sortable == 1 ? 'fm-yes' : 'fm-no' ?>" onclick="enable_drag(this); return false;" value="<?php echo $row->sortable; ?>">
|
463 |
<span></span>
|
464 |
</button>
|
478 |
<div id="add_field" class="ui-sortable-handle">
|
479 |
<div class="first-time-use">
|
480 |
<span class="first-time-use-close dashicons dashicons-no-alt"></span>
|
481 |
+
<?php _e('Drag icon to the form to add a field.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
482 |
</div>
|
483 |
|
484 |
<div type="type_text" class="wdform_field">
|
485 |
<div class="add-new-button button-primary" onclick="popup_ready(); Enable(); return false;">
|
486 |
<span class="dashicons dashicons-move"></span>
|
487 |
+
<?php _e('New Field', WDFMInstance(self::PLUGIN)->prefix); ?>
|
488 |
</div>
|
489 |
</div>
|
490 |
</div>
|
512 |
<?php
|
513 |
}
|
514 |
|
515 |
+
public function add_fields($params) {
|
516 |
+
$pro_fields1 = array('file_upload', 'map', 'paypal');
|
517 |
+
$pro_fields2 = array('file_upload', 'paypal', 'checkbox', 'radio', 'survey', 'time_and_date', 'select');
|
518 |
$fields = array(
|
519 |
+
__('BASIC FIELDS', WDFMInstance(self::PLUGIN)->prefix) => array(
|
520 |
+
array('type' => 'text', 'subtype' => 'text', 'title' => __('Single Line Text', WDFMInstance(self::PLUGIN)->prefix)),
|
521 |
+
array('type' => 'text', 'subtype' => 'textarea', 'title' => __('Paragraph Text', WDFMInstance(self::PLUGIN)->prefix)),
|
522 |
+
array('type' => 'survey', 'subtype' => 'spinner', 'title' => __('Number', WDFMInstance(self::PLUGIN)->prefix)),
|
523 |
+
array('type' => 'time_and_date', 'subtype' => 'date_new', 'title' => __('Date', WDFMInstance(self::PLUGIN)->prefix)),
|
524 |
+
array('type' => 'select', 'subtype' => 'own_select', 'title' => __('Select', WDFMInstance(self::PLUGIN)->prefix)),
|
525 |
+
array('type' => 'radio', 'subtype' => '', 'title' => __('Single Choice', WDFMInstance(self::PLUGIN)->prefix)),
|
526 |
+
array('type' => 'checkbox', 'subtype' => '', 'title' => __('Multiple Choice', WDFMInstance(self::PLUGIN)->prefix)),
|
527 |
+
array('type' => 'captcha', 'subtype' => 'recaptcha', 'title' => __('Recaptcha', WDFMInstance(self::PLUGIN)->prefix)),
|
528 |
+
array('type' => 'button', 'subtype' => 'submit_reset', 'title' => __('Submit', WDFMInstance(self::PLUGIN)->prefix)),
|
529 |
+
array('type' => 'captcha', 'subtype' => 'captcha', 'title' => __('Simple Captcha', WDFMInstance(self::PLUGIN)->prefix)),
|
530 |
+
),
|
531 |
+
__('USER INFO FIELDS', WDFMInstance(self::PLUGIN)->prefix) => array(
|
532 |
+
array('type' => 'text', 'subtype' => 'name', 'title' => __('Name', WDFMInstance(self::PLUGIN)->prefix)),
|
533 |
+
array('type' => 'text', 'subtype' => 'submitter_mail', 'title' => __('Email', WDFMInstance(self::PLUGIN)->prefix)),
|
534 |
+
array('type' => 'text', 'subtype' => 'phone_new', 'title' => __('Phone', WDFMInstance(self::PLUGIN)->prefix)),
|
535 |
+
array('type' => 'text', 'subtype' => 'address', 'title' => __('Address', WDFMInstance(self::PLUGIN)->prefix)),
|
536 |
+
array('type' => 'text', 'subtype' => 'mark_map', 'title' => __('Mark on Map', WDFMInstance(self::PLUGIN)->prefix)),
|
537 |
+
array('type' => 'select', 'subtype' => 'country', 'title' => __('Country List', WDFMInstance(self::PLUGIN)->prefix)),
|
538 |
+
array('type' => 'time_and_date', 'subtype' => 'date_fields', 'title' => __('Date of Birth', WDFMInstance(self::PLUGIN)->prefix)),
|
539 |
),
|
540 |
+
__('LAYOUT FIELDS', WDFMInstance(self::PLUGIN)->prefix) => array(
|
541 |
+
array('type' => 'editor', 'subtype' => '', 'title' => __('HTML', WDFMInstance(self::PLUGIN)->prefix)),
|
542 |
+
array('type' => 'section_break', 'subtype' => '', 'title' => __('Section', WDFMInstance(self::PLUGIN)->prefix)),
|
543 |
+
array('type' => 'page_break', 'subtype' => '', 'title' => __('Page', WDFMInstance(self::PLUGIN)->prefix)),
|
544 |
),
|
545 |
+
__('ADVANCED', WDFMInstance(self::PLUGIN)->prefix) => array(
|
546 |
+
array('type' => 'file_upload', 'subtype' => '', 'title' => __('File Upload', WDFMInstance(self::PLUGIN)->prefix)),
|
547 |
+
array('type' => 'map', 'subtype' => '', 'title' => __('Map', WDFMInstance(self::PLUGIN)->prefix)),
|
548 |
+
array('type' => 'time_and_date', 'subtype' => 'time', 'title' => __('Time', WDFMInstance(self::PLUGIN)->prefix)),
|
549 |
+
array('type' => 'text', 'subtype' => 'send_copy', 'title' => __('Receive Copy', WDFMInstance(self::PLUGIN)->prefix)),
|
550 |
+
array('type' => 'time_and_date', 'subtype' => 'date_range', 'title' => __('Date Range', WDFMInstance(self::PLUGIN)->prefix)),
|
551 |
+
array('type' => 'survey', 'subtype' => 'star_rating', 'title' => __('Stars', WDFMInstance(self::PLUGIN)->prefix)),
|
552 |
+
array('type' => 'survey', 'subtype' => 'scale_rating', 'title' => __('Rating', WDFMInstance(self::PLUGIN)->prefix)),
|
553 |
+
array('type' => 'survey', 'subtype' => 'slider', 'title' => __('Slider', WDFMInstance(self::PLUGIN)->prefix)),
|
554 |
+
array('type' => 'survey', 'subtype' => 'range', 'title' => __('Range', WDFMInstance(self::PLUGIN)->prefix)),
|
555 |
+
array('type' => 'survey', 'subtype' => 'grading', 'title' => __('Grades', WDFMInstance(self::PLUGIN)->prefix)),
|
556 |
+
array('type' => 'survey', 'subtype' => 'matrix', 'title' => __('Table of Fields', WDFMInstance(self::PLUGIN)->prefix)),
|
557 |
+
array('type' => 'text', 'subtype' => 'hidden', 'title' => __('Hidden Input', WDFMInstance(self::PLUGIN)->prefix)),
|
558 |
+
array('type' => 'button', 'subtype' => 'button', 'title' => __('Custom Button', WDFMInstance(self::PLUGIN)->prefix)),
|
559 |
+
array('type' => 'text', 'subtype' => 'password', 'title' => __('Password', WDFMInstance(self::PLUGIN)->prefix)),
|
560 |
+
array('type' => 'text', 'subtype' => 'phone', 'title' => __('Phone-Area Code', WDFMInstance(self::PLUGIN)->prefix)),
|
561 |
+
array('type' => 'captcha', 'subtype' => 'arithmetic_captcha', 'title' => __('Arithmetic Captcha', WDFMInstance(self::PLUGIN)->prefix)),
|
562 |
),
|
563 |
+
__('PAYMENT', WDFMInstance(self::PLUGIN)->prefix) => array(
|
564 |
+
array('type' => 'paypal', 'subtype' => 'paypal_price_new', 'title' => __('Price', WDFMInstance(self::PLUGIN)->prefix)),
|
565 |
+
array('type' => 'paypal', 'subtype' => 'paypal_select', 'title' => __('Payment Select', WDFMInstance(self::PLUGIN)->prefix)),
|
566 |
+
array('type' => 'paypal', 'subtype' => 'paypal_radio', 'title' => __('Payment Single Choice', WDFMInstance(self::PLUGIN)->prefix)),
|
567 |
+
array('type' => 'paypal', 'subtype' => 'paypal_checkbox', 'title' => __('Payment Multiple Choice', WDFMInstance(self::PLUGIN)->prefix)),
|
568 |
+
array('type' => 'paypal', 'subtype' => 'paypal_shipping', 'title' => __('Shipping', WDFMInstance(self::PLUGIN)->prefix)),
|
569 |
+
array('type' => 'paypal', 'subtype' => 'paypal_total', 'title' => __('Total', WDFMInstance(self::PLUGIN)->prefix)),
|
570 |
+
array('type' => 'paypal', 'subtype' => 'stripe', 'title' => __('Stripe', WDFMInstance(self::PLUGIN)->prefix)),
|
571 |
),
|
572 |
);
|
573 |
ob_start();
|
575 |
<div class="add-popup js">
|
576 |
<div class="popup-header">
|
577 |
<span class="popup-title">
|
578 |
+
<?php _e('Add field', WDFMInstance(self::PLUGIN)->prefix); ?>
|
579 |
</span>
|
580 |
+
<span title="<?php _e('Close', WDFMInstance(self::PLUGIN)->prefix); ?>" alt="<?php _e('Close', WDFMInstance(self::PLUGIN)->prefix); ?>" class="close-popup dashicons dashicons-no-alt" onclick="close_window()"></span>
|
581 |
</div>
|
582 |
<div class="popup-body meta-box-sortables">
|
583 |
<div class="popup-body-col field_types">
|
584 |
+
<div class="field_types_cont">
|
585 |
+
<h2 class="hndle field-types-filter_header"><span><?php _e('FIELD TYPES', WDFMInstance(self::PLUGIN)->prefix); ?></span></h2>
|
586 |
+
<span class="field-types-filter-cont">
|
587 |
+
<input class="field-types-filter" value="" placeholder="<?php _e('Filter', WDFMInstance(self::PLUGIN)->prefix); ?>" tabindex="-1" type="search" />
|
588 |
</span>
|
589 |
+
<div class="postbox filtered-fields hide">
|
590 |
<button class="button-link handlediv" type="button" aria-expanded="true">
|
591 |
<span class="screen-reader-text">Toggle panel</span>
|
592 |
<span class="toggle-indicator" aria-hidden="true"></span>
|
593 |
</button>
|
594 |
<h2 class="hndle">
|
595 |
+
<span><?php _e('Filtered fields', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
596 |
</h2>
|
597 |
<div class="inside"></div>
|
598 |
</div>
|
599 |
<?php
|
600 |
foreach ($fields as $section => $field) {
|
601 |
?>
|
602 |
+
<div class="postbox<?php echo $section != __('BASIC FIELDS', WDFMInstance(self::PLUGIN)->prefix) ? " closed" : ""; ?>">
|
603 |
<button class="button-link handlediv" type="button" aria-expanded="true">
|
604 |
+
<span class="screen-reader-text"><?php echo __('Toggle panel:', WDFMInstance(self::PLUGIN)->prefix) , $section; ?></span>
|
605 |
<span class="toggle-indicator" aria-hidden="false"></span>
|
606 |
</button>
|
607 |
<h2 class="hndle">
|
611 |
<?php
|
612 |
foreach ($field as $button) {
|
613 |
?>
|
614 |
+
<button class="<?php echo ((WDFMInstance(self::PLUGIN)->is_free == 1 && in_array($button['type'], $pro_fields1)) || (WDFMInstance(self::PLUGIN)->is_free == 2 && in_array($button['type'], $pro_fields2))) ? 'wd-pro-fields ' : ''; ?>wd-button button-secondary" onclick="addRow(event, this, '<?php echo $button['type']; ?>', '<?php echo $button['subtype']; ?>'); return false;" data-type="type_<?php echo $button['subtype'] ? $button['subtype'] : $button['type']; ?>">
|
615 |
<span class="field-type-button wd<?php echo ($button['subtype'] == '' ? $button['type'] : $button['subtype']); ?>"></span>
|
616 |
<?php echo $button['title']; ?>
|
617 |
</button>
|
625 |
?>
|
626 |
</div>
|
627 |
</div>
|
628 |
+
<div id="field_container">
|
629 |
+
<?php
|
630 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
631 |
+
echo $this->free_message(__('This field type is available in Premium version', WDFMInstance(self::PLUGIN)->prefix), '', '', 'premium_message');
|
632 |
+
}
|
633 |
+
$stripe_addon = $params['stripe_addon'];
|
634 |
+
if ( $stripe_addon['enable'] ) {
|
635 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
636 |
+
echo $this->free_message(__('STRIPE add-on compatible with Premium version only', WDFMInstance(self::PLUGIN)->prefix), '', '', 'stripe_message');
|
637 |
+
}
|
638 |
+
}
|
639 |
+
else {
|
640 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
641 |
+
echo $this->promo_box(__('This feature is available only in the Premium version', WDFMInstance(self::PLUGIN)->prefix), __('Requires STRIPE add-on.', WDFMInstance(self::PLUGIN)->prefix), 'https://web-dorado.com/products/wordpress-form/add-ons/stripe.html', 'stripe_message');
|
642 |
+
}
|
643 |
+
else {
|
644 |
+
echo $this->free_message(__('This feature requires STRIPE add-on', WDFMInstance(self::PLUGIN)->prefix), 'https://web-dorado.com/products/wordpress-form/add-ons/stripe.html', __( 'Buy', WDFMInstance(self::PLUGIN)->prefix ), 'stripe_message');
|
645 |
+
}
|
646 |
+
}
|
647 |
+
?>
|
648 |
+
<div class="popup-body-col field_options">
|
649 |
+
<div id="edit_table"></div>
|
650 |
+
</div>
|
651 |
+
<div class="popup-body-col field_preview">
|
652 |
<div id="add-button-cont" class="add-button-cont">
|
653 |
<button class="button button-primary button-hero wd-add-button" onclick="add(0, false); return false;">
|
654 |
+
<?php _e('Add', WDFMInstance(self::PLUGIN)->prefix);?>
|
655 |
</button>
|
656 |
</div>
|
657 |
<div id="show_table">
|
658 |
</div>
|
659 |
</div>
|
660 |
+
</div>
|
661 |
</div>
|
662 |
<input type="hidden" id="old" />
|
663 |
<input type="hidden" id="old_selected" />
|
664 |
<input type="hidden" id="element_type" />
|
665 |
<input type="hidden" id="editing_id" />
|
666 |
+
<input type="hidden" value="<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>" id="form_plugins_url" />
|
667 |
<div id="main_editor" style="position: fixed; display: none; z-index: 140;">
|
668 |
<?php if ( user_can_richedit() ) {
|
669 |
wp_editor('', 'form_maker_editor', array(
|
684 |
return ob_get_clean();
|
685 |
}
|
686 |
|
687 |
+
public function form_options( $params ) {
|
688 |
wp_enqueue_style('thickbox');
|
689 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-phone_field_css');
|
690 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-jquery-ui');
|
691 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-codemirror');
|
692 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-colorpicker');
|
693 |
|
694 |
wp_enqueue_script('thickbox');
|
695 |
wp_enqueue_script('jquery-ui-widget');
|
697 |
wp_enqueue_script('jquery-ui-spinner');
|
698 |
wp_enqueue_script('jquery-ui-datepicker');
|
699 |
if ( function_exists('wp_add_inline_script') ) { // Since Wordpress 4.5.0
|
700 |
+
wp_add_inline_script('jquery-ui-datepicker', WDW_FM_Library(self::PLUGIN)->localize_ui_datepicker());
|
701 |
}
|
702 |
else {
|
703 |
+
echo '<script>' . WDW_FM_Library(self::PLUGIN)->localize_ui_datepicker() . '</script>';
|
704 |
}
|
705 |
wp_enqueue_media();
|
706 |
wp_enqueue_script('google-maps');
|
707 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-form-options');
|
708 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-gmap_form');
|
709 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-phone_field');
|
710 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-formmaker_div');
|
711 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-codemirror');
|
712 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-formatting');
|
713 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-clike');
|
714 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-css');
|
715 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-javascript');
|
716 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-xml');
|
717 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-php');
|
718 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-htmlmixed');
|
719 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-colorpicker');
|
720 |
|
721 |
$id = $params['id'];
|
722 |
$page = $params['page'];
|
728 |
$form_attr = array(
|
729 |
'id' => 'adminForm',
|
730 |
'name' => 'adminForm',
|
731 |
+
'class' => WDFMInstance(self::PLUGIN)->css_prefix . 'form_options wd-form',
|
732 |
'current_id' => $id,
|
733 |
'action' => add_query_arg( array('page' => $page, 'current_id' => $id ), $page_url),
|
734 |
);
|
743 |
* @return string Body html.
|
744 |
*/
|
745 |
private function body_form_options( $params ) {
|
746 |
+
$id = $params['id'];
|
747 |
+
$page = $params['page'];
|
748 |
+
$page_title = $params['page_title'];
|
749 |
+
$page_url = $params['page_url'];
|
750 |
+
$back_url = $params['back_url'];
|
751 |
+
$fieldset_id = $params['fieldset_id'];
|
752 |
+
$addons = $params['addons'];
|
753 |
+
$row = $params['row'];
|
754 |
+
$themes = $params['themes'];
|
755 |
+
$default_theme = $params['default_theme'];
|
756 |
+
$queries = $params['queries'];
|
757 |
+
$userGroups = $params['userGroups'];
|
758 |
+
$fields = $params['fields'];
|
759 |
+
$fields_count = $params['fields_count'];
|
760 |
+
$stripe_addon = $params['stripe_addon'];
|
761 |
+
$payment_method = $params['payment_method'];
|
762 |
+
$label_label = $params['label_label'];
|
763 |
+
$label_type = $params['label_type'];
|
764 |
+
echo $this->title(array(
|
765 |
+
'title' => $page_title,
|
766 |
+
'title_class' => 'wd-header',
|
767 |
+
'add_new_button' => FALSE,
|
768 |
+
));
|
769 |
+
$buttons = array(
|
770 |
+
'save' => array(
|
771 |
+
'title' => __('Update', WDFMInstance(self::PLUGIN)->prefix),
|
772 |
+
'value' => 'save',
|
773 |
+
'onclick' => 'if( ! wd_fm_apply_options(\'apply_form_options\') ){ return false; }',
|
774 |
+
'class' => 'button-primary',
|
775 |
+
),
|
776 |
+
'back' => array(
|
777 |
+
'title' => __('Back to Form', WDFMInstance(self::PLUGIN)->prefix),
|
778 |
+
'value' => 'back',
|
779 |
+
'onclick' => 'window.open(\'' . $back_url . '\', \'_self\'); return false;',
|
780 |
+
'class' => 'button',
|
781 |
+
)
|
782 |
+
);
|
783 |
+
echo $this->buttons($buttons);
|
784 |
+
$label_titles_for_submissions = array();
|
785 |
+
$labels_id_for_submissions = array();
|
786 |
+
$payment_info = $params['payment_info'];
|
787 |
+
$labels_for_submissions = $params['labels_for_submissions'];
|
788 |
+
if ( $labels_for_submissions ) {
|
789 |
+
$labels_id_for_submissions = $params['labels_id_for_submissions'];
|
790 |
+
$label_titles_for_submissions = $params['label_titles_for_submissions'];
|
791 |
+
}
|
792 |
+
$stats_labels_ids = $params['stats_labels_ids'];
|
793 |
+
$stats_labels = $params['stats_labels'];
|
794 |
+
?>
|
795 |
<div class="fm-clear"></div>
|
796 |
+
<?php echo $this->placeholders_popup($params[ 'label_label' ]); ?>
|
797 |
<div class="submenu-box">
|
798 |
<div class="submenu-pad">
|
799 |
<ul id="submenu" class="configuration">
|
800 |
<li>
|
801 |
+
<a id="general" class="fm_fieldset_tab" onclick="form_maker_options_tabs('general')" href="#"><?php _e('General Options', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
802 |
</li>
|
803 |
<li>
|
804 |
+
<a id="emailTab" class="fm_fieldset_tab" onclick="form_maker_options_tabs('emailTab')" href="#"><?php _e('Email Options', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
805 |
</li>
|
806 |
<li>
|
807 |
+
<a id="actions" class="fm_fieldset_tab" onclick="form_maker_options_tabs('actions')" href="#"><?php _e('Actions after Submission', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
808 |
</li>
|
809 |
<li>
|
810 |
+
<a id="payment" class="fm_fieldset_tab" onclick="form_maker_options_tabs('payment')" href="#"><?php _e('Payment Options', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
811 |
</li>
|
812 |
<li>
|
813 |
+
<a id="javascript" class="fm_fieldset_tab" onclick="form_maker_options_tabs('javascript'); codemirror_for_javascript();" href="#"><?php _e('JavaScript', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
814 |
</li>
|
815 |
<li>
|
816 |
+
<a id="conditions" class="fm_fieldset_tab" onclick="form_maker_options_tabs('conditions')" href="#"><?php _e('Conditional Fields', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
817 |
</li>
|
818 |
<li>
|
819 |
+
<a id="mapping" class="fm_fieldset_tab" onclick="form_maker_options_tabs('mapping')" href="#"><?php _e('MySQL Mapping', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
820 |
</li>
|
821 |
<?php
|
822 |
if ( !empty($addons['tabs']) ) {
|
840 |
<div class="wd-box-section">
|
841 |
<div class="wd-box-content">
|
842 |
<span class="wd-group">
|
843 |
+
<label class="wd-label"><?php _e('Published', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
844 |
<input type="radio" name="published" <?php echo $row->published == 1 ? 'checked="checked"' : '' ?> id="fm_go-published-1" class="wd-radio" value="1">
|
845 |
+
<label class="wd-label-radio" for="fm_go-published-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
846 |
<input type="radio" name="published" <?php echo $row->published == 0 ? 'checked="checked"' : '' ?> id="fm_go-published-0" class="wd-radio" value="0">
|
847 |
+
<label class="wd-label-radio" for="fm_go-published-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
848 |
</span>
|
849 |
<span class="wd-group">
|
850 |
+
<label class="wd-label"><?php _e('Save data(to database)', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
851 |
<input type="radio" name="savedb" <?php echo $row->savedb == 1 ? 'checked="checked"' : '' ?> id="fm_go-savedb-1" class="wd-radio" value="1">
|
852 |
+
<label class="wd-label-radio" for="fm_go-savedb-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
853 |
<input type="radio" name="savedb" <?php echo $row->savedb == 0 ? 'checked="checked"' : '' ?> id="fm_go-savedb-0" class="wd-radio" value="0">
|
854 |
+
<label class="wd-label-radio" for="fm_go-savedb-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
855 |
+
<p class="description"><?php _e('IMPORTANT! If you disable this option, the information submitted through this form will not be saved in the database and will not be displayed on the Submissions page.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
856 |
+
</span>
|
857 |
<span class="wd-group theme-wrap">
|
858 |
+
<label class="wd-label"><?php _e('Theme', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
859 |
<select id="theme" name="theme" onChange="set_theme()">
|
860 |
+
<optgroup label="<?php _e('New Themes', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
861 |
+
<option value="0" <?php echo $row->theme && $row->theme == 0 ? 'selected' : '' ?> data-version="2"><?php _e('Inherit From Website Theme', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
862 |
+
<?php
|
863 |
+
$optiongroup = TRUE;
|
864 |
+
foreach ($themes as $theme) {
|
865 |
+
if ($optiongroup && $theme->version == 1) {
|
866 |
+
$optiongroup = FALSE;
|
867 |
+
?>
|
868 |
+
</optgroup>
|
869 |
+
<optgroup label="<?php _e('Outdated Themes', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
870 |
+
<?php } ?>
|
871 |
+
<option value="<?php echo $theme->id; ?>" <?php echo(($theme->id == $row->theme) ? 'selected' : ''); ?> data-version="<?php echo $theme->version; ?>"><?php echo $theme->title; ?></option>
|
872 |
+
<?php } ?>
|
|
|
|
|
873 |
</optgroup>
|
874 |
</select>
|
875 |
<a id="edit_css" class="options-edit-button" onclick="window.open('<?php echo add_query_arg(array(
|
876 |
'current_id' => ($row->theme && $row->theme != '0' ? $row->theme : $default_theme),
|
877 |
+
WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce)
|
878 |
+
), admin_url('admin.php?page=themes' . WDFMInstance(self::PLUGIN)->menu_postfix . '&task=edit')); ?>'); return false;"><?php _e('Edit', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
879 |
+
<div id="old_theme_notice" class="error inline" style="display: none;"><p><?php _e('The theme you have selected is outdated. Please choose one from New Themes section.', WDFMInstance(self::PLUGIN)->prefix); ?></p></div>
|
880 |
+
<p class="description"><?php _e('The appearance of your forms is controlled by the theme you select with this option. Press Edit button to open and modify your form theme.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
881 |
|
882 |
</span>
|
883 |
<span class="wd-group">
|
884 |
+
<label class="wd-label" for="requiredmark"><?php _e('Required fields mark', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
885 |
<input type="text" id="requiredmark" name="requiredmark" value="<?php echo $row->requiredmark; ?>">
|
886 |
+
<p class="description"><?php _e('Use this option to change the mark for required fields of your form.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
887 |
</span>
|
888 |
<span class="wd-group">
|
889 |
+
<label class="wd-label"><?php _e('Save Uploads', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
890 |
<input type="radio" name="save_uploads" <?php echo $row->save_uploads == 1 ? 'checked="checked"' : '' ?> id="fm_go-save_uploads-1" class="wd-radio" value="1">
|
891 |
+
<label class="wd-label-radio" for="fm_go-save_uploads-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
892 |
<input type="radio" name="save_uploads" <?php echo $row->save_uploads == 0 ? 'checked="checked"' : '' ?> id="fm_go-save_uploads-0" class="wd-radio" value="0">
|
893 |
+
<label class="wd-label-radio" for="fm_go-save_uploads-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
894 |
+
<p class="description"><?php _e('IMPORTANT! If you disable this option, the files uploaded through your form will not be saved on your site. The files will still be sent to emails and saved in Google Drive or Dropbox, if configured.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
895 |
</span>
|
896 |
</div>
|
897 |
</div>
|
899 |
<div class="wd-table-col wd-table-col-50 wd-table-col-right">
|
900 |
<div class="wd-box-section">
|
901 |
<div class="wd-box-content">
|
902 |
+
<?php
|
903 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
904 |
+
echo $this->free_message(__('This functionality is available in Premium version', WDFMInstance(self::PLUGIN)->prefix));
|
905 |
+
}
|
906 |
+
?>
|
907 |
+
<span class="wd-group <?php if(WDFMInstance(self::PLUGIN)->is_free) { echo 'fm-free-option'; } ?>">
|
908 |
+
<label class="wd-label"><?php _e('Allow User to see submissions', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
909 |
+
<?php
|
910 |
+
$checked_UserGroup = explode(',', $row->user_id_wd);
|
911 |
+
$i = 0;
|
912 |
+
foreach ( $userGroups as $val => $uG ) {
|
913 |
+
echo "\r\n" . '<input type="checkbox" value="' . $val . '" id="user_' . $i . '" ';
|
914 |
+
if ( in_array($val, $checked_UserGroup) ) {
|
915 |
+
echo ' checked="checked"';
|
916 |
+
}
|
917 |
+
echo ' onchange="acces_level(' . count($userGroups) . ')" ' . disabled(WDFMInstance(self::PLUGIN)->is_free, true, false) . ' /><label for="user_' . $i . '">' . $uG["name"] . '</label><br>';
|
918 |
+
$i++;
|
919 |
+
}
|
920 |
+
?>
|
921 |
+
<input type="checkbox" value="guest" id="user_<?php echo $i; ?>" onchange="acces_level(<?php echo count($userGroups); ?>)"<?php echo(in_array('guest', $checked_UserGroup) ? 'checked="checked"' : '') ?> <?php disabled(WDFMInstance(self::PLUGIN)->is_free, true) ?> /><label for="user_<?php echo $i; ?>">Guest</label>
|
922 |
+
<input type="hidden" name="user_id_wd" value="<?php echo $row->user_id_wd ?>" id="user_id_wd" />
|
923 |
+
<p class="description"><?php _e('Mark all user roles which will be able to view front-end submissions, when you publish them on a post or page.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
924 |
+
</span>
|
925 |
+
<?php if ( count($label_titles_for_submissions) ) { ?>
|
926 |
+
<span class="wd-group <?php if(WDFMInstance(self::PLUGIN)->is_free) { echo 'fm-free-option'; } ?>">
|
927 |
+
<label class="wd-label"><?php _e('Fields to hide in frontend submissions', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
928 |
+
<ul id="form_fields">
|
929 |
+
<li>
|
930 |
+
<input type="checkbox" name="all_fields" id="all_fields" onclick="checkAllByParentId('form_fields'); checked_labels('filed_label')" value="submit_id,<?php echo implode(',', $labels_id_for_submissions) . "," . ($payment_info ? "payment_info" : ""); ?>" <?php disabled(WDFMInstance(self::PLUGIN)->is_free, true) ?> />
|
931 |
+
<label for="all_fields"><?php _e('Select All', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
932 |
+
</li>
|
933 |
<?php
|
934 |
+
echo "<li><input type=\"checkbox\" id=\"submit_id\" name=\"submit_id\" value=\"submit_id\" class=\"filed_label\" onclick=\"checked_labels('filed_label')\" " . disabled(WDFMInstance(self::PLUGIN)->is_free, true, false) . " /><label for=\"submit_id\">ID</label></li>";
|
935 |
+
for ( $i = 0, $n = count($label_titles_for_submissions); $i < $n; $i++ ) {
|
936 |
+
$field_label = $label_titles_for_submissions[$i];
|
937 |
+
echo "<li><input type=\"checkbox\" id=\"filed_label" . $i . "\" name=\"filed_label" . $i . "\" value=\"" . $labels_id_for_submissions[$i] . "\" class=\"filed_label\" onclick=\"checked_labels('filed_label')\" " . disabled(WDFMInstance(self::PLUGIN)->is_free, true, false) . " /><label for=\"filed_label" . $i . "\">" . (strlen($field_label) > 80 ? substr($field_label, 0, 80) . '...' : $field_label) . "</label></li>";
|
938 |
+
}
|
939 |
+
if ( $payment_info ) {
|
940 |
+
echo "<li><input type=\"checkbox\" id=\"payment_info\" name=\"payment_info\" value=\"payment_info\" class=\"filed_label\" onclick=\"checked_labels('filed_label')\" " . disabled(WDFMInstance(self::PLUGIN)->is_free, true, false) . " /><label for=\"payment_info\">Payment Info</label></li>";
|
|
|
|
|
941 |
}
|
942 |
?>
|
943 |
+
</ul>
|
944 |
+
<input type="hidden" name="frontend_submit_fields" value="<?php echo $row->frontend_submit_fields ?>" id="frontend_submit_fields" />
|
945 |
+
<p class="description"><?php _e('Select fields of the form and Stats Fields which will not to be displayed within front-end submissions, when you publish them.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
946 |
+
</span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
947 |
<?php if ( $stats_labels ) { ?>
|
948 |
<span class="wd-group">
|
949 |
+
<label class="wd-label"><?php _e('Stats fields:', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
950 |
+
<ul id="stats_fields">
|
951 |
+
<li>
|
952 |
+
<input type="checkbox" name="all_stats_fields" id="all_stats_fields" onclick="checkAllByParentId('stats_fields'); checked_labels('stats_filed_label');" value="<?php echo implode(',', $stats_labels_ids) . ","; ?>" <?php disabled(WDFMInstance(self::PLUGIN)->is_free, true) ?> />
|
953 |
+
<label for="all_stats_fields"><?php _e('Select All', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
954 |
+
</li>
|
955 |
+
<?php
|
956 |
+
for ( $i = 0, $n = count($stats_labels); $i < $n; $i++ ) {
|
957 |
+
$field_label = $stats_labels[$i];
|
958 |
+
echo "<li><input type=\"checkbox\" id=\"stats_filed_label" . $i . "\" name=\"stats_filed_label" . $i . "\" value=\"" . $stats_labels_ids[$i] . "\" class=\"stats_filed_label\" onclick=\"checked_labels('stats_filed_label')\" " . disabled(WDFMInstance(self::PLUGIN)->is_free, true, false) . " /><label for=\"stats_filed_label" . $i . "\">" . (strlen($field_label) > 80 ? substr($field_label, 0, 80) . '...' : $field_label) . "</label></li>";
|
959 |
+
}
|
960 |
+
?>
|
961 |
+
</ul>
|
962 |
+
<input type="hidden" name="frontend_submit_stat_fields" value="<?php echo $row->frontend_submit_stat_fields ?>" id="frontend_submit_stat_fields" />
|
963 |
+
<p class="description"><?php _e('Select fields of the form and Stats Fields which will not to be displayed within front-end submissions, when you publish them.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
964 |
</span>
|
965 |
<?php }
|
966 |
} ?>
|
975 |
<div class="wd-box-section">
|
976 |
<div class="wd-box-content">
|
977 |
<div class="wd-group">
|
978 |
+
<label class="wd-label"><?php _e('Send E-mail', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
979 |
<input type="radio" name="sendemail" <?php echo $row->sendemail == 1 ? 'checked="checked"' : '' ?> id="fm_sendemail-1" class="wd-radio" value="1" onchange="fm_toggle_email_options(true)" />
|
980 |
+
<label class="wd-label-radio" for="fm_sendemail-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
981 |
<input type="radio" name="sendemail" <?php echo $row->sendemail == 0 ? 'checked="checked"' : '' ?> id="fm_sendemail-0" class="wd-radio" value="0" onchange="fm_toggle_email_options(false)" />
|
982 |
+
<label class="wd-label-radio" for="fm_sendemail-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
983 |
+
<p class="description"><?php _e('Enable this setting to send submitted information to administrators and/or the submitter.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
984 |
+
<p class="description fm_email_options"><?php _e('In case you cannot find the submission email in your Inbox, make sure to check the Spam folder as well.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
985 |
</div>
|
986 |
</div>
|
987 |
</div>
|
992 |
<div class="wd-table-col wd-table-col-50 wd-table-col-left">
|
993 |
<div class="wd-box-section">
|
994 |
<div class="wd-box-title">
|
995 |
+
<strong><?php _e('Email to Administrator', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
996 |
</div>
|
997 |
<div class="wd-box-content">
|
998 |
+
<div class="wd-group wd-has-placeholder">
|
999 |
+
<label class="wd-label" for="mailToAdd"><?php _e('Email to send submissions to', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1000 |
+
<input type="text" id="mailToAdd" name="mailToAdd" />
|
1001 |
<input type="hidden" id="mail" name="mail" value="<?php echo $row->mail . ($row->mail && (substr($row->mail, -1) != ',') ? ',' : ''); ?>" />
|
1002 |
+
<span class="dashicons dashicons-list-view" data-id="mailToAdd"></span>
|
1003 |
<div id="cfm_mail_div">
|
1004 |
<?php
|
1005 |
$mail_array = explode(',', $row->mail);
|
1007 |
if ( $mail && $mail != ',' ) {
|
1008 |
?>
|
1009 |
<p class="fm_mail_input">
|
1010 |
+
<span class="mail_name"><?php echo $mail; ?></span><span class="dashicons dashicons-trash" onclick="fm_delete_mail(this, '<?php echo $mail; ?>')" title="<?php _e('Delete Email', WDFMInstance(self::PLUGIN)->prefix); ?>"></span>
|
1011 |
</p>
|
1012 |
<?php
|
1013 |
}
|
1014 |
}
|
1015 |
?>
|
1016 |
</div>
|
1017 |
+
<p class="description"><?php _e('Specify the email address(es), to which submitted form information will be sent. For multiple email addresses separate with commas.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1018 |
</div>
|
1019 |
+
<div class="wd-group wd-has-placeholder">
|
1020 |
+
<label class="wd-label" for="mail_subject"><?php _e('Subject', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1021 |
+
<input type="text" id="mail_subject" name="mail_subject" value="<?php echo !empty($row->mail_subject) ? $row->mail_subject : '{formtitle}'; ?>" />
|
1022 |
+
<span class="dashicons dashicons-list-view" data-id="mail_subject"></span>
|
1023 |
+
<p class="description"><?php _e('Add a custom subject or search for a form field for the submission email. In case it’s left blank, Form Title will be set as the subject of submission emails.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1024 |
</div>
|
1025 |
<div class="wd-group">
|
1026 |
+
<label class="wd-label" for="script_mail"><?php _e('Custom Text in Email For Administrator', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1027 |
+
<div class="wd-editor-placeholder">
|
1028 |
+
<span class="dashicons dashicons-list-view" data-id="script_mail"></span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1029 |
</div>
|
1030 |
<?php
|
1031 |
if ( user_can_richedit() ) {
|
1042 |
<?php
|
1043 |
}
|
1044 |
?>
|
1045 |
+
<p class="description"><?php _e('Write custom content to the email message which is sent to administrator. Include All Fields List to forward all submitted information, or click on fields buttons to use individual field values in the content.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1046 |
</div>
|
1047 |
<div class="postbox closed">
|
1048 |
<button class="button-link handlediv" type="button" aria-expanded="true">
|
1049 |
+
<span class="screen-reader-text"><?php _e('Toggle panel:', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
1050 |
<span class="toggle-indicator" aria-hidden="false"></span>
|
1051 |
</button>
|
1052 |
<h2 class="hndle">
|
1053 |
+
<span><?php _e('Advanced', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
1054 |
</h2>
|
1055 |
<div class="inside">
|
1056 |
<div class="wd-group">
|
1057 |
+
<label class="wd-label"><?php _e('Email From', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1058 |
<?php
|
1059 |
$is_other = TRUE;
|
1060 |
for ( $i = 0; $i < $fields_count - 1; $i++ ) {
|
1075 |
}
|
1076 |
?>
|
1077 |
<input style="<?php echo ($fields_count == 1) ? 'display:none;' : ''; ?>" class="wd-radio" type="radio" id="other" name="from_mail" value="other" <?php echo ($is_other) ? 'checked="checked"' : ''; ?> onclick="wdshow('mail_from_other_wrap')" />
|
1078 |
+
<label style="<?php echo ($fields_count == 1) ? 'display:none;' : ''; ?>" class="wd-label-radio" for="other"><?php _e('Other', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1079 |
<p style="display: <?php echo ($is_other) ? 'block;' : 'none;'; ?>" id="mail_from_other_wrap">
|
1080 |
<input type="text" name="mail_from_other" id="mail_from_other" value="<?php echo ($is_other) ? $row->from_mail : ''; ?>" />
|
1081 |
</p>
|
1082 |
+
<p class="description"><?php _e('Specify the email address from which the administrator will receive the email.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1083 |
</div>
|
1084 |
+
<div class="wd-group wd-has-placeholder">
|
1085 |
+
<label class="wd-label" for="from_name"><?php _e('From Name', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1086 |
+
<input type="text" name="from_name" value="<?php echo $row->from_name; ?>" id="from_name" />
|
1087 |
+
<span class="dashicons dashicons-list-view" data-id="from_name"></span>
|
1088 |
+
<p class="description"><?php _e('Set the name or search for a form field which is shown as the sender’s name in submission or confirmation emails.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1089 |
</div>
|
1090 |
<div class="wd-group">
|
1091 |
+
<label class="wd-label" for="from_name"><?php _e('Reply to (if different from "Email From")', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1092 |
<?php
|
1093 |
$is_other = TRUE;
|
1094 |
for ( $i = 0; $i < $fields_count - 1; $i++ ) {
|
1109 |
}
|
1110 |
?>
|
1111 |
<input style="<?php echo ($fields_count == 1) ? 'display: none;' : ''; ?>" class="wd-radio" type="radio" id="other1" name="reply_to" value="other" <?php echo ($is_other) ? 'checked="checked"' : ''; ?> onclick="wdshow('reply_to_other_wrap')" />
|
1112 |
+
<label style="<?php echo ($fields_count == 1) ? 'display: none;' : ''; ?>" class="wd-label-radio" for="other1"><?php _e('Other', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1113 |
<p style="display: <?php echo ($is_other) ? 'block;' : 'none;'; ?>" id="reply_to_other_wrap">
|
1114 |
<input type="text" name="reply_to_other" value="<?php echo ($is_other && $row->reply_to) ? $row->reply_to : ''; ?>" id="reply_to_other" />
|
1115 |
</p>
|
1116 |
+
<p class="description"><?php _e('Specify an alternative email address, to which the administrator will be able to reply upon receiving the message.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1117 |
</div>
|
1118 |
<div class="wd-group">
|
1119 |
+
<label class="wd-label" for="mail_cc"><?php _e('CC', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1120 |
<input type="text" id="mail_cc" name="mail_cc" value="<?php echo $row->mail_cc ?>" />
|
1121 |
+
<p class="description"><?php _e('Provide additional email addresses to send the submission or confirmation email to. The receiver will be able to view all other recipients.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1122 |
</div>
|
1123 |
<div class="wd-group">
|
1124 |
+
<label class="wd-label" for="mail_bcc"><?php _e('BCC', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1125 |
<input type="text" id="mail_bcc" name="mail_bcc" value="<?php echo $row->mail_bcc ?>" />
|
1126 |
+
<p class="description"><?php _e('Write additional email addresses to send the submission or confirmation email to. The receiver will not be able to view other recipients.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1127 |
</div>
|
1128 |
<div class="wd-group">
|
1129 |
+
<label class="wd-label"><?php _e('Mode', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1130 |
<input type="radio" name="mail_mode" <?php echo $row->mail_mode == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_mode-1" class="wd-radio" value="1">
|
1131 |
+
<label class="wd-label-radio" for="fm_mo_mail_mode-1"><?php _e('HTML', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1132 |
<input type="radio" name="mail_mode" <?php echo $row->mail_mode == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_mode-0" class="wd-radio" value="0">
|
1133 |
+
<label class="wd-label-radio" for="fm_mo_mail_mode-0"><?php _e('Text', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1134 |
+
<p class="description"><?php _e('Select the layout of the submission email, Text or HTML.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1135 |
</div>
|
1136 |
<div class="wd-group">
|
1137 |
+
<label class="wd-label"><?php _e('Attach File', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1138 |
<input type="radio" name="mail_attachment" <?php echo $row->mail_attachment == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_attachment-1" class="wd-radio" value="1">
|
1139 |
+
<label class="wd-label-radio" for="fm_mo_mail_attachment-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1140 |
<input type="radio" name="mail_attachment" <?php echo $row->mail_attachment == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_attachment-0" class="wd-radio" value="0">
|
1141 |
+
<label class="wd-label-radio" for="fm_mo_mail_attachment-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1142 |
+
<p class="description"><?php _e('If you have File Upload fields on your form, enable this setting to attach uploaded files to submission or confirmation email.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1143 |
</div>
|
1144 |
<div class="wd-group">
|
1145 |
+
<label class="wd-label"><?php _e('Email empty fields', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1146 |
<input type="radio" name="mail_emptyfields" <?php echo $row->mail_emptyfields == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_emptyfields-1" class="wd-radio" value="1">
|
1147 |
+
<label class="wd-label-radio" for="fm_mo_mail_emptyfields-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1148 |
<input type="radio" name="mail_emptyfields" <?php echo $row->mail_emptyfields == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_emptyfields-0" class="wd-radio" value="0">
|
1149 |
+
<label class="wd-label-radio" for="fm_mo_mail_emptyfields-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1150 |
+
<p class="description"><?php _e('Disable this setting, in case you do not want to include form fields, which are left empty by the submitter.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1151 |
</div>
|
1152 |
</div>
|
1153 |
</div>
|
1157 |
<div class="wd-table-col wd-table-col-50 wd-table-col-right">
|
1158 |
<div class="wd-box-section">
|
1159 |
<div class="wd-box-title">
|
1160 |
+
<strong><?php _e('Email to User', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
1161 |
</div>
|
1162 |
<div class="wd-box-content">
|
1163 |
<div class="wd-group">
|
1164 |
+
<label class="wd-label"><?php _e('Send to', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1165 |
<?php
|
1166 |
$fields = explode('*:*id*:*type_submitter_mail*:*type*:*', $row->form_fields);
|
1167 |
$fields_count = count($fields);
|
1168 |
if ( $fields_count == 1 ) {
|
1169 |
+
_e('There is no email field', WDFMInstance(self::PLUGIN)->prefix);
|
1170 |
}
|
1171 |
else {
|
1172 |
for ( $i = 0; $i < $fields_count - 1; $i++ ) {
|
1179 |
}
|
1180 |
}
|
1181 |
?>
|
1182 |
+
<p class="description"><?php _e('Use this setting to select the email field of your form, to which the submissions will be sent.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1183 |
</div>
|
1184 |
+
<div class="wd-group wd-has-placeholder">
|
1185 |
+
<label class="wd-label" for="mail_subject_user"><?php _e('Subject', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1186 |
+
<input type="text" name="mail_subject_user" value="<?php echo !empty($row->mail_subject_user) ? $row->mail_subject_user : '{formtitle}' ?>" id="mail_subject_user" class="mail_subject_user" />
|
1187 |
+
<span class="dashicons dashicons-list-view" data-id="mail_subject_user"></span>
|
1188 |
+
<p class="description"><?php _e('Add a custom subject or search for a form field for the submission email. In case it’s left blank, Form Title will be set as the subject of submission emails.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1189 |
</div>
|
1190 |
<div class="wd-group">
|
1191 |
+
<label class="wd-label" for="script_mail_user"><?php _e('Custom Text in Email For User', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1192 |
+
<div class="wd-editor-placeholder">
|
1193 |
+
<span class="dashicons dashicons-list-view" data-id="script_mail_user"></span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1194 |
</div>
|
1195 |
<?php
|
1196 |
if ( user_can_richedit() ) {
|
1207 |
<?php
|
1208 |
}
|
1209 |
?>
|
1210 |
+
<p class="description"><?php _e('Write custom content to the email message which is sent to submitter. Include All Fields List to forward all submitted information, or click on fields buttons to use individual field values in the content.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1211 |
</div>
|
1212 |
<div class="postbox closed">
|
1213 |
<button class="button-link handlediv" type="button" aria-expanded="true">
|
1214 |
+
<span class="screen-reader-text"><?php _e('Toggle panel:', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
1215 |
<span class="toggle-indicator" aria-hidden="false"></span>
|
1216 |
</button>
|
1217 |
<h2 class="hndle">
|
1218 |
+
<span><?php _e('Advanced', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
1219 |
</h2>
|
1220 |
<div class="inside">
|
1221 |
<div class="wd-group">
|
1222 |
+
<label class="wd-label" for="mail_from_user"><?php _e('Email From', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1223 |
<input type="text" id="mail_from_user" name="mail_from_user" value="<?php echo $row->mail_from_user; ?>" />
|
1224 |
+
<p class="description"><?php _e('Specify the email address from which the submitter will receive the email.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1225 |
</div>
|
1226 |
+
<div class="wd-group wd-has-placeholder">
|
1227 |
+
<label class="wd-label" for="mail_from_name_user"><?php _e('From Name', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1228 |
+
<input type="text" name="mail_from_name_user" value="<?php echo $row->mail_from_name_user; ?>" id="mail_from_name_user" />
|
1229 |
+
<span class="dashicons dashicons-list-view" data-id="mail_from_name_user"></span>
|
1230 |
+
<p class="description"><?php _e('Set the name or search for a form field which is shown as the sender’s name in submission or confirmation emails.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1231 |
</div>
|
1232 |
<div class="wd-group">
|
1233 |
+
<label class="wd-label" for="reply_to_user"><?php _e('Reply to (if different from "Email From")', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1234 |
<input type="text" name="reply_to_user" value="<?php echo $row->reply_to_user; ?>" id="reply_to_user" />
|
1235 |
+
<p class="description"><?php _e('Specify an alternative email address, to which the submitter will be able to reply upon receiving the message.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1236 |
</div>
|
1237 |
<div class="wd-group">
|
1238 |
+
<label class="wd-label" for="mail_cc_user"><?php _e('CC', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1239 |
<input type="text" name="mail_cc_user" value="<?php echo $row->mail_cc_user ?>" id="mail_cc_user" />
|
1240 |
+
<p class="description"><?php _e('Provide additional email addresses to send the submission or confirmation email to. The receiver will be able to view all other recipients.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1241 |
</div>
|
1242 |
<div class="wd-group">
|
1243 |
+
<label class="wd-label" for="mail_bcc_user"><?php _e('BCC', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1244 |
<input type="text" name="mail_bcc_user" value="<?php echo $row->mail_bcc_user ?>" id="mail_bcc_user" />
|
1245 |
+
<p class="description"><?php _e('Write additional email addresses to send the submission or confirmation email to. The receiver will not be able to view other recipients.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1246 |
</div>
|
1247 |
<div class="wd-group">
|
1248 |
+
<label class="wd-label"><?php _e('Mode', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1249 |
<input type="radio" name="mail_mode_user" <?php echo $row->mail_mode_user == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_mode_user-1" class="wd-radio" value="1">
|
1250 |
+
<label class="wd-label-radio" for="fm_mo_mail_mode_user-1"><?php _e('HTML', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1251 |
<input type="radio" name="mail_mode_user" <?php echo $row->mail_mode_user == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_mode_user-0" class="wd-radio" value="0">
|
1252 |
+
<label class="wd-label-radio" for="fm_mo_mail_mode_user-0"><?php _e('Text', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1253 |
+
<p class="description"><?php _e('Select the layout of the submission email, Text or HTML.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1254 |
</div>
|
1255 |
<div class="wd-group">
|
1256 |
+
<label class="wd-label"><?php _e('Attach File', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1257 |
<input type="radio" name="mail_attachment_user" <?php echo $row->mail_attachment_user == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_attachment_user-1" class="wd-radio" value="1">
|
1258 |
+
<label class="wd-label-radio" for="fm_mo_mail_attachment_user-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1259 |
<input type="radio" name="mail_attachment_user" <?php echo $row->mail_attachment_user == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_attachment_user-0" class="wd-radio" value="0">
|
1260 |
+
<label class="wd-label-radio" for="fm_mo_mail_attachment_user-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1261 |
+
<p class="description"><?php _e('If you have File Upload fields on your form, enable this setting to attach uploaded files to submission or confirmation email.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1262 |
</div>
|
1263 |
<div class="wd-group">
|
1264 |
+
<label class="wd-label"><?php _e('Email verification', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1265 |
<input type="radio" name="mail_verify" <?php echo $row->mail_verify == 1 ? 'checked="checked"' : '' ?> id="fm_mo_mail_verify-1" onclick="wdshow('expire_link')" class="wd-radio" value="1">
|
1266 |
+
<label class="wd-label-radio" for="fm_mo_mail_verify-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1267 |
<input type="radio" name="mail_verify" <?php echo $row->mail_verify == 0 ? 'checked="checked"' : '' ?> id="fm_mo_mail_verify-0" onclick="wdhide('expire_link')" class="wd-radio" value="0">
|
1268 |
+
<label class="wd-label-radio" for="fm_mo_mail_verify-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1269 |
+
<p class="description"><?php _e('Activate this option, in case you would like the users to verify their email addresses. If it’s enabled, the user email will contain a verification link.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1270 |
</div>
|
1271 |
<div class="wd-group" <?php echo($row->mail_verify == 0 ? 'style="display:none;"' : '') ?> id="expire_link">
|
1272 |
+
<label class="wd-label" for="mail_verify_expiretime"><?php _e('Verification link expires in', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1273 |
<input class="inputbox" type="text" name="mail_verify_expiretime" maxlength="10" value="<?php echo($row->mail_verify_expiretime ? $row->mail_verify_expiretime : 0); ?>" onkeypress="return check_isnum_point(event)" id="mail_verify_expiretime">
|
1274 |
+
<small><?php _e(' -- hours (0 - never expires).', WDFMInstance(self::PLUGIN)->prefix); ?></small>
|
1275 |
<a target="_blank" href="<?php echo add_query_arg(array(
|
1276 |
'post' => $params["mail_ver_id"],
|
1277 |
'action' => 'edit',
|
1278 |
+
), admin_url('post.php')); ?>"><?php _e('Edit post', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
1279 |
+
<p class="description"><?php _e('Use this option to specify a time period (hours), during which the user will be able to verify their email address.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1280 |
</div>
|
1281 |
</div>
|
1282 |
</div>
|
1291 |
<div class="wd-box-section">
|
1292 |
<div class="wd-box-content">
|
1293 |
<span class="wd-group">
|
1294 |
+
<label class="wd-label"><?php _e('Action type', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1295 |
<input type="radio" name="submit_text_type" id="text_type_none" onclick="set_type('none')" value="1" <?php echo ($row->submit_text_type != 2 && $row->submit_text_type != 3 && $row->submit_text_type != 4 && $row->submit_text_type != 5) ? "checked" : ""; ?> />
|
1296 |
+
<label for="text_type_none"><?php _e('Stay on Form', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1297 |
<br>
|
1298 |
<input type="radio" name="submit_text_type" id="text_type_post" onclick="set_type('post')" value="2" <?php echo ($row->submit_text_type == 2) ? "checked" : ""; ?> />
|
1299 |
+
<label for="text_type_post"><?php _e('Post', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1300 |
<br>
|
1301 |
<input type="radio" name="submit_text_type" id="text_type_page" onclick="set_type('page')" value="5" <?php echo ($row->submit_text_type == 5) ? "checked" : ""; ?> />
|
1302 |
+
<label for="text_type_page"><?php _e('Page', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1303 |
<br>
|
1304 |
<input type="radio" name="submit_text_type" id="text_type_custom_text" onclick="set_type('custom_text')" value="3" <?php echo ($row->submit_text_type == 3) ? "checked" : ""; ?> />
|
1305 |
+
<label for="text_type_custom_text"><?php _e('Custom Text', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1306 |
<br>
|
1307 |
<input type="radio" name="submit_text_type" id="text_type_url" onclick="set_type('url')" value="4" <?php echo ($row->submit_text_type == 4) ? "checked" : ""; ?> />
|
1308 |
+
<label for="text_type_url"><?php _e('URL', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1309 |
</span>
|
1310 |
<span class="wd-group">
|
1311 |
<div id="post" <?php echo(($row->submit_text_type != 2) ? 'style="display:none"' : ''); ?>>
|
1312 |
+
<label class="wd-label"><?php _e('Post', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1313 |
<select id="post_name" name="post_name">
|
1314 |
<option value="0">- Select Post -</option>
|
1315 |
<?php
|
1326 |
</select>
|
1327 |
</div>
|
1328 |
<div id="page" <?php echo(($row->submit_text_type != 5) ? 'style="display:none"' : ''); ?>>
|
1329 |
+
<label class="wd-label"><?php _e('Page', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1330 |
<select id="page_name" name="page_name">
|
1331 |
<option value="0">- Select Page -</option>
|
1332 |
<?php
|
1342 |
</select>
|
1343 |
</div>
|
1344 |
<div id="custom_text" <?php echo(($row->submit_text_type != 3) ? 'style="display: none;"' : ''); ?>>
|
1345 |
+
<label class="wd-label"><?php _e('Text', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1346 |
+
<div class="wd-editor-placeholder">
|
1347 |
+
<span class="dashicons dashicons-list-view" data-id="submit_text"></span>
|
1348 |
+
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1349 |
<?php
|
1350 |
if ( user_can_richedit() ) {
|
1351 |
wp_editor($row->submit_text, 'submit_text', array(
|
1365 |
?>
|
1366 |
</div>
|
1367 |
<div id="url" <?php echo(($row->submit_text_type != 4) ? 'style="display:none"' : ''); ?>>
|
1368 |
+
<label class="wd-label"><?php _e('URL', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1369 |
<input type="text" id="url" name="url" value="<?php echo $row->url; ?>" />
|
1370 |
</div>
|
1371 |
</span>
|
1374 |
</div>
|
1375 |
</div>
|
1376 |
</div>
|
|
|
1377 |
<div id="payment_fieldset" class="adminform fm_fieldset_deactive">
|
1378 |
<div class="wd-table">
|
1379 |
<div class="wd-table-col-70">
|
1380 |
<div class="wd-box-section">
|
1381 |
<div class="wd-box-content">
|
1382 |
<div class="wd-group">
|
1383 |
+
<label class="wd-label"><?php _e('Payment Method', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1384 |
<input type="radio" name="paypal_mode" id="paypal_mode0" value="none" class="wd-radio" <?php echo ($payment_method == "none") ? "checked" : ""; ?> onchange="fm_change_payment_method('none');" />
|
1385 |
+
<label for="paypal_mode0"><?php _e('None', WDFMInstance(self::PLUGIN)->prefix); ?></label><br>
|
1386 |
<input type="radio" name="paypal_mode" id="paypal_mode1" value="paypal" class="wd-radio" <?php echo ($payment_method == "paypal") ? "checked" : ""; ?> onchange="fm_change_payment_method('paypal');" />
|
1387 |
+
<label for="paypal_mode1"><?php _e('Paypal', WDFMInstance(self::PLUGIN)->prefix); ?></label><br>
|
1388 |
<input type="radio" name="paypal_mode" id="paypal_mode2" value="stripe" <?php echo ($payment_method == "stripe") ? "checked" : ""; ?> class="wd-radio" onchange="fm_change_payment_method('stripe');" />
|
1389 |
+
<label for="paypal_mode2"><?php _e('Stripe', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1390 |
</div>
|
1391 |
<div class="fm_payment_option">
|
1392 |
+
<?php
|
1393 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
1394 |
+
echo $this->free_message(__('PAYPAL is available in Premium version', WDFMInstance(self::PLUGIN)->prefix));
|
1395 |
+
}
|
1396 |
+
?>
|
1397 |
+
<div class="wd-group <?php if(WDFMInstance(self::PLUGIN)->is_free) { echo 'fm-free-option'; } ?>">
|
1398 |
+
<label class="wd-label" for="payment_currency"><?php _e('Payment Currency', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1399 |
+
<select id="payment_currency" name="payment_currency" <?php disabled(WDFMInstance(self::PLUGIN)->is_free, true) ?>>
|
1400 |
<option value="USD" <?php echo(($row->payment_currency == 'USD') ? 'selected' : ''); ?>>$ • U.S. Dollar</option>
|
1401 |
<option value="EUR" <?php echo(($row->payment_currency == 'EUR') ? 'selected' : ''); ?>>€ • Euro</option>
|
1402 |
<option value="GBP" <?php echo(($row->payment_currency == 'GBP') ? 'selected' : ''); ?>>£ • Pound Sterling</option>
|
1421 |
<option value="PHP" <?php echo(($row->payment_currency == 'PHP') ? 'selected' : ''); ?>>₱ • Philippine Peso</option>
|
1422 |
<option value="THB" <?php echo(($row->payment_currency == 'THB') ? 'selected' : ''); ?>>฿ • Thai Bahtv</option>
|
1423 |
</select>
|
1424 |
+
<p class="description"><?php _e('Choose the currency to be used for the payments made through your form.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1425 |
</div>
|
1426 |
+
<div class="wd-group <?php if(WDFMInstance(self::PLUGIN)->is_free) { echo 'fm-free-option'; } ?>">
|
1427 |
+
<label class="wd-label" for="tax"><?php _e('Tax', WDFMInstance(self::PLUGIN)->prefix); ?> (%)</label>
|
1428 |
+
<input type="text" name="tax" id="tax" value="<?php echo $row->tax; ?>" class="text_area" onKeyPress="return check_isnum_point(event)" <?php disabled(WDFMInstance(self::PLUGIN)->is_free, true) ?> />
|
1429 |
+
<p class="description"><?php _e('Specify the percentage of the tax. It will be calculated from the total payment amount of your form.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1430 |
</div>
|
1431 |
+
<div class="wd-group <?php if(WDFMInstance(self::PLUGIN)->is_free) { echo 'fm-free-option'; } ?>">
|
1432 |
+
<label class="wd-label"><?php _e('Checkout Mode', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1433 |
+
<input type="radio" name="checkout_mode" <?php echo $row->checkout_mode == 1 ? 'checked="checked"' : '' ?> id="checkout_mode-1" class="wd-radio" value="1" <?php disabled(WDFMInstance(self::PLUGIN)->is_free, true) ?> />
|
1434 |
+
<label class="wd-label-radio" for="checkout_mode-1"><?php _e('Production', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1435 |
+
<input type="radio" name="checkout_mode" <?php echo $row->checkout_mode == 0 ? 'checked="checked"' : '' ?> id="checkout_mode-0" class="wd-radio" value="0" <?php disabled(WDFMInstance(self::PLUGIN)->is_free, true) ?> />
|
1436 |
+
<label class="wd-label-radio" for="checkout_mode-0"><?php _e('Testmode', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1437 |
</div>
|
1438 |
+
<div class="wd-group <?php if(WDFMInstance(self::PLUGIN)->is_free) { echo 'fm-free-option'; } ?>">
|
1439 |
+
<label class="wd-label" for="paypal_email"><?php _e('Paypal email', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1440 |
+
<input type="text" name="paypal_email" id="paypal_email" value="<?php echo $row->paypal_email; ?>" class="text_area" <?php disabled(WDFMInstance(self::PLUGIN)->is_free, true) ?> />
|
1441 |
+
<p class="description"><?php _e('Provide the email address of a valid PayPal account. It will receive the payments made through your form.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1442 |
</div>
|
1443 |
</div>
|
1444 |
<div class="fm_payment_option_stripe">
|
1445 |
<?php
|
1446 |
if ( $stripe_addon['enable'] && !empty($stripe_addon['html']) ) {
|
1447 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
1448 |
+
echo $this->free_message(__('STRIPE add-on compatible with Premium version only', WDFMInstance(self::PLUGIN)->prefix));
|
1449 |
+
}
|
1450 |
+
else {
|
1451 |
+
echo $stripe_addon[ 'html' ];
|
1452 |
+
}
|
1453 |
}
|
1454 |
else {
|
1455 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
1456 |
+
echo $this->promo_box(__('This feature is available only in the Premium version', WDFMInstance(self::PLUGIN)->prefix), __('Requires STRIPE add-on.', WDFMInstance(self::PLUGIN)->prefix), 'https://web-dorado.com/products/wordpress-form/add-ons/stripe.html');
|
1457 |
+
}
|
1458 |
+
else {
|
1459 |
+
echo $this->free_message(__('This feature requires STRIPE add-on', WDFMInstance(self::PLUGIN)->prefix), 'https://web-dorado.com/products/wordpress-form/add-ons/stripe.html', __( 'Buy', WDFMInstance(self::PLUGIN)->prefix ));
|
1460 |
+
}
|
1461 |
}
|
1462 |
?>
|
1463 |
</div>
|
1585 |
<div class="wd-box-section">
|
1586 |
<div class="wd-box-content">
|
1587 |
<div class="wd-group" id="conditions_fieldset_wrap">
|
1588 |
+
<p class="description"><?php _e('Press Add Condition button to configure the first condition of your form. Show/Hide select box represents the action which will be completed, if all or any of the condition statements are fulfilled. Use the second drop-down menu to select the field which will be shown or hidden. Click the little Plus (+) icon to add the statement of your form condition.', WDFMInstance(self::PLUGIN)->prefix); ?><br><br></p>
|
1589 |
<div style="text-align: right;">
|
1590 |
+
<button class="wd-button button-primary" onclick="add_condition('<?php echo $chose_ids; ?>', '<?php echo htmlspecialchars(addslashes($chose_labels)); ?>', '<?php echo $chose_types; ?>', '<?php echo htmlspecialchars(addslashes($chose_paramss)); ?>', '<?php echo $all_ids_cond; ?>', '<?php echo htmlspecialchars(addslashes($all_labels_cond)); ?>'); return false;"><?php _e('Add Condition', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
1591 |
</div>
|
1592 |
<?php
|
1593 |
for ( $k = 0; $k < $count_of_conditions; $k++ ) {
|
1597 |
<select id="show_hide<?php echo $k; ?>" name="show_hide<?php echo $k; ?>" class="fm_condition_show_hide">
|
1598 |
<option value="1" <?php if ( $show_hide[$k] == 1 ) {
|
1599 |
echo 'selected="selected"';
|
1600 |
+
} ?>><?php _e('Show', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1601 |
<option value="0" <?php if ( $show_hide[$k] == 0 ) {
|
1602 |
echo 'selected="selected"';
|
1603 |
+
} ?>><?php _e('Hide', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1604 |
</select>
|
1605 |
<select id="fields<?php echo $k; ?>" name="fields<?php echo $k; ?>" class="fm_condition_fields">
|
1606 |
<?php
|
1619 |
<select id="all_any<?php echo $k; ?>" name="all_any<?php echo $k; ?>" class="fm_condition_all_any">
|
1620 |
<option value="and" <?php if ( $all_any[$k] == "and" ) {
|
1621 |
echo 'selected="selected"';
|
1622 |
+
} ?>><?php _e('all', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1623 |
<option value="or" <?php if ( $all_any[$k] == "or" ) {
|
1624 |
echo 'selected="selected"';
|
1625 |
+
} ?>><?php _e('any', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1626 |
</select>
|
1627 |
+
<span style="display: inline-block; width: 100%; max-width: 235px;"><?php _e('of the following match:', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
1628 |
<span class="dashicons dashicons-trash" onclick="delete_condition('<?php echo $k; ?>')"></span>
|
1629 |
<span class="dashicons dashicons-plus-alt" onclick="add_condition_fields(<?php echo $k; ?>,'<?php echo $chose_ids; ?>', '<?php echo htmlspecialchars(addslashes($chose_labels)); ?>', '<?php echo $chose_types; ?>', '<?php echo htmlspecialchars(addslashes($chose_paramss)); ?>')"></span>
|
1630 |
</div>
|
1742 |
}
|
1743 |
}
|
1744 |
if ( $types[$key_select_or_input] == "type_address" ) {
|
1745 |
+
$w_countries = WDW_FM_Library(self::PLUGIN)->get_countries();
|
1746 |
$w_options = '';
|
1747 |
foreach ( $w_countries as $w_country ) {
|
1748 |
if ( in_array($w_country, $multiselect) ) {
|
1793 |
|
1794 |
<div id="mapping_fieldset" class="adminform fm_fieldset_deactive">
|
1795 |
<?php
|
1796 |
+
if ( WDFMInstance(self::PLUGIN)->is_demo ) {
|
1797 |
+
echo WDW_FM_Library(self::PLUGIN)->message_id(0, 'This feature is disabled in demo.', 'error');
|
1798 |
}
|
1799 |
else {
|
1800 |
?>
|
1803 |
<div class="wd-box-section">
|
1804 |
<div class="wd-box-content">
|
1805 |
<div class="wd-group">
|
1806 |
+
<p class="description"><?php _e('WordPress Form Maker stores the submitted information into [prefix]_formmaker_submits MySQL database table of your website by default. With MySQL Mapping functionality of Form Maker you can insert this data into any local or remote table of your choice, or perform other queries based on submitted values. Press Add Query button to configure the first query for this form.', WDFMInstance(self::PLUGIN)->prefix); ?></p><br><br>
|
1807 |
<div style="text-align: right; padding-bottom: 20px;">
|
1808 |
<button id="add_query" class="wd-button button-primary" onclick="tb_show('', '<?php echo add_query_arg(array(
|
1809 |
+
'action' => 'FormMakerSQLMapping' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
1810 |
'id' => 0,
|
1811 |
'form_id' => $row->id,
|
1812 |
'width' => '1000',
|
1813 |
'height' => '500',
|
1814 |
'TB_iframe' => '1'
|
1815 |
+
), admin_url('admin-ajax.php')); ?>'); return false;"><?php _e('Add Query', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
1816 |
</div>
|
1817 |
<?php if ( $queries ) { ?>
|
1818 |
<table class="wp-list-table widefat fixed posts table_content">
|
1819 |
<thead>
|
1820 |
<tr>
|
1821 |
+
<th style="width:86%;" class="table_large_col"><?php _e('Query', WDFMInstance(self::PLUGIN)->prefix); ?></th>
|
1822 |
+
<th style="width:14%;" class="table_large_col"><?php _e('Delete', WDFMInstance(self::PLUGIN)->prefix); ?></th>
|
1823 |
</tr>
|
1824 |
</thead>
|
1825 |
<?php
|
1826 |
for ( $i = 0, $n = count($queries); $i < $n; $i++ ) {
|
1827 |
$query = $queries[$i];
|
1828 |
$link = add_query_arg(array(
|
1829 |
+
'action' => 'FormMakerSQLMapping' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
1830 |
'id' => $query->id,
|
1831 |
'form_id' => $row->id,
|
1832 |
'width' => '1000',
|
1880 |
<script>
|
1881 |
default_theme = '<?php echo $default_theme; ?>';
|
1882 |
payment_method = '<?php echo $payment_method; ?>';
|
1883 |
+
theme_edit_url = '<?php echo add_query_arg( array('page' => 'themes' . WDFMInstance(self::PLUGIN)->menu_postfix, 'task' =>'edit'), $page_url); ?>';
|
1884 |
|
1885 |
jQuery(document).ready( function () {
|
1886 |
set_theme();
|
1888 |
</script>
|
1889 |
<?php
|
1890 |
}
|
1891 |
+
|
1892 |
+
public function placeholders_popup($placeholders) {
|
1893 |
+
ob_start();
|
1894 |
+
?>
|
1895 |
+
<div id="placeholders_overlay"></div>
|
1896 |
+
<div class="placeholder-popup js">
|
1897 |
+
<div class="placeholder-body meta-box-sortables">
|
1898 |
+
<div class="placeholder-body-col placeholders">
|
1899 |
+
<div class="placeholders_cont">
|
1900 |
+
<p class="description"><?php _e('Select a field, the value of which will be used as the placeholder.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
1901 |
+
<span class="placeholders-filter-cont">
|
1902 |
+
<input class="placeholders-filter" value="" placeholder="<?php _e('Filter', WDFMInstance(self::PLUGIN)->prefix); ?>" tabindex="-1" type="search" />
|
1903 |
+
</span>
|
1904 |
+
<div class="postbox filtered-placeholders hide">
|
1905 |
+
<h2 class="hndle readonly">
|
1906 |
+
<span><?php _e('Filtered placeholders', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
1907 |
+
</h2>
|
1908 |
+
<div class="inside"></div>
|
1909 |
+
</div>
|
1910 |
+
<?php
|
1911 |
+
foreach ($placeholders as $section => $field) {
|
1912 |
+
?>
|
1913 |
+
<div class="postbox<?php echo $section != __('Misc', WDFMInstance(self::PLUGIN)->prefix) ? " closed" : ""; ?>">
|
1914 |
+
<button class="button-link handlediv" type="button" aria-expanded="true">
|
1915 |
+
<span class="screen-reader-text"><?php echo __('Toggle panel:', WDFMInstance(self::PLUGIN)->prefix) , $section; ?></span>
|
1916 |
+
<span class="toggle-indicator" aria-hidden="false"></span>
|
1917 |
+
</button>
|
1918 |
+
<h2 class="hndle">
|
1919 |
+
<span><?php echo $section; ?></span>
|
1920 |
+
</h2>
|
1921 |
+
<div class="inside">
|
1922 |
+
<?php
|
1923 |
+
foreach ($field as $button) {
|
1924 |
+
?>
|
1925 |
+
<button class="wd-button button-secondary" onclick="wd_insert_placeholder(jQuery('.placeholders-active .dashicons-list-view').data('id'), '<?php echo $button['value']; ?>'); return false;" data-type="">
|
1926 |
+
<?php echo $button['title']; ?>
|
1927 |
+
</button>
|
1928 |
+
<?php
|
1929 |
+
}
|
1930 |
+
?>
|
1931 |
+
</div>
|
1932 |
+
</div>
|
1933 |
+
<?php
|
1934 |
+
}
|
1935 |
+
?>
|
1936 |
+
</div>
|
1937 |
+
</div>
|
1938 |
+
</div>
|
1939 |
+
</div>
|
1940 |
+
<?php
|
1941 |
+
return ob_get_clean();
|
1942 |
+
}
|
1943 |
|
1944 |
/**
|
1945 |
* Form layout.
|
1948 |
*
|
1949 |
*/
|
1950 |
public function form_layout( $params ) {
|
1951 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-codemirror');
|
1952 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-colorpicker');
|
1953 |
|
1954 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-codemirror');
|
1955 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-formatting');
|
1956 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-formatting');
|
1957 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-clike');
|
1958 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-css');
|
1959 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-javascript');
|
1960 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-xml');
|
1961 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-php');
|
1962 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-htmlmixed');
|
1963 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-colorpicker');
|
1964 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-form-advanced-layout');
|
1965 |
|
1966 |
$id = $params['id'];
|
1967 |
$page = $params['page'];
|
1977 |
);
|
1978 |
$buttons = array(
|
1979 |
'save' => array(
|
1980 |
+
'title' => __('Update', WDFMInstance(self::PLUGIN)->prefix),
|
1981 |
'value' => 'save',
|
1982 |
'onclick' => 'fm_apply_advanced_layout(\'apply_layout\');',
|
1983 |
'class' => 'button-primary'
|
1984 |
),
|
1985 |
'back' => array(
|
1986 |
+
'title' => __('Back to Form', WDFMInstance(self::PLUGIN)->prefix),
|
1987 |
'value' => 'back',
|
1988 |
'onclick' => 'window.open(\''. $back_url .'\', \'_self\'); return false;',
|
1989 |
'class' => 'button'
|
1997 |
|
1998 |
// Pass the content to form.
|
1999 |
$form_attr = array(
|
2000 |
+
'id' => WDFMInstance(self::PLUGIN)->css_prefix . 'ApplyLayoutForm',
|
2001 |
'name' => 'adminForm',
|
2002 |
+
'class' => WDFMInstance(self::PLUGIN)->css_prefix . 'advanced_layout wd-form',
|
2003 |
'current_id' => $id,
|
2004 |
'enctype' => 'multipart/form-data',
|
2005 |
'action' => add_query_arg( array('page' => $page, 'current_id' => $id ), $page_url),
|
2024 |
<div class="wd-table-col-100">
|
2025 |
<div class="wd-box-section">
|
2026 |
<div class="wd-box-content">
|
2027 |
+
<p><?php _e('To customize the layout of the form fields uncheck the Auto-Generate Layout box and edit the HTML.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
2028 |
+
<p><?php _e('You can change positioning, add in-line styles and etc. Click on the provided buttons to add the corresponding field.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
2029 |
+
<p><?php _e('This will add the following line:', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2030 |
+
<b><span class="cm-tag"><div</span> <span class="cm-attribute">wdid</span>=<span class="cm-string">"example_id"</span> <span class="cm-attribute">class</span>=<span class="cm-string">"wdform_row"</span><span class="cm-tag">></span>%example_id - Example%<span class="cm-tag"></div></span></b> , where <b><span class="cm-tag"><div></span></b> <?php _e('is used to set a row.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
2031 |
<p>
|
2032 |
+
<b style="color:red"><?php _e('Notice', WDFMInstance(self::PLUGIN)->prefix); ?></b><br>
|
2033 |
+
<?php _e('Make sure not to publish the same field twice. This will cause malfunctioning of the form.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2034 |
</p>
|
2035 |
<div class="wd-group">
|
2036 |
+
<label class="wd-label autogen_layout_label" for="autogen_layout"><?php _e('Auto Generate Layout?', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2037 |
<input type="checkbox" value="1" name="autogen_layout" id="autogen_layout" <?php echo (($row->autogen_layout) ? 'checked="checked"' : ''); ?> />
|
2038 |
</div>
|
2039 |
<div class="wd-group">
|
2048 |
}
|
2049 |
?>
|
2050 |
</div>
|
2051 |
+
<span class="button button-hero fm_auto_format_button" onclick="autoFormat()"><strong><?php _e('Apply Source Formatting', WDFMInstance(self::PLUGIN)->prefix); ?></strong> <em>(<?php _e('ctrl-enter', WDFMInstance(self::PLUGIN)->prefix); ?>)</em></span>
|
2052 |
<textarea id="source" name="source" style="display: none;"></textarea>
|
2053 |
<input type="hidden" name="custom_front" id="custom_front" value="" />
|
2054 |
</div>
|
2070 |
$page = $params['page'];
|
2071 |
$page_url = $params['page_url'];
|
2072 |
|
|
|
2073 |
if($fieldset_id != "embedded") $row->type = $fieldset_id;
|
2074 |
|
2075 |
ob_start();
|
2079 |
$form_attr = array(
|
2080 |
'id' => 'adminForm',
|
2081 |
'name' => 'adminForm',
|
2082 |
+
'class' => WDFMInstance(self::PLUGIN)->prefix . '_display_options wd-form',
|
2083 |
'current_id' => $id,
|
2084 |
'action' => add_query_arg( array('page' => $page, 'current_id' => $id ), $page_url),
|
2085 |
);
|
2102 |
|
2103 |
$buttons = array(
|
2104 |
'save' => array(
|
2105 |
+
'title' => __('Update', WDFMInstance(self::PLUGIN)->prefix),
|
2106 |
'value' => 'save',
|
2107 |
'onclick' => 'fm_apply_options(\'apply_display_options\');',
|
2108 |
'class' => 'button-primary',
|
2109 |
),
|
2110 |
'back' => array(
|
2111 |
+
'title' => __('Back to Form', WDFMInstance(self::PLUGIN)->prefix),
|
2112 |
'value' => 'back',
|
2113 |
'onclick' => 'window.open(\''. $back_url .'\', \'_self\'); return false;',
|
2114 |
'class' => 'button',
|
2128 |
<div class="wd-box-content">
|
2129 |
<span>
|
2130 |
<div class="fm-row fm-form-types">
|
2131 |
+
<label class="wd-label"><?php _e('Form Type', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2132 |
<label>
|
2133 |
<input type="radio" name="form_type" value="embedded" onclick="change_form_type('embedded'); change_hide_show('fm-embedded');"
|
2134 |
<?php echo $row->type == 'embedded' ? 'checked="checked"' : '' ?>>
|
2164 |
<div class="wd-box-section">
|
2165 |
<div class="wd-box-content">
|
2166 |
<span class="wd-group fm-embedded <?php echo $row->type == 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2167 |
+
<label class="wd-label"><?php _e('Form Placement', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2168 |
<div id="fm-embedded-element">
|
2169 |
+
<p><?php _e('Use', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
2170 |
+
<input type="text" value='<?php echo (WDFMInstance(self::PLUGIN)->is_free == 2 ? '[wd_contact_form id="' . $row->form_id . '"]' : '[Form id="' . $row->form_id . '"]'); ?>' onclick="fm_select_value(this)" readonly="readonly" style="width:155px !important;"/>
|
2171 |
+
<p><?php _e('shortcode to display the form.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
2172 |
</div>
|
2173 |
</span>
|
2174 |
<span class="wd-group fm-popover <?php echo $row->type == 'popover' ? 'fm-show' : 'fm-hide' ?>">
|
2175 |
+
<label class="wd-label"><?php _e('Animation Effect', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2176 |
<select id="popover_animate_effect" name="popover_animate_effect">
|
2177 |
<?php
|
2178 |
foreach($animation_effects as $anim_key => $animation_effect){
|
2183 |
</select>
|
2184 |
</span>
|
2185 |
<span class="wd-group fm-popover <?php echo $row->type != 'popover' ? 'fm-hide' : 'fm-show'; ?>">
|
2186 |
+
<label class="wd-label"><?php _e('Loading Delay', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2187 |
<input type="number" name="popover_loading_delay" value="<?php echo $row->popover_loading_delay; ?>" /> seconds
|
2188 |
<div>
|
2189 |
+
<?php _e('Define the amount of time before the form popup appears after the page loads.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2190 |
+
<?php _e('Set 0 for no delay.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2191 |
</div>
|
2192 |
</span>
|
2193 |
<span class="wd-group fm-popover <?php echo $row->type == 'popover' ? 'fm-show' : 'fm-hide' ?>">
|
2194 |
+
<label class="wd-label"><?php _e('Frequency', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2195 |
<input type="number" name="popover_frequency" value="<?php echo $row->popover_frequency; ?>" /> days
|
2196 |
<div>
|
2197 |
+
<?php _e('Display the popup to the same visitor (who has closed the popup/submitted the form) after this period.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2198 |
+
<?php _e('Set the value to 0 to always show.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2199 |
</div>
|
2200 |
</span>
|
2201 |
<span class="wd-group fm-topbar <?php echo $row->type == 'topbar' ? 'fm-show' : 'fm-hide' ?>">
|
2202 |
+
<label class="wd-label"><?php _e('Position', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2203 |
<input type="radio" name="topbar_position" <?php echo $row->topbar_position == 1 ? 'checked="checked"' : '' ?> id="fm_do-topbarpos-1" class="wd-radio" value="1">
|
2204 |
+
<label class="wd-label-radio" for="fm_do-topbarpos-1"><?php _e('Top', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2205 |
<input type="radio" name="topbar_position" <?php echo $row->topbar_position == 0 ? 'checked="checked"' : '' ?> id="fm_do-topbarpos-0" class="wd-radio" value="0">
|
2206 |
+
<label class="wd-label-radio" for="fm_do-topbarpos-0"><?php _e('Bottom', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2207 |
</span>
|
2208 |
<span class="wd-group fm-topbar topbar_remain_top <?php echo $row->type != 'topbar' ? 'fm-hide' : ($row->topbar_position == 1 ? 'fm-show' : 'fm-hide') ?>">
|
2209 |
+
<label class="wd-label"><?php _e('Remain at top when scrolling', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2210 |
<input type="radio" name="topbar_remain_top" <?php echo $row->topbar_remain_top == 1 ? 'checked="checked"' : '' ?> id="fm_do-remaintop-1" class="wd-radio" value="1">
|
2211 |
+
<label class="wd-label-radio" for="fm_do-remaintop-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2212 |
<input type="radio" name="topbar_remain_top" <?php echo $row->topbar_remain_top == 0 ? 'checked="checked"' : '' ?> id="fm_do-remaintop-0" class="wd-radio" value="0">
|
2213 |
+
<label class="wd-label-radio" for="fm_do-remaintop-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2214 |
</span>
|
2215 |
<span class="wd-group fm-topbar <?php echo $row->type == 'topbar' ? 'fm-show' : 'fm-hide' ?>">
|
2216 |
+
<label class="wd-label"><?php _e('Allow Closing the bar', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2217 |
<input type="radio" name="topbar_closing" <?php echo $row->topbar_closing == 1 ? 'checked="checked"' : '' ?> id="fm_do-topbarclosing-1" class="wd-radio" value="1">
|
2218 |
+
<label class="wd-label-radio" for="fm_do-topbarclosing-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2219 |
<input type="radio" name="topbar_closing" <?php echo $row->topbar_closing == 0 ? 'checked="checked"' : '' ?> id="fm_do-topbarclosing-0" class="wd-radio" value="0">
|
2220 |
+
<label class="wd-label-radio" for="fm_do-topbarclosing-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2221 |
</span>
|
2222 |
<span class="wd-group fm-topbar topbar_hide_duration <?php echo $row->type != 'topbar' ? 'fm-hide' : 'fm-show' ?>">
|
2223 |
+
<label class="wd-label"><?php _e('Frequency', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2224 |
<input type="number" name="topbar_hide_duration" value="<?php echo $row->topbar_hide_duration; ?>"/>days
|
2225 |
<div>
|
2226 |
+
<?php _e('Display the topbar to the same visitor (who has closed the popup/submitted the form) after this period.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2227 |
+
<?php _e('Set the value to 0 to always show.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2228 |
</div>
|
2229 |
</span>
|
2230 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2231 |
+
<label class="wd-label"><?php _e('Position', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2232 |
<input type="radio" name="scrollbox_position" <?php echo $row->scrollbox_position == 0 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxposition-0" class="wd-radio" value="0">
|
2233 |
+
<label class="wd-label-radio" for="fm_do-scrollboxposition-0"><?php _e('Left', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2234 |
<input type="radio" name="scrollbox_position" <?php echo $row->scrollbox_position == 1 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxposition-1" class="wd-radio" value="1">
|
2235 |
+
<label class="wd-label-radio" for="fm_do-scrollboxposition-1"><?php _e('Right', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2236 |
</span>
|
2237 |
<span class="wd-group fm-scrollbox <?php echo $row->type != 'scrollbox' ? 'fm-hide' : 'fm-show'; ?>">
|
2238 |
+
<label class="wd-label"><?php _e('Loading Delay', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2239 |
<input type="number" name="scrollbox_loading_delay" value="<?php echo $row->scrollbox_loading_delay; ?>" /> seconds
|
2240 |
<div>
|
2241 |
+
<?php _e('Define the amount of time before the form scrollbox appears after the page loads. Set 0 for no delay.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2242 |
</div>
|
2243 |
</span>
|
2244 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2245 |
+
<label class="wd-label"><?php _e('Frequency', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2246 |
<input type="number" name="scrollbox_hide_duration" value="<?php echo $row->scrollbox_hide_duration; ?>"/>days
|
2247 |
<div>
|
2248 |
+
<?php _e('Display the scrollbox to the same visitor (who has closed the popup/submitted the form) after this period.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2249 |
+
<?php _e('Set the value to 0 to always show.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2250 |
</div>
|
2251 |
</span>
|
2252 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox <?php echo $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2253 |
+
<label class="wd-label"><?php _e('Always show for administrator', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2254 |
<input type="radio" name="show_for_admin" <?php echo $row->show_for_admin == 1 ? 'checked="checked"' : '' ?> id="fm_do-showforadmin-1" class="wd-radio" value="1">
|
2255 |
+
<label class="wd-label-radio" for="fm_do-showforadmin-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2256 |
<input type="radio" name="show_for_admin" <?php echo $row->show_for_admin == 0 ? 'checked="checked"' : '' ?> id="fm_do-showforadmin-0" class="wd-radio" value="0">
|
2257 |
+
<label class="wd-label-radio" for="fm_do-showforadmin-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2258 |
<div>
|
2259 |
+
<?php _e('If this option is enabled, website admins will always see the form.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2260 |
</div>
|
2261 |
</span>
|
2262 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2263 |
+
<label class="wd-label"><?php _e('Trigger Point', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2264 |
<input type="number" name="scrollbox_trigger_point" value="<?php echo $row->scrollbox_trigger_point; ?>"/>%
|
2265 |
<div>
|
2266 |
+
<?php _e('Set the percentage of the page height, where the scrollbox form will appear after scrolling down.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2267 |
</div>
|
2268 |
</span>
|
2269 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2270 |
+
<label class="wd-label"><?php _e('Allow Closing the bar', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2271 |
<input type="radio" name="scrollbox_closing" <?php echo $row->scrollbox_closing == 1 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxclosing-1" class="wd-radio" value="1">
|
2272 |
+
<label class="wd-label-radio" for="fm_do-scrollboxclosing-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2273 |
<input type="radio" name="scrollbox_closing" <?php echo $row->scrollbox_closing == 0 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxclosing-0" class="wd-radio" value="0">
|
2274 |
+
<label class="wd-label-radio" for="fm_do-scrollboxclosing-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2275 |
</span>
|
2276 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2277 |
+
<label class="wd-label"><?php _e('Allow Minimize', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2278 |
<input type="radio" name="scrollbox_minimize" <?php echo $row->scrollbox_minimize == 1 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxminimize-1" class="wd-radio" value="1">
|
2279 |
+
<label class="wd-label-radio" for="fm_do-scrollboxminimize-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2280 |
<input type="radio" name="scrollbox_minimize" <?php echo $row->scrollbox_minimize == 0 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxminimize-0" class="wd-radio" value="0">
|
2281 |
+
<label class="wd-label-radio" for="fm_do-scrollboxminimize-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2282 |
</span>
|
2283 |
<span class="wd-group fm-scrollbox minimize_text <?php echo $row->type == 'scrollbox' && $row->scrollbox_minimize == 1 ? 'fm-show' : 'fm-hide' ?>">
|
2284 |
+
<label class="wd-label"><?php _e('Minimize Text', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2285 |
<input type="text" name="scrollbox_minimize_text" value="<?php echo $row->scrollbox_minimize_text; ?>"/>
|
2286 |
</span>
|
2287 |
<span class="wd-group fm-scrollbox <?php echo $row->type == 'scrollbox' ? 'fm-show' : 'fm-hide' ?>">
|
2288 |
+
<label class="wd-label"><?php _e('Auto Hide', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2289 |
<input type="radio" name="scrollbox_auto_hide" <?php echo $row->scrollbox_auto_hide == 1 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxautohide-1" class="wd-radio" value="1">
|
2290 |
+
<label class="wd-label-radio" for="fm_do-scrollboxautohide-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2291 |
<input type="radio" name="scrollbox_auto_hide" <?php echo $row->scrollbox_auto_hide == 0 ? 'checked="checked"' : '' ?> id="fm_do-scrollboxautohide-0" class="wd-radio" value="0">
|
2292 |
+
<label class="wd-label-radio" for="fm_do-scrollboxautohide-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2293 |
<div>
|
2294 |
+
<?php _e('Hide the scrollbox form again when visitor scrolls back up.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2295 |
</div>
|
2296 |
</span>
|
2297 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox <?php echo $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2298 |
+
<label class="wd-label"><?php _e('Display on', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2299 |
<ul class="pp_display pp_display_on"><?php
|
2300 |
$posts_and_pages = $params['posts_and_pages'];
|
2301 |
$stat_types = array('everything' => 'All', 'home' => 'Homepage', 'archive' => 'Archives');
|
2321 |
</ul>
|
2322 |
</span>
|
2323 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox fm-cat-show <?php echo $row->type != 'embedded' && $show_cats ? 'fm-show' : 'fm-hide' ?>">
|
2324 |
+
<label class="wd-label"><?php _e("Display on these categories' posts", WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2325 |
<ul class="pp_display pp_display_on_categories"><?php
|
2326 |
$categories = $params['categories'];
|
2327 |
$selected_categories = $params['selected_categories'];
|
2341 |
<input type="hidden" name="current_categories" value="<?php echo $current_categories; ?>"/>
|
2342 |
</span>
|
2343 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox fm-posts-show <?php echo (in_array('everything', $selected_types) || in_array('post', $selected_types)) && $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2344 |
+
<label class="wd-label"><?php _e('Display on these posts', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2345 |
<div class="fm-mini-heading">
|
2346 |
+
<?php _e('Click on input area to view the list of posts.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2347 |
+
<?php _e('If left empty the form will appear on all posts.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2348 |
</div>
|
2349 |
+
<p><?php _e('Posts defined below will override all settings above.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
2350 |
<ul class="fm-pp">
|
2351 |
<li class="pp_selected"><?php if($row->posts_include){
|
2352 |
$posts_include = explode(',', $row->posts_include);
|
2371 |
</ul>
|
2372 |
</span>
|
2373 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox fm-pages-show <?php echo (in_array('everything', $selected_types) || in_array('page', $selected_types)) && $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2374 |
+
<label class="wd-label"><?php _e('Display on these pages', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2375 |
<div class="fm-mini-heading">
|
2376 |
+
<?php _e('Click on input area to view the list of pages. ', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2377 |
+
<?php _e('If left empty the form will appear on all pages.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
2378 |
</div>
|
2379 |
+
<p><?php _e('Pages defined below will override all settings above.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
2380 |
<ul class="fm-pp">
|
2381 |
<li class="pp_selected"><?php if($row->pages_include){
|
2382 |
$pages_include = explode(',', $row->pages_include);
|
2400 |
</ul>
|
2401 |
</span>
|
2402 |
<span class="wd-group fm-popover fm-topbar fm-scrollbox <?php echo $row->type != 'embedded' ? 'fm-show' : 'fm-hide' ?>">
|
2403 |
+
<label class="wd-label"><?php _e('Hide on Mobile', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2404 |
<input type="radio" name="hide_mobile" <?php echo $row->hide_mobile == 1 ? 'checked="checked"' : '' ?> id="fm_do-hidemobile-1" class="wd-radio" value="1">
|
2405 |
+
<label class="wd-label-radio" for="fm_do-hidemobile-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2406 |
<input type="radio" name="hide_mobile" <?php echo $row->hide_mobile == 0 ? 'checked="checked"' : '' ?> id="fm_do-hidemobile-0" class="wd-radio" value="0">
|
2407 |
+
<label class="wd-label-radio" for="fm_do-hidemobile-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
2408 |
</span>
|
2409 |
</div>
|
2410 |
</div>
|
admin/views/Options_fm.php
CHANGED
@@ -8,10 +8,10 @@ class FMViewOptions_fmc extends FMAdminView_fmc {
|
|
8 |
* FMViewOptions_fmc constructor.
|
9 |
*/
|
10 |
public function __construct() {
|
11 |
-
wp_enqueue_style('
|
12 |
|
13 |
wp_enqueue_script('jquery');
|
14 |
-
wp_enqueue_script('
|
15 |
}
|
16 |
|
17 |
/**
|
@@ -20,13 +20,13 @@ class FMViewOptions_fmc extends FMAdminView_fmc {
|
|
20 |
public function display($params) {
|
21 |
ob_start();
|
22 |
echo $this->title(array(
|
23 |
-
'title' => __('Options',
|
24 |
'title_class' => 'wd-header',
|
25 |
'add_new_button' => FALSE,
|
26 |
));
|
27 |
$buttons = array(
|
28 |
'save' => array(
|
29 |
-
'title' => __('Save',
|
30 |
'value' => 'save',
|
31 |
'onclick' => 'fm_set_input_value(\'task\', \'save\')',
|
32 |
'class' => 'button-primary',
|
@@ -37,7 +37,7 @@ class FMViewOptions_fmc extends FMAdminView_fmc {
|
|
37 |
// Pass the content to form.
|
38 |
$form_attr = array(
|
39 |
'id' => 'options_form',
|
40 |
-
'action' => add_query_arg(array('page' => 'options' .
|
41 |
);
|
42 |
echo $this->form(ob_get_clean(), $form_attr);
|
43 |
}
|
@@ -48,24 +48,24 @@ class FMViewOptions_fmc extends FMAdminView_fmc {
|
|
48 |
$csv_delimiter = isset($fm_settings['csv_delimiter']) ? $fm_settings['csv_delimiter'] : ',';
|
49 |
$fm_advanced_layout = isset($fm_settings['fm_advanced_layout']) && $fm_settings['fm_advanced_layout'] == '1' ? '1' : '0';
|
50 |
$map_key = isset($fm_settings['map_key']) ? $fm_settings['map_key'] : '';
|
51 |
-
$uninstall_href = add_query_arg( array( 'page' => 'uninstall' .
|
52 |
?>
|
53 |
<div class="wd-table">
|
54 |
<div class="wd-table-col wd-table-col-50 wd-table-col-left">
|
55 |
<div class="wd-box-section">
|
56 |
<div class="wd-box-title">
|
57 |
-
<strong><?php _e('Recaptcha',
|
58 |
</div>
|
59 |
<div class="wd-box-content">
|
60 |
<span class="wd-group">
|
61 |
-
<label class="wd-label" for="public_key"><?php _e('Site key',
|
62 |
<input id="public_key" name="public_key" value="<?php echo $public_key; ?>" type="text" />
|
63 |
</span>
|
64 |
<span class="wd-group">
|
65 |
-
<label class="wd-label" for="private_key"><?php _e('Secret key',
|
66 |
<input id="private_key" name="private_key" value="<?php echo $private_key; ?>" type="text" />
|
67 |
<p class="description">
|
68 |
-
<?php echo sprintf(__('%s for your site from ReCaptcha website and copy the provided here.',
|
69 |
</p>
|
70 |
</span>
|
71 |
<span class="wd-group wd-right">
|
@@ -75,16 +75,16 @@ class FMViewOptions_fmc extends FMAdminView_fmc {
|
|
75 |
</div>
|
76 |
<div class="wd-box-section">
|
77 |
<div class="wd-box-title">
|
78 |
-
<strong><?php _e('Google Maps',
|
79 |
</div>
|
80 |
<div class="wd-box-content">
|
81 |
<span class="wd-group">
|
82 |
-
<label class="wd-label" for="map_key"><?php _e('Map API Key',
|
83 |
<input id="map_key" name="map_key" value="<?php echo $map_key; ?>" type="text" />
|
84 |
<p class="description">
|
85 |
-
<?php echo _e('Get',
|
86 |
-
<a href="https://console.developers.google.com/flows/enableapi?apiid=maps_backend&keyType=CLIENT_SIDE&reusekey=true" target="_blank"><?php _e('Google Map API key',
|
87 |
-
<?php echo _e(' and copy them to this input. Make sure the key does not have restrictions.',
|
88 |
</p>
|
89 |
</span>
|
90 |
</div>
|
@@ -93,25 +93,25 @@ class FMViewOptions_fmc extends FMAdminView_fmc {
|
|
93 |
<div class="wd-table-col wd-table-col-50 wd-table-col-right">
|
94 |
<div class="wd-box-section">
|
95 |
<div class="wd-box-title">
|
96 |
-
<strong><?php _e('Other',
|
97 |
</div>
|
98 |
<div class="wd-box-content">
|
99 |
<span class="wd-group">
|
100 |
-
<label class="wd-label" for="csv_delimiter"><?php _e('CSV Delimiter',
|
101 |
<input id="csv_delimiter" name="csv_delimiter" value="<?php echo $csv_delimiter; ?>" type="text" />
|
102 |
-
<p class="description"><?php _e('This option sets the symbol, which will be used to separate the values in CSV file of form submissions.',
|
103 |
</span>
|
104 |
<span class="wd-group">
|
105 |
-
<label class="wd-label"><?php _e('Enable Advanced Layout',
|
106 |
<input <?php echo checked($fm_advanced_layout, '1'); ?> id="fm_advanced_layout-1" class="wd-radio" value="1" name="fm_advanced_layout" type="radio"/>
|
107 |
-
<label class="wd-label-radio" for="fm_advanced_layout-1"><?php _e('Yes',
|
108 |
<input <?php echo checked($fm_advanced_layout, '0'); ?> id="fm_advanced_layout-0" class="wd-radio" value="0" name="fm_advanced_layout" type="radio"/>
|
109 |
-
<label class="wd-label-radio" for="fm_advanced_layout-0"><?php _e('No',
|
110 |
-
<p class="description"><?php _e('If you wish to build your form with HTML, instead of using Form Maker’s user-friendly interface, you can enable Advanced Layout. It can be accessed from the form editor.',
|
111 |
</span>
|
112 |
<span class="wd-group">
|
113 |
-
<label class="wd-label"><?php echo sprintf(__('Uninstall %s',
|
114 |
-
<a class="button" href="<?php echo $uninstall_href ?>"><?php _e('Uninstall',
|
115 |
</span>
|
116 |
</div>
|
117 |
</div>
|
8 |
* FMViewOptions_fmc constructor.
|
9 |
*/
|
10 |
public function __construct() {
|
11 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-tables');
|
12 |
|
13 |
wp_enqueue_script('jquery');
|
14 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-admin');
|
15 |
}
|
16 |
|
17 |
/**
|
20 |
public function display($params) {
|
21 |
ob_start();
|
22 |
echo $this->title(array(
|
23 |
+
'title' => __('Options', WDFMInstance(self::PLUGIN)->prefix),
|
24 |
'title_class' => 'wd-header',
|
25 |
'add_new_button' => FALSE,
|
26 |
));
|
27 |
$buttons = array(
|
28 |
'save' => array(
|
29 |
+
'title' => __('Save', WDFMInstance(self::PLUGIN)->prefix),
|
30 |
'value' => 'save',
|
31 |
'onclick' => 'fm_set_input_value(\'task\', \'save\')',
|
32 |
'class' => 'button-primary',
|
37 |
// Pass the content to form.
|
38 |
$form_attr = array(
|
39 |
'id' => 'options_form',
|
40 |
+
'action' => add_query_arg(array('page' => 'options' . WDFMInstance(self::PLUGIN)->menu_postfix), 'admin.php'),
|
41 |
);
|
42 |
echo $this->form(ob_get_clean(), $form_attr);
|
43 |
}
|
48 |
$csv_delimiter = isset($fm_settings['csv_delimiter']) ? $fm_settings['csv_delimiter'] : ',';
|
49 |
$fm_advanced_layout = isset($fm_settings['fm_advanced_layout']) && $fm_settings['fm_advanced_layout'] == '1' ? '1' : '0';
|
50 |
$map_key = isset($fm_settings['map_key']) ? $fm_settings['map_key'] : '';
|
51 |
+
$uninstall_href = add_query_arg( array( 'page' => 'uninstall' . WDFMInstance(self::PLUGIN)->menu_postfix), admin_url('admin.php') );
|
52 |
?>
|
53 |
<div class="wd-table">
|
54 |
<div class="wd-table-col wd-table-col-50 wd-table-col-left">
|
55 |
<div class="wd-box-section">
|
56 |
<div class="wd-box-title">
|
57 |
+
<strong><?php _e('Recaptcha', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
58 |
</div>
|
59 |
<div class="wd-box-content">
|
60 |
<span class="wd-group">
|
61 |
+
<label class="wd-label" for="public_key"><?php _e('Site key', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
62 |
<input id="public_key" name="public_key" value="<?php echo $public_key; ?>" type="text" />
|
63 |
</span>
|
64 |
<span class="wd-group">
|
65 |
+
<label class="wd-label" for="private_key"><?php _e('Secret key', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
66 |
<input id="private_key" name="private_key" value="<?php echo $private_key; ?>" type="text" />
|
67 |
<p class="description">
|
68 |
+
<?php echo sprintf(__('%s for your site from ReCaptcha website and copy the provided here.', WDFMInstance(self::PLUGIN)->prefix), '<a href="https://www.google.com/recaptcha/intro/index.html" target="_blank">' . __('Get ReCaptcha Site and Secret Keys', WDFMInstance(self::PLUGIN)->prefix) . '</a>'); ?>
|
69 |
</p>
|
70 |
</span>
|
71 |
<span class="wd-group wd-right">
|
75 |
</div>
|
76 |
<div class="wd-box-section">
|
77 |
<div class="wd-box-title">
|
78 |
+
<strong><?php _e('Google Maps', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
79 |
</div>
|
80 |
<div class="wd-box-content">
|
81 |
<span class="wd-group">
|
82 |
+
<label class="wd-label" for="map_key"><?php _e('Map API Key', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
83 |
<input id="map_key" name="map_key" value="<?php echo $map_key; ?>" type="text" />
|
84 |
<p class="description">
|
85 |
+
<?php echo _e('Get', WDFMInstance(self::PLUGIN)->prefix); ?>
|
86 |
+
<a href="https://console.developers.google.com/flows/enableapi?apiid=maps_backend&keyType=CLIENT_SIDE&reusekey=true" target="_blank"><?php _e('Google Map API key', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
87 |
+
<?php echo _e(' and copy them to this input. Make sure the key does not have restrictions.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
88 |
</p>
|
89 |
</span>
|
90 |
</div>
|
93 |
<div class="wd-table-col wd-table-col-50 wd-table-col-right">
|
94 |
<div class="wd-box-section">
|
95 |
<div class="wd-box-title">
|
96 |
+
<strong><?php _e('Other', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
97 |
</div>
|
98 |
<div class="wd-box-content">
|
99 |
<span class="wd-group">
|
100 |
+
<label class="wd-label" for="csv_delimiter"><?php _e('CSV Delimiter', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
101 |
<input id="csv_delimiter" name="csv_delimiter" value="<?php echo $csv_delimiter; ?>" type="text" />
|
102 |
+
<p class="description"><?php _e('This option sets the symbol, which will be used to separate the values in CSV file of form submissions.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
103 |
</span>
|
104 |
<span class="wd-group">
|
105 |
+
<label class="wd-label"><?php _e('Enable Advanced Layout', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
106 |
<input <?php echo checked($fm_advanced_layout, '1'); ?> id="fm_advanced_layout-1" class="wd-radio" value="1" name="fm_advanced_layout" type="radio"/>
|
107 |
+
<label class="wd-label-radio" for="fm_advanced_layout-1"><?php _e('Yes', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
108 |
<input <?php echo checked($fm_advanced_layout, '0'); ?> id="fm_advanced_layout-0" class="wd-radio" value="0" name="fm_advanced_layout" type="radio"/>
|
109 |
+
<label class="wd-label-radio" for="fm_advanced_layout-0"><?php _e('No', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
110 |
+
<p class="description"><?php _e('If you wish to build your form with HTML, instead of using Form Maker’s user-friendly interface, you can enable Advanced Layout. It can be accessed from the form editor.', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
111 |
</span>
|
112 |
<span class="wd-group">
|
113 |
+
<label class="wd-label"><?php echo sprintf(__('Uninstall %s', WDFMInstance(self::PLUGIN)->prefix), WDFMInstance(self::PLUGIN)->nicename); ?></label>
|
114 |
+
<a class="button" href="<?php echo $uninstall_href ?>"><?php _e('Uninstall', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
115 |
</span>
|
116 |
</div>
|
117 |
</div>
|
admin/views/Pricing_fm.php
ADDED
@@ -0,0 +1,174 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
/**
|
4 |
+
* Class FMViewPricing_fmc
|
5 |
+
*/
|
6 |
+
class FMViewPricing_fmc extends FMAdminView_fmc {
|
7 |
+
/**
|
8 |
+
* FMViewpricing_fm constructor.
|
9 |
+
*/
|
10 |
+
public function __construct() {
|
11 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
12 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-pricing');
|
13 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-admin');
|
14 |
+
}
|
15 |
+
|
16 |
+
public function display( $params = array() ) {
|
17 |
+
$page = $params['page'];
|
18 |
+
$page_url = $params['page_url'];
|
19 |
+
ob_start();
|
20 |
+
echo $this->body($params);
|
21 |
+
// Pass the content to form.
|
22 |
+
$form_attr = array(
|
23 |
+
'id' => WDFMInstance(self::PLUGIN)->prefix . '_pricing',
|
24 |
+
'name' => WDFMInstance(self::PLUGIN)->prefix . '_pricing',
|
25 |
+
'class' => WDFMInstance(self::PLUGIN)->prefix . '_pricing wd-form',
|
26 |
+
'action' => add_query_arg( array('page' => $page, 'task' => 'display'), $page_url),
|
27 |
+
);
|
28 |
+
echo $this->form(ob_get_clean(), $form_attr);
|
29 |
+
}
|
30 |
+
|
31 |
+
/**
|
32 |
+
* Generate page body.
|
33 |
+
*
|
34 |
+
* @return string Body html.
|
35 |
+
*/
|
36 |
+
public function body( $params = array() ) {
|
37 |
+
?>
|
38 |
+
<div class="fm-pricestable-container">
|
39 |
+
<div class="fm-pricestable">
|
40 |
+
<div class="ptFree">
|
41 |
+
<span class="price product_info"><span>$</span>30</span>
|
42 |
+
<p><?php _e('Personal', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
43 |
+
<span class="supp">
|
44 |
+
<strong><?php _e('6 Months', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
45 |
+
<span class="desc_span"><?php _e('You’ll have access to new releases during this period and update plugin to include new features without additional charges.', WDFMInstance(self::PLUGIN)->prefix); ?></span><br>
|
46 |
+
<?php _e('Access to Updates', WDFMInstance(self::PLUGIN)->prefix); ?>
|
47 |
+
</span>
|
48 |
+
<span class="supp">
|
49 |
+
<strong><?php _e('6 Months', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
50 |
+
<span class="desc_span"><?php _e('Get quick answers to all product related questions from our support team.', WDFMInstance(self::PLUGIN)->prefix); ?></span><br>
|
51 |
+
<?php _e('Premium Support', WDFMInstance(self::PLUGIN)->prefix); ?>
|
52 |
+
</span>
|
53 |
+
<span class="supp product_info">
|
54 |
+
<strong><?php _e('1 Domain', WDFMInstance(self::PLUGIN)->prefix); ?></strong><br>
|
55 |
+
<?php _e('Support', WDFMInstance(self::PLUGIN)->prefix); ?>
|
56 |
+
</span>
|
57 |
+
<ul class="circles">
|
58 |
+
<li><div></div></li>
|
59 |
+
<li><div></div></li>
|
60 |
+
<li><div></div></li>
|
61 |
+
</ul>
|
62 |
+
<span class="supp product_info"><?php _e('Unlimited Forms/Fields', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
63 |
+
<span class="supp product_info"><?php _e('40+ Field Types', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
64 |
+
<span class="supp product_info"><?php _e('Multi-Page Forms', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
65 |
+
<span class="supp product_info"><?php _e('Paypal Integration', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
66 |
+
<span class="supp product_info"><?php _e('File Upload field', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
67 |
+
<span class="supp product_info"><?php _e('Fully Customizable Themes', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
68 |
+
<span>
|
69 |
+
<a href="https://web-dorado.com/index.php?option=com_wdsubscriptions&view=checkoutpage&tmpl=component&id=69&offerId=117" target="_blank"><?php _e('Buy now', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
70 |
+
</span>
|
71 |
+
</div>
|
72 |
+
<div class="ptPersonal">
|
73 |
+
<span class="price product_info"><span>$</span>45</span>
|
74 |
+
<p><?php _e('Business', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
75 |
+
<span class="supp">
|
76 |
+
<strong><?php _e('1 Year', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
77 |
+
<span class="desc_span"><?php _e('You’ll have access to new releases during this period and update plugin to include new features without additional charges.', WDFMInstance(self::PLUGIN)->prefix); ?></span><br>
|
78 |
+
<?php _e('Access to Updates', WDFMInstance(self::PLUGIN)->prefix); ?>
|
79 |
+
</span>
|
80 |
+
<span class="supp">
|
81 |
+
<strong><?php _e('1 Year', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
82 |
+
<span class="desc_span"><?php _e('Get quick answers to all product related questions from our support team.', WDFMInstance(self::PLUGIN)->prefix); ?></span><br>
|
83 |
+
<?php _e('Premium Support', WDFMInstance(self::PLUGIN)->prefix); ?>
|
84 |
+
</span>
|
85 |
+
<span class="supp product_info">
|
86 |
+
<strong><?php _e('3 Domains', WDFMInstance(self::PLUGIN)->prefix); ?></strong><br>
|
87 |
+
<?php _e('Support', WDFMInstance(self::PLUGIN)->prefix); ?>
|
88 |
+
</span>
|
89 |
+
<ul class="circles">
|
90 |
+
<li><div></div></li>
|
91 |
+
<li><div></div></li>
|
92 |
+
<li><div></div></li>
|
93 |
+
</ul>
|
94 |
+
<span class="supp product_info"><?php _e('Unlimited Forms/Fields', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
95 |
+
<span class="supp product_info"><?php _e('40+ Field Types', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
96 |
+
<span class="supp product_info"><?php _e('Multi-Page Forms', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
97 |
+
<span class="supp product_info"><?php _e('Paypal Integration', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
98 |
+
<span class="supp product_info"><?php _e('File Upload field', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
99 |
+
<span class="supp product_info"><?php _e('Fully Customizable Themes', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
100 |
+
<span>
|
101 |
+
<a href="https://web-dorado.com/index.php?option=com_wdsubscriptions&view=checkoutpage&tmpl=component&id=70&offerId=117" target="_blank"><?php _e('Buy now', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
102 |
+
</span>
|
103 |
+
</div>
|
104 |
+
<div class="ptBusiness">
|
105 |
+
<span class="price product_info"><span>$</span>60</span>
|
106 |
+
<p><?php _e('Developer', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
107 |
+
<span class="supp">
|
108 |
+
<strong><?php _e('1 Year', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
109 |
+
<span class="desc_span"><?php _e('You’ll have access to new releases during this period and update plugin to include new features without additional charges.', WDFMInstance(self::PLUGIN)->prefix); ?></span><br>
|
110 |
+
<?php _e('Access to Updates', WDFMInstance(self::PLUGIN)->prefix); ?>
|
111 |
+
</span>
|
112 |
+
<span class="supp"><strong><?php _e('1 Year', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
113 |
+
<span class="desc_span"><?php _e('Get quick answers to all product related questions from our support team.', WDFMInstance(self::PLUGIN)->prefix); ?></span><br>
|
114 |
+
<?php _e('Premium Support', WDFMInstance(self::PLUGIN)->prefix); ?>
|
115 |
+
</span>
|
116 |
+
<span class="supp product_info">
|
117 |
+
<strong><?php _e('Unlimited Domains', WDFMInstance(self::PLUGIN)->prefix); ?></strong><br>
|
118 |
+
<?php _e('Support', WDFMInstance(self::PLUGIN)->prefix); ?>
|
119 |
+
</span>
|
120 |
+
<ul class="circles">
|
121 |
+
<li><div></div></li>
|
122 |
+
<li><div></div></li>
|
123 |
+
<li><div></div></li>
|
124 |
+
</ul>
|
125 |
+
<span class="supp product_info"><?php _e('Unlimited Forms/Fields', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
126 |
+
<span class="supp product_info"><?php _e('40+ Field Types', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
127 |
+
<span class="supp product_info"><?php _e('Multi-Page Forms', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
128 |
+
<span class="supp product_info"><?php _e('Paypal Integration', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
129 |
+
<span class="supp product_info"><?php _e('File Upload field', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
130 |
+
<span class="supp product_info"><?php _e('Fully Customizable Themes', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
131 |
+
<span>
|
132 |
+
<a href="https://web-dorado.com/index.php?option=com_wdsubscriptions&view=checkoutpage&tmpl=component&id=71&offerId=117" target="_blank"><?php _e('Buy now', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
133 |
+
</span>
|
134 |
+
</div>
|
135 |
+
<div class="ptDeveloper">
|
136 |
+
<span class="special_offer"><?php _e('Special offer', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
137 |
+
<span class="price product_info"><span>$</span>99</span>
|
138 |
+
<p class="save_money"><span><?php _e('Save', WDFMInstance(self::PLUGIN)->prefix); ?> $735</span></p>
|
139 |
+
<p><?php _e('Form Maker Premium', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
140 |
+
<span class="supp">
|
141 |
+
<strong><?php _e('+12 Add-ons', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
142 |
+
<span class="desc_span"><?php _e('Tune up Form Maker with powerful add-ons: PDF Integration, Mailchimp, Export/Import, Conditional Emails, Registration,etc.', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
143 |
+
</span>
|
144 |
+
<span class="supp product_info">
|
145 |
+
<strong><?php _e('+ All Our 50 WordPress Premium Plugins', WDFMInstance(self::PLUGIN)->prefix); ?></strong>
|
146 |
+
</span>
|
147 |
+
<span class="supp product_info"><?php _e('Photo Gallery, Slider, Event Calendar & etc.', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
148 |
+
<ul class="circles">
|
149 |
+
<li><div></div></li>
|
150 |
+
<li><div></div></li>
|
151 |
+
<li><div></div></li>
|
152 |
+
</ul>
|
153 |
+
<span class="supp">
|
154 |
+
<?php _e('6 Months Access to Updates', WDFMInstance(self::PLUGIN)->prefix); ?>
|
155 |
+
<span class="desc_span"><?php _e('You’ll have access to new releases during this period and update plugins to include new features without additional charges.', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
156 |
+
</span>
|
157 |
+
<span class="supp"><?php _e('6 Months Premium Support', WDFMInstance(self::PLUGIN)->prefix); ?>
|
158 |
+
<span class="desc_span"><?php _e('Get quick answers to all product related questions from our support team.', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
159 |
+
</span>
|
160 |
+
<span class="supp product_info"><?php _e('Unlimited Domains Support', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
161 |
+
<span>
|
162 |
+
<a href="https://web-dorado.com/index.php?option=com_wdsubscriptions&task=buy&id=117&from_id=71&wd_button_clicks=insert_into" target="_blank"><?php _e('Buy now', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
163 |
+
</span>
|
164 |
+
</div>
|
165 |
+
</div>
|
166 |
+
<div class="fm-prices-more">
|
167 |
+
<div>
|
168 |
+
<?php _e('Learn more about Form Maker plugin.', WDFMInstance(self::PLUGIN)->prefix); ?> <a href="https://web-dorado.com/files/fromFormMaker.php" target="_blank"><?php _e('Learn More', WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
169 |
+
</div>
|
170 |
+
</div>
|
171 |
+
</div>
|
172 |
+
<?php
|
173 |
+
}
|
174 |
+
}
|
admin/views/Submissions_fm.php
CHANGED
@@ -8,9 +8,9 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
8 |
public function __construct( $model ) {
|
9 |
$this->model = $model;
|
10 |
wp_enqueue_style('thickbox');
|
11 |
-
wp_enqueue_style('
|
12 |
-
wp_enqueue_style('
|
13 |
-
wp_enqueue_style('
|
14 |
wp_enqueue_style('jquery.fancybox');
|
15 |
|
16 |
wp_enqueue_script('thickbox');
|
@@ -24,14 +24,14 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
24 |
wp_enqueue_script('jquery-ui-core');
|
25 |
wp_enqueue_script('jquery-ui-datepicker');
|
26 |
if ( function_exists('wp_add_inline_script') ) { // Since Wordpress 4.5.0
|
27 |
-
wp_add_inline_script('jquery-ui-datepicker',
|
28 |
}
|
29 |
else {
|
30 |
-
echo '<script>' .
|
31 |
}
|
32 |
-
wp_enqueue_script('
|
33 |
-
wp_enqueue_script('
|
34 |
-
wp_enqueue_script('
|
35 |
wp_enqueue_script('jquery.fancybox.pack');
|
36 |
}
|
37 |
|
@@ -40,6 +40,9 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
40 |
* @param $params
|
41 |
*/
|
42 |
public function forms( $params ) {
|
|
|
|
|
|
|
43 |
$id = $params['id'];
|
44 |
$page = $params['page'];
|
45 |
$page_title = $params['page_title'];
|
@@ -57,15 +60,15 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
57 |
<?php echo $this->saelect_form( array('id' => $id, 'forms' => $forms, 'page' => $page, 'page_url' => $page_url) ); ?>
|
58 |
</div>
|
59 |
<div class="fm-export-tools">
|
60 |
-
<?php $blocked_ips_link = add_query_arg(array( 'page' => 'blocked_ips' .
|
61 |
-
<a class="button" href="<?php echo $blocked_ips_link; ?>" target="_blank"><?php echo _e('Blocked IPs',
|
62 |
</div>
|
63 |
</div>
|
64 |
<?php if( !$id ) { ?>
|
65 |
<table class="wp-list-table widefat fixed striped posts">
|
66 |
<body id="the-list">
|
67 |
<tr class="no-items">
|
68 |
-
<td class="colspanchange" colspan="0"><?php _e('Please select a form to view submissions',
|
69 |
</tr>
|
70 |
</body>
|
71 |
</table>
|
@@ -85,10 +88,10 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
85 |
|
86 |
// Pass the content to form.
|
87 |
$form_attr = array(
|
88 |
-
// 'id' =>
|
89 |
'id' => 'admin_form',
|
90 |
-
'name' =>
|
91 |
-
'class' =>
|
92 |
'action' => add_query_arg( array('page' => $page, 'task' => 'display', 'current_id' => $id ), $page_url),
|
93 |
);
|
94 |
echo $this->form(ob_get_clean(), $form_attr);
|
@@ -164,22 +167,22 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
164 |
<div class="fm-reports">
|
165 |
<div class="fm-tools-button">
|
166 |
<div class="fm-total_entries"><?php echo $statistics["total_entries"]; ?></div>
|
167 |
-
<?php echo _e('Entries',
|
168 |
</div>
|
169 |
<div class="fm-tools-button">
|
170 |
<div class="fm-total_rate"><?php echo $statistics["conversion_rate"]; ?></div>
|
171 |
-
<?php echo _e('Conversion Rate',
|
172 |
</div>
|
173 |
<div class="fm-tools-button">
|
174 |
<div class="fm-total_views"><?php echo $statistics["total_views"] ? $statistics["total_views"] : 0; ?></div>
|
175 |
-
<?php echo _e('Views',
|
176 |
</div>
|
177 |
</div>
|
178 |
<div class="fm-export-tools">
|
179 |
-
<?php $blocked_ips_link = add_query_arg(array( 'page' => 'blocked_ips' .
|
180 |
-
<a class="button" href="<?php echo $blocked_ips_link; ?>" target="_blank"><?php echo _e('Blocked IPs',
|
181 |
-
<button class="button" onclick="export_submissions('csv', 0); return false;"><?php echo _e('Export to CSV',
|
182 |
-
<button class="button" onclick="export_submissions('xml', 0); return false;"><?php echo _e('Export to XML',
|
183 |
</div>
|
184 |
</div>
|
185 |
<div class="tablenav top">
|
@@ -187,12 +190,12 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
187 |
echo $this->bulk_actions($actions);
|
188 |
?>
|
189 |
<div class="alignleft actions fm-bulk-actions">
|
190 |
-
<input type="button" class="button action" onclick="toggleChBDiv(true); return false;" value="<?php echo _e('Add/Remove Columns',
|
191 |
<input type="hidden" name="hide_label_list" value="">
|
192 |
-
<button type="button" class="button action" onclick="show_hide_filter(); return false;"><span class="show-filter <?php echo !($is_search) ? '' : 'hide'?>"><?php echo __('Show Filters',
|
193 |
<span class="search_reset_button <?php echo ($is_search) ? '' : 'hide'; ?>">
|
194 |
-
<input type="button" class="button action" onclick="fm_form_submit(event, 'admin_form'); return false;" value="<?php echo _e('Search',
|
195 |
-
<input type="button" class="button action <?php echo ($is_search) ? '' : 'hide'; ?>" onclick="remove_all(); fm_set_input_value('order_by', 'group_id'); fm_set_input_value('asc_or_desc', 'desc'); fm_form_submit(event, 'admin_form'); return false;" value="<?php echo _e('Reset',
|
196 |
</span>
|
197 |
</div>
|
198 |
<?php
|
@@ -210,7 +213,7 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
210 |
<thead>
|
211 |
<tr class="fm_table_head">
|
212 |
<td id="cb" class="column-cb check-column">
|
213 |
-
<label class="screen-reader-text" for="cb-select-all-1"><?php _e('Select all',
|
214 |
<input type="checkbox" id="check_all">
|
215 |
</td>
|
216 |
<th id="submitid_fc" class="<?php if ( $order_by == "group_id" ) {
|
@@ -218,11 +221,11 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
218 |
}
|
219 |
else {
|
220 |
echo $oder_class_default;
|
221 |
-
} ?> col_id" <?php echo $style_id; ?> data-colname="<?php _e('ID',
|
222 |
<a href="" class="sub_id" onclick="fm_set_input_value('order_by', 'group_id');
|
223 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'group_id' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
224 |
fm_form_submit(event, 'admin_form')">
|
225 |
-
<span><?php echo _e('ID',
|
226 |
<span class="sorting-indicator"></span>
|
227 |
</a>
|
228 |
</th>
|
@@ -231,11 +234,11 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
231 |
}
|
232 |
else {
|
233 |
echo $oder_class_default;
|
234 |
-
} ?>" <?php echo $style_date; ?> data-colname="<?php _e('Submit date',
|
235 |
<a href="" onclick="fm_set_input_value('order_by', 'date');
|
236 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'date' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
237 |
fm_form_submit(event, 'admin_form')">
|
238 |
-
<span><?php _e('Submit date',
|
239 |
<span class="sorting-indicator"></span>
|
240 |
</a>
|
241 |
</th>
|
@@ -244,11 +247,11 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
244 |
}
|
245 |
else {
|
246 |
echo $oder_class_default;
|
247 |
-
} ?>" <?php echo $style_ip; ?> data-colname="<?php _e('Submitter\'s IP',
|
248 |
<a href="" onclick="fm_set_input_value('order_by', 'ip');
|
249 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'ip' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
250 |
fm_form_submit(event, 'admin_form')">
|
251 |
-
<span><?php _e('Submitter\'s IP',
|
252 |
<span class="sorting-indicator"></span>
|
253 |
</a>
|
254 |
</th>
|
@@ -257,11 +260,11 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
257 |
}
|
258 |
else {
|
259 |
echo $oder_class_default;
|
260 |
-
|
261 |
<a href="" onclick="fm_set_input_value('order_by', 'display_name');
|
262 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'display_name' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
263 |
fm_form_submit(event, 'admin_form')">
|
264 |
-
<span><?php _e('Submitter\'s Username',
|
265 |
<span class="sorting-indicator"></span>
|
266 |
</a>
|
267 |
</th>
|
@@ -270,11 +273,11 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
270 |
}
|
271 |
else {
|
272 |
echo $oder_class_default;
|
273 |
-
} ?>" <?php echo $style_useremail; ?> data-colname="<?php _e('Submitter\'s Email Address',
|
274 |
<a href="" onclick="fm_set_input_value('order_by', 'user_email');
|
275 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'user_email' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
276 |
fm_form_submit(event, 'admin_form')">
|
277 |
-
<span><?php _e('Submitter\'s Email Address',
|
278 |
<span class="sorting-indicator"></span>
|
279 |
</a>
|
280 |
</th>
|
@@ -323,9 +326,9 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
323 |
}
|
324 |
}
|
325 |
if( $stripe_paypal ) { ?>
|
326 |
-
<th id="payment_info_fc" class="column-autor payment_info_fc" <?php echo $style_payment_info; ?> data-colname="<?php _e('Payment Info',
|
327 |
<?php } ?>
|
328 |
-
</tr>
|
329 |
<tr id="fm-fields-filter" style="display: none;">
|
330 |
<th></th>
|
331 |
<th class="submitid_fc" <?php echo $style_id; ?> >
|
@@ -453,13 +456,13 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
453 |
<th class="check-column">
|
454 |
<input type="checkbox" id="check_<?php echo $data->group_id; ?>" name="check[<?php echo $data->group_id; ?>]">
|
455 |
</th>
|
456 |
-
<td id="submitid_fc" class="col-id" data-colname="<?php _e('ID',
|
457 |
<a href="" onclick="fm_set_input_value('task', 'edit'); fm_set_input_value('current_id',<?php echo $data->group_id; ?>); fm_form_submit(event, 'admin_form');"><?php echo $data->group_id; ?></a>
|
458 |
</td>
|
459 |
-
<td class="column-primary col-submit-date" data-colname="<?php _e('Submit date',
|
460 |
<?php
|
461 |
$view_url = add_query_arg( array(
|
462 |
-
'action' => 'FormMakerSubmits' .
|
463 |
'group_id' => $data->group_id,
|
464 |
'form_id' => $form_id,
|
465 |
'width' => '600',
|
@@ -473,7 +476,7 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
473 |
$unblock_url = add_query_arg( array( 'task' => 'unblock_ip', 'current_id' => $data->group_id, 'form_id' => $form_id ), $page_url );
|
474 |
|
475 |
$ip_infoin_popup_url = add_query_arg( array(
|
476 |
-
'action' => 'FormMakerIpinfoinPopup' .
|
477 |
'data_ip' => $data->ip,
|
478 |
'width' => '450',
|
479 |
'height' => '300',
|
@@ -483,33 +486,33 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
483 |
?>
|
484 |
<p><strong><a href="<?php echo $edit_url; ?>" target="_blank"><?php echo $data->date; ?></a></strong></p>
|
485 |
<div class="row-actions">
|
486 |
-
<span><a href="<?php echo $view_url; ?>" class="thickbox thickbox-preview" title="<?php _e("View submission",
|
487 |
-
<span><a href="<?php echo $edit_url; ?>" target="_blank" title="<?php _e("Edit submission",
|
488 |
<?php if ( $pdf_data && isset($pdf_data[$group_id_s[$www]]) ){ ?>
|
489 |
-
<span><a href="<?php echo site_url() . '/' . $pdf_data[$group_id_s[$www]]; ?>" download ><?php _e('Download PDF',
|
490 |
<?php } ?>
|
491 |
-
<span class="trash"><a href="<?php echo $delete_url; ?>" title="<?php _e("Edit submission",
|
492 |
|
493 |
-
<button class="toggle-row" type="button"><span class="screen-reader-text"><?php _e("Show more details",
|
494 |
</div>
|
495 |
</td>
|
496 |
-
<td class="submitterip_fc sub-align" id="submitterip_fc" <?php echo $style_ip; ?> data-colname="<?php _e('Show submitter information',
|
497 |
-
<p><a class="thickbox-preview" href="<?php echo $ip_infoin_popup_url; ?>" title="<?php _e("Show submitter information",
|
498 |
<div class="row-actions">
|
499 |
<?php if( !in_array($data->ip, $blocked_ips) ){ ?>
|
500 |
-
<span><a href="<?php echo $block_url; ?>" title="<?php _e("Block IP",
|
501 |
<?php } else { ?>
|
502 |
-
<span><a href="<?php echo $unblock_url; ?>" title="<?php _e("Unblock IP ",
|
503 |
<?php } ?>
|
504 |
</div>
|
505 |
</td>
|
506 |
-
<td class="table_large_col submitterusername_fc sub-align" id="submitterusername_fc" <?php echo $style_username; ?> data-colname="<?php _e('Submitter\'s Username',
|
507 |
<p><?php echo $username; ?></p>
|
508 |
</td>
|
509 |
-
<td class="table_large_col submitteremail_fc sub-align" id="submitteremail_fc" <?php echo $style_useremail; ?> data-colname="<?php _e('Submitter\'s Email Address',
|
510 |
<p><?php echo $useremail; ?></p>
|
511 |
</td>
|
512 |
-
<?php
|
513 |
for ( $h = 0; $h < $m; $h++ ) {
|
514 |
$ispaypal = false;
|
515 |
if ( $sorted_label_types[$h] == 'type_stripe' ) {
|
@@ -526,21 +529,21 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
526 |
if ( strpos($temp[$g]->element_value, "***map***") ) {
|
527 |
$map_params = explode('***map***', $temp[$g]->element_value);
|
528 |
?>
|
529 |
-
<td class="table_large_col <?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('Show on Map',
|
530 |
<a class="thickbox-preview" href="<?php echo add_query_arg(array(
|
531 |
-
'action' => 'FormMakerMapEditinPopup' .
|
532 |
'long' => $map_params[0],
|
533 |
'lat' => $map_params[1],
|
534 |
'width' => '620',
|
535 |
'height' => '550',
|
536 |
'TB_iframe' => '1',
|
537 |
-
), admin_url('admin-ajax.php')); ?>" title="<?php _e("Show on Map",
|
538 |
</td>
|
539 |
<?php
|
540 |
}
|
541 |
elseif ( strpos($temp[$g]->element_value, "*@@url@@*") ) {
|
542 |
?>
|
543 |
-
<td class="<?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('URL',
|
544 |
<?php
|
545 |
$new_files = explode("*@@url@@*", $temp[$g]->element_value);
|
546 |
foreach ( $new_files as $new_file ) {
|
@@ -561,19 +564,19 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
561 |
$view_star_rating_array = $this->model->view_for_star_rating($temp[$g]->element_value, $temp[$g]->element_label);
|
562 |
$stars = $view_star_rating_array[0];
|
563 |
?>
|
564 |
-
<td align="center" class="<?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('Star rating',
|
565 |
<?php
|
566 |
}
|
567 |
elseif ( strpos($temp[$g]->element_value, "***matrix***") ) {
|
568 |
?>
|
569 |
-
<td class="table_large_col <?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('Matrix',
|
570 |
<a class="thickbox-preview" href="<?php echo add_query_arg(array(
|
571 |
-
'action' => 'show_matrix' .
|
572 |
'matrix_params' => str_replace('#', '%23', urlencode($temp[$g]->element_value)),
|
573 |
'width' => '620',
|
574 |
'height' => '550',
|
575 |
'TB_iframe' => '1',
|
576 |
-
), admin_url('admin-ajax.php')); ?>" title="<?php _e("Show Matrix",
|
577 |
</td>
|
578 |
<?php
|
579 |
}
|
@@ -588,12 +591,12 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
588 |
$view_grading_array = $this->model->view_for_grading($temp[$g]->element_value);
|
589 |
$items = $view_grading_array[0];
|
590 |
?>
|
591 |
-
<td class="<?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('Grading',
|
592 |
<p><?php echo $items; ?></p>
|
593 |
</td>
|
594 |
<?php
|
595 |
}
|
596 |
-
else {
|
597 |
// check is paypal status
|
598 |
if($sorted_labels_id[$h] == 0 && !empty($temp[$g]->element_value) ) {
|
599 |
$ispaypal = true;
|
@@ -616,7 +619,7 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
616 |
?>
|
617 |
<td class="<?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php echo !empty($label_name_ids[$sorted_labels_id[$h]]) ? $label_name_ids[$sorted_labels_id[$h]] : ''; ?>">
|
618 |
<p><?php echo $temp[$g]->element_value; ?>
|
619 |
-
<span style="color:#2DA068;">( Verified <img src="<?php echo
|
620 |
</p>
|
621 |
</td>
|
622 |
<?php }
|
@@ -650,15 +653,15 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
650 |
}
|
651 |
if ( $ispaypal ) {
|
652 |
?>
|
653 |
-
<td class="payment_info_fc sub-align" id="payment_info_fc" <?php echo $style_payment_info; ?> data-colname="<?php _e('Paypal information',
|
654 |
<a class="thickbox-preview" href="<?php echo add_query_arg(array(
|
655 |
-
'action' => 'paypal_info' .
|
656 |
'id' => $i,
|
657 |
'width' => '600',
|
658 |
'height' => '500',
|
659 |
'TB_iframe' => '1',
|
660 |
-
), admin_url('admin-ajax.php')); ?>" title="<?php _e("Paypal information",
|
661 |
-
<img src="<?php echo
|
662 |
</a>
|
663 |
</td>
|
664 |
<?php
|
@@ -670,7 +673,7 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
670 |
}
|
671 |
}
|
672 |
else {
|
673 |
-
echo
|
674 |
}
|
675 |
?>
|
676 |
</tbody>
|
@@ -687,15 +690,15 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
687 |
}
|
688 |
}
|
689 |
if ( $is_stats ) {
|
690 |
-
$ajax_nonce = wp_create_nonce(
|
691 |
-
?>
|
692 |
<div class="fm-statistics">
|
693 |
-
<h2><?php echo _e('Statistics',
|
694 |
<table class="stats">
|
695 |
<tr>
|
696 |
<td colspan="3">
|
697 |
<select id="sorted_label_key">
|
698 |
-
<option value=""><?php echo _e('- Select -',
|
699 |
<?php
|
700 |
foreach ( $sorted_label_types as $key => $sorted_label_type ) {
|
701 |
if ( $sorted_label_type == "type_checkbox" || $sorted_label_type == "type_radio" || $sorted_label_type == "type_own_select" || $sorted_label_type == "type_country" || $sorted_label_type == "type_paypal_select" || $sorted_label_type == "type_paypal_radio" || $sorted_label_type == "type_paypal_checkbox" || $sorted_label_type == "type_paypal_shipping" ) {
|
@@ -706,28 +709,28 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
706 |
}
|
707 |
?>
|
708 |
</select>
|
709 |
-
<p class="fm_error_sorted_label_key"><?php echo _e('Please select the field!',
|
710 |
</td>
|
711 |
</tr>
|
712 |
<tr>
|
713 |
<td>
|
714 |
-
<label style="margin-left: 7px;"><?php echo _e('Date From:',
|
715 |
</td>
|
716 |
<td>
|
717 |
<input class="inputbox" type="text" name="startstats" id="startstats" size="9" maxlength="9" />
|
718 |
-
<?php echo _e('To:',
|
719 |
<input class="inputbox" type="text" name="endstats" id="endstats" size="9" maxlength="9" />
|
720 |
</td>
|
721 |
<td>
|
722 |
<span class="fm-div_stats-loading spinner"></span>
|
723 |
-
<button class="button" onclick="show_stats(); return false;"><?php _e('Show',
|
724 |
</td>
|
725 |
</tr>
|
726 |
</table>
|
727 |
<div id="div_stats"></div>
|
728 |
</div>
|
729 |
-
<script>
|
730 |
-
show_stats_url = "<?php echo add_query_arg( array('action' => 'get_stats' .
|
731 |
</script>
|
732 |
<?php
|
733 |
}
|
@@ -798,10 +801,10 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
798 |
}
|
799 |
</script>
|
800 |
<div id="ChBDiv">
|
801 |
-
<p class="add-col-header"><?php _e('Select columns',
|
802 |
<div class="fm_check_labels">
|
803 |
<input type="checkbox" <?php echo ( !$lists['hide_label_list'] ) ? 'checked="checked"' : ''; ?> onclick="clickLabChBAll(this)" id="ChBAll" />
|
804 |
-
<label for="ChBAll"><?php _e('All',
|
805 |
</div>
|
806 |
<?php
|
807 |
foreach ( $templabels as $key => $curlabel ) {
|
@@ -832,13 +835,13 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
832 |
?>
|
833 |
<div class="fm_check_labels">
|
834 |
<input type="checkbox" onclick="clickLabChB('payment_info', this)" id="fm_check_payment_info" <?php echo (strpos($lists['hide_label_list'], '@payment_info@') === FALSE) ? 'checked="checked"' : ''; ?> />
|
835 |
-
<label for="fm_check_payment_info"><?php _e('Payment info',
|
836 |
</div>
|
837 |
<?php
|
838 |
}
|
839 |
?>
|
840 |
<div class="done-cont">
|
841 |
-
<button onclick="toggleChBDiv(false); return false;" class="button button-primary"><?php _e('Done',
|
842 |
</div>
|
843 |
</div>
|
844 |
<script type="text/javascript">
|
@@ -853,7 +856,7 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
853 |
url: "<?php echo add_query_arg(array(
|
854 |
'form_id' => $form_id,
|
855 |
'send_header' => 0,
|
856 |
-
), admin_url('admin-ajax.php')); ?>&action=generete_" + type + "<?php echo
|
857 |
data: {search_labels: '<?php echo $searched_ids; ?>', verified_emails: jQuery('#verified_emails').val()},
|
858 |
beforeSend: function () {
|
859 |
if (<?php echo $subs_count; ?> >=
|
@@ -891,7 +894,7 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
891 |
window.location = "<?php echo add_query_arg(array(
|
892 |
'form_id' => $form_id,
|
893 |
'send_header' => 1,
|
894 |
-
), admin_url('admin-ajax.php')); ?>&action=generete_" + type + "<?php echo
|
895 |
}
|
896 |
}
|
897 |
});
|
@@ -1006,9 +1009,9 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
1006 |
<table class="adminlist">
|
1007 |
<thead>
|
1008 |
<tr>
|
1009 |
-
<th width="20%"><?php _e('Choices',
|
1010 |
-
<th><?php _e('Percentage',
|
1011 |
-
<th width="10%" style="text-align: left;"><?php _e('Count',
|
1012 |
</tr>
|
1013 |
</thead>
|
1014 |
<?php
|
@@ -1048,14 +1051,14 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
1048 |
if ( $unanswered ) {
|
1049 |
?>
|
1050 |
<tr>
|
1051 |
-
<td colspan="2" style="text-align:right; color: #000;"><?php _e('Unanswered',
|
1052 |
<td><strong style="margin-left:10px;"><?php echo $unanswered; ?></strong></td>
|
1053 |
</tr>
|
1054 |
<?php
|
1055 |
}
|
1056 |
?>
|
1057 |
<tr>
|
1058 |
-
<td colspan="2" style="text-align:right; color: #000;"><strong><?php _e('Total',
|
1059 |
<td><strong style="margin-left:10px;"><?php echo $all; ?></strong></td>
|
1060 |
</tr>
|
1061 |
</table>
|
@@ -1065,6 +1068,9 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
1065 |
}
|
1066 |
|
1067 |
public function edit( $params ) {
|
|
|
|
|
|
|
1068 |
$form = $params['form'];
|
1069 |
$current_id = $params['current_id'];
|
1070 |
$rows = $params['rows'];
|
@@ -1077,43 +1083,43 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
1077 |
<div class="wrap">
|
1078 |
<?php
|
1079 |
// Generate message container by message id or directly by message.
|
1080 |
-
$message_id =
|
1081 |
-
$message =
|
1082 |
-
echo
|
1083 |
?>
|
1084 |
-
<form action="admin.php?page=submissions<?php echo
|
1085 |
<div class="wd-page-title wd-header">
|
1086 |
-
<h1 class="wp-heading-inline"><?php _e('Edit Submission',
|
1087 |
</div>
|
1088 |
<div class="wd-buttons">
|
1089 |
-
<button class="button button-primary button-large" onclick="fm_set_input_value('task', 'save'); fm_set_input_value('current_id', <?php echo $current_id; ?>); fm_form_submit(event, 'adminForm');"><?php _e('Save',
|
1090 |
</div>
|
1091 |
<div class="wd-table">
|
1092 |
<div class="wd-table-col wd-table-col-50 wd-table-col-left">
|
1093 |
<div class="wd-box-section">
|
1094 |
<div class="wd-box-content non-editable">
|
1095 |
<div class="wd-group">
|
1096 |
-
<label class="wd-label" for="id"><?php _e('Form',
|
1097 |
<span><?php echo $form->title; ?></span>
|
1098 |
</div>
|
1099 |
<div class="wd-group">
|
1100 |
-
<label class="wd-label" for="id"><?php _e('ID',
|
1101 |
<span><?php echo $rows[0]->group_id; ?></span>
|
1102 |
</div>
|
1103 |
<div class="wd-group">
|
1104 |
-
<label class="wd-label" for="id"><?php _e('Date',
|
1105 |
<span><?php echo $rows[0]->date; ?></span>
|
1106 |
</div>
|
1107 |
<div class="wd-group">
|
1108 |
-
<label class="wd-label" for="id"><?php _e('IP',
|
1109 |
<span><?php echo $rows[0]->ip; ?></span>
|
1110 |
</div>
|
1111 |
<div class="wd-group">
|
1112 |
-
<label class="wd-label" for="id"><?php _e('Submitter\'s Username',
|
1113 |
<span><?php echo $username; ?></span>
|
1114 |
</div>
|
1115 |
<div class="wd-group">
|
1116 |
-
<label class="wd-label" for="id"><?php _e('Submitter\'s Email Address',
|
1117 |
<span><?php echo $useremail; ?></span>
|
1118 |
</div>
|
1119 |
</div>
|
@@ -1148,27 +1154,27 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
1148 |
<label class="wd-label"><?php echo $labels_name[$key]; ?></label>
|
1149 |
<select name="submission_0" id="submission_0">
|
1150 |
<option value=""></option>
|
1151 |
-
<option value="Canceled"><?php echo _e('Canceled',
|
1152 |
-
<option value="Cleared"><?php echo _e('Cleared',
|
1153 |
-
<option value="Cleared by payment review"><?php echo _e('Cleared by payment review',
|
1154 |
-
<option value="Completed"><?php echo _e('Completed',
|
1155 |
-
<option value="Denied"><?php echo _e('Denied',
|
1156 |
-
<option value="Failed"><?php echo _e('Failed',
|
1157 |
-
<option value="Held"><?php echo _e('Held',
|
1158 |
-
<option value="In progress"><?php echo _e('In progress',
|
1159 |
-
<option value="On hold"><?php echo _e('On hold',
|
1160 |
-
<option value="Paid"><?php echo _e('Paid',
|
1161 |
-
<option value="Partially refunded"><?php echo _e('Partially refunded',
|
1162 |
-
<option value="Pending verification"><?php echo _e('Pending verification',
|
1163 |
-
<option value="Placed"><?php echo _e('Placed',
|
1164 |
-
<option value="Processing"><?php echo _e('Processing',
|
1165 |
-
<option value="Refunded"><?php echo _e('Refunded',
|
1166 |
-
<option value="Refused"><?php echo _e('Refused',
|
1167 |
-
<option value="Removed"><?php echo _e('Removed',
|
1168 |
-
<option value="Returned"><?php echo _e('Returned',
|
1169 |
-
<option value="Reversed"><?php echo _e('Reversed',
|
1170 |
-
<option value="Temporary hold"><?php echo _e('Temporary hold',
|
1171 |
-
<option value="Unclaimed"><?php echo _e('Unclaimed',
|
1172 |
</select>
|
1173 |
<script>
|
1174 |
var element = document.getElementById("submission_0");
|
@@ -1278,14 +1284,14 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
1278 |
</div>
|
1279 |
</div>
|
1280 |
</div>
|
1281 |
-
<?php wp_nonce_field(
|
1282 |
<input type="hidden" name="option" value="com_formmaker" />
|
1283 |
<input type="hidden" id="current_id" name="current_id" value="<?php echo $rows[0]->group_id; ?>" />
|
1284 |
<input type="hidden" name="form_id" value="<?php echo $rows[0]->form_id; ?>" />
|
1285 |
<input type="hidden" name="date" value="<?php echo $rows[0]->date; ?>" />
|
1286 |
<input type="hidden" name="ip" value="<?php echo $rows[0]->ip; ?>" />
|
1287 |
<input type="hidden" id="task" name="task" value="" />
|
1288 |
-
<input type="hidden" value="<?php echo
|
1289 |
</form>
|
1290 |
</div>
|
1291 |
<?php
|
@@ -1301,7 +1307,7 @@ class FMViewSubmissions_fmc extends FMAdminView_fmc {
|
|
1301 |
$page_url = $params['page_url'];
|
1302 |
?>
|
1303 |
<select name="form_id" id="form_id">
|
1304 |
-
<option value="0"><?php _e('- Select a form -',
|
1305 |
<?php
|
1306 |
foreach ( $params['forms'] as $form ) {
|
1307 |
$selected = ( $form->id == $params['id'] ) ? 'selected="selected"' : '';
|
8 |
public function __construct( $model ) {
|
9 |
$this->model = $model;
|
10 |
wp_enqueue_style('thickbox');
|
11 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-tables');
|
12 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
13 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-jquery-ui');
|
14 |
wp_enqueue_style('jquery.fancybox');
|
15 |
|
16 |
wp_enqueue_script('thickbox');
|
24 |
wp_enqueue_script('jquery-ui-core');
|
25 |
wp_enqueue_script('jquery-ui-datepicker');
|
26 |
if ( function_exists('wp_add_inline_script') ) { // Since Wordpress 4.5.0
|
27 |
+
wp_add_inline_script('jquery-ui-datepicker', WDW_FM_Library(self::PLUGIN)->localize_ui_datepicker());
|
28 |
}
|
29 |
else {
|
30 |
+
echo '<script>' . WDW_FM_Library(self::PLUGIN)->localize_ui_datepicker() . '</script>';
|
31 |
}
|
32 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-admin');
|
33 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-manage');
|
34 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-submissions');
|
35 |
wp_enqueue_script('jquery.fancybox.pack');
|
36 |
}
|
37 |
|
40 |
* @param $params
|
41 |
*/
|
42 |
public function forms( $params ) {
|
43 |
+
// TODO: Change this function to standard.
|
44 |
+
echo $this->topbar();
|
45 |
+
|
46 |
$id = $params['id'];
|
47 |
$page = $params['page'];
|
48 |
$page_title = $params['page_title'];
|
60 |
<?php echo $this->saelect_form( array('id' => $id, 'forms' => $forms, 'page' => $page, 'page_url' => $page_url) ); ?>
|
61 |
</div>
|
62 |
<div class="fm-export-tools">
|
63 |
+
<?php $blocked_ips_link = add_query_arg(array( 'page' => 'blocked_ips' . WDFMInstance(self::PLUGIN)->menu_postfix ), $page_url); ?>
|
64 |
+
<a class="button" href="<?php echo $blocked_ips_link; ?>" target="_blank"><?php echo _e('Blocked IPs', WDFMInstance(self::PLUGIN)->prefix);?></a>
|
65 |
</div>
|
66 |
</div>
|
67 |
<?php if( !$id ) { ?>
|
68 |
<table class="wp-list-table widefat fixed striped posts">
|
69 |
<body id="the-list">
|
70 |
<tr class="no-items">
|
71 |
+
<td class="colspanchange" colspan="0"><?php _e('Please select a form to view submissions', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
72 |
</tr>
|
73 |
</body>
|
74 |
</table>
|
88 |
|
89 |
// Pass the content to form.
|
90 |
$form_attr = array(
|
91 |
+
// 'id' => WDFMInstance(self::PLUGIN)->prefix . '_submissions',
|
92 |
'id' => 'admin_form',
|
93 |
+
'name' => WDFMInstance(self::PLUGIN)->prefix . '_submissions',
|
94 |
+
'class' => WDFMInstance(self::PLUGIN)->prefix . '_submissions wd-form',
|
95 |
'action' => add_query_arg( array('page' => $page, 'task' => 'display', 'current_id' => $id ), $page_url),
|
96 |
);
|
97 |
echo $this->form(ob_get_clean(), $form_attr);
|
167 |
<div class="fm-reports">
|
168 |
<div class="fm-tools-button">
|
169 |
<div class="fm-total_entries"><?php echo $statistics["total_entries"]; ?></div>
|
170 |
+
<?php echo _e('Entries', WDFMInstance(self::PLUGIN)->prefix);?>
|
171 |
</div>
|
172 |
<div class="fm-tools-button">
|
173 |
<div class="fm-total_rate"><?php echo $statistics["conversion_rate"]; ?></div>
|
174 |
+
<?php echo _e('Conversion Rate', WDFMInstance(self::PLUGIN)->prefix);?>
|
175 |
</div>
|
176 |
<div class="fm-tools-button">
|
177 |
<div class="fm-total_views"><?php echo $statistics["total_views"] ? $statistics["total_views"] : 0; ?></div>
|
178 |
+
<?php echo _e('Views', WDFMInstance(self::PLUGIN)->prefix);?>
|
179 |
</div>
|
180 |
</div>
|
181 |
<div class="fm-export-tools">
|
182 |
+
<?php $blocked_ips_link = add_query_arg(array( 'page' => 'blocked_ips' . WDFMInstance(self::PLUGIN)->menu_postfix ), $page_url); ?>
|
183 |
+
<a class="button" href="<?php echo $blocked_ips_link; ?>" target="_blank"><?php echo _e('Blocked IPs', WDFMInstance(self::PLUGIN)->prefix);?></a>
|
184 |
+
<button class="button" onclick="export_submissions('csv', 0); return false;"><?php echo _e('Export to CSV', WDFMInstance(self::PLUGIN)->prefix);?></button>
|
185 |
+
<button class="button" onclick="export_submissions('xml', 0); return false;"><?php echo _e('Export to XML', WDFMInstance(self::PLUGIN)->prefix);?></button>
|
186 |
</div>
|
187 |
</div>
|
188 |
<div class="tablenav top">
|
190 |
echo $this->bulk_actions($actions);
|
191 |
?>
|
192 |
<div class="alignleft actions fm-bulk-actions">
|
193 |
+
<input type="button" class="button action" onclick="toggleChBDiv(true); return false;" value="<?php echo _e('Add/Remove Columns', WDFMInstance(self::PLUGIN)->prefix);?>">
|
194 |
<input type="hidden" name="hide_label_list" value="">
|
195 |
+
<button type="button" class="button action" onclick="show_hide_filter(); return false;"><span class="show-filter <?php echo !($is_search) ? '' : 'hide'?>"><?php echo __('Show Filters', WDFMInstance(self::PLUGIN)->prefix); ?></span> <span class="hide-filter <?php echo !($is_search) ? 'hide' : 'show'?>" ><?php echo __('Hide Filters', WDFMInstance(self::PLUGIN)->prefix);?></span></button>
|
196 |
<span class="search_reset_button <?php echo ($is_search) ? '' : 'hide'; ?>">
|
197 |
+
<input type="button" class="button action" onclick="fm_form_submit(event, 'admin_form'); return false;" value="<?php echo _e('Search', WDFMInstance(self::PLUGIN)->prefix);?>">
|
198 |
+
<input type="button" class="button action <?php echo ($is_search) ? '' : 'hide'; ?>" onclick="remove_all(); fm_set_input_value('order_by', 'group_id'); fm_set_input_value('asc_or_desc', 'desc'); fm_form_submit(event, 'admin_form'); return false;" value="<?php echo _e('Reset', WDFMInstance(self::PLUGIN)->prefix);?>">
|
199 |
</span>
|
200 |
</div>
|
201 |
<?php
|
213 |
<thead>
|
214 |
<tr class="fm_table_head">
|
215 |
<td id="cb" class="column-cb check-column">
|
216 |
+
<label class="screen-reader-text" for="cb-select-all-1"><?php _e('Select all', WDFMInstance(self::PLUGIN)->prefix);?></label>
|
217 |
<input type="checkbox" id="check_all">
|
218 |
</td>
|
219 |
<th id="submitid_fc" class="<?php if ( $order_by == "group_id" ) {
|
221 |
}
|
222 |
else {
|
223 |
echo $oder_class_default;
|
224 |
+
} ?> col_id" <?php echo $style_id; ?> data-colname="<?php _e('ID', WDFMInstance(self::PLUGIN)->prefix);?>">
|
225 |
<a href="" class="sub_id" onclick="fm_set_input_value('order_by', 'group_id');
|
226 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'group_id' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
227 |
fm_form_submit(event, 'admin_form')">
|
228 |
+
<span><?php echo _e('ID', WDFMInstance(self::PLUGIN)->prefix);?></span>
|
229 |
<span class="sorting-indicator"></span>
|
230 |
</a>
|
231 |
</th>
|
234 |
}
|
235 |
else {
|
236 |
echo $oder_class_default;
|
237 |
+
} ?>" <?php echo $style_date; ?> data-colname="<?php _e('Submit date', WDFMInstance(self::PLUGIN)->prefix);?>">
|
238 |
<a href="" onclick="fm_set_input_value('order_by', 'date');
|
239 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'date' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
240 |
fm_form_submit(event, 'admin_form')">
|
241 |
+
<span><?php _e('Submit date', WDFMInstance(self::PLUGIN)->prefix);?></span>
|
242 |
<span class="sorting-indicator"></span>
|
243 |
</a>
|
244 |
</th>
|
247 |
}
|
248 |
else {
|
249 |
echo $oder_class_default;
|
250 |
+
} ?>" <?php echo $style_ip; ?> data-colname="<?php _e('Submitter\'s IP', WDFMInstance(self::PLUGIN)->prefix);?>">
|
251 |
<a href="" onclick="fm_set_input_value('order_by', 'ip');
|
252 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'ip' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
253 |
fm_form_submit(event, 'admin_form')">
|
254 |
+
<span><?php _e('Submitter\'s IP', WDFMInstance(self::PLUGIN)->prefix);?></span>
|
255 |
<span class="sorting-indicator"></span>
|
256 |
</a>
|
257 |
</th>
|
260 |
}
|
261 |
else {
|
262 |
echo $oder_class_default;
|
263 |
+
} ?>" <?php echo $style_username; ?> data-colname="<?php _e('Submitter\'s Username', WDFMInstance(self::PLUGIN)->prefix);?>">
|
264 |
<a href="" onclick="fm_set_input_value('order_by', 'display_name');
|
265 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'display_name' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
266 |
fm_form_submit(event, 'admin_form')">
|
267 |
+
<span><?php _e('Submitter\'s Username', WDFMInstance(self::PLUGIN)->prefix);?></span>
|
268 |
<span class="sorting-indicator"></span>
|
269 |
</a>
|
270 |
</th>
|
273 |
}
|
274 |
else {
|
275 |
echo $oder_class_default;
|
276 |
+
} ?>" <?php echo $style_useremail; ?> data-colname="<?php _e('Submitter\'s Email Address', WDFMInstance(self::PLUGIN)->prefix);?>">
|
277 |
<a href="" onclick="fm_set_input_value('order_by', 'user_email');
|
278 |
fm_set_input_value('asc_or_desc', '<?php echo(($order_by == 'user_email' && $asc_or_desc == 'asc') ? 'desc' : 'asc'); ?>');
|
279 |
fm_form_submit(event, 'admin_form')">
|
280 |
+
<span><?php _e('Submitter\'s Email Address', WDFMInstance(self::PLUGIN)->prefix);?></span>
|
281 |
<span class="sorting-indicator"></span>
|
282 |
</a>
|
283 |
</th>
|
326 |
}
|
327 |
}
|
328 |
if( $stripe_paypal ) { ?>
|
329 |
+
<th id="payment_info_fc" class="column-autor payment_info_fc" <?php echo $style_payment_info; ?> data-colname="<?php _e('Payment Info', WDFMInstance(self::PLUGIN)->prefix); ?>"><?php _e('Payment Info', WDFMInstance(self::PLUGIN)->prefix); ?></th>
|
330 |
<?php } ?>
|
331 |
+
</tr>
|
332 |
<tr id="fm-fields-filter" style="display: none;">
|
333 |
<th></th>
|
334 |
<th class="submitid_fc" <?php echo $style_id; ?> >
|
456 |
<th class="check-column">
|
457 |
<input type="checkbox" id="check_<?php echo $data->group_id; ?>" name="check[<?php echo $data->group_id; ?>]">
|
458 |
</th>
|
459 |
+
<td id="submitid_fc" class="col-id" data-colname="<?php _e('ID', WDFMInstance(self::PLUGIN)->prefix);?>" <?php echo $style_id; ?>>
|
460 |
<a href="" onclick="fm_set_input_value('task', 'edit'); fm_set_input_value('current_id',<?php echo $data->group_id; ?>); fm_form_submit(event, 'admin_form');"><?php echo $data->group_id; ?></a>
|
461 |
</td>
|
462 |
+
<td class="column-primary col-submit-date" data-colname="<?php _e('Submit date', WDFMInstance(self::PLUGIN)->prefix);?>" <?php echo $style_date; ?>>
|
463 |
<?php
|
464 |
$view_url = add_query_arg( array(
|
465 |
+
'action' => 'FormMakerSubmits' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
466 |
'group_id' => $data->group_id,
|
467 |
'form_id' => $form_id,
|
468 |
'width' => '600',
|
476 |
$unblock_url = add_query_arg( array( 'task' => 'unblock_ip', 'current_id' => $data->group_id, 'form_id' => $form_id ), $page_url );
|
477 |
|
478 |
$ip_infoin_popup_url = add_query_arg( array(
|
479 |
+
'action' => 'FormMakerIpinfoinPopup' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
480 |
'data_ip' => $data->ip,
|
481 |
'width' => '450',
|
482 |
'height' => '300',
|
486 |
?>
|
487 |
<p><strong><a href="<?php echo $edit_url; ?>" target="_blank"><?php echo $data->date; ?></a></strong></p>
|
488 |
<div class="row-actions">
|
489 |
+
<span><a href="<?php echo $view_url; ?>" class="thickbox thickbox-preview" title="<?php _e("View submission", WDFMInstance(self::PLUGIN)->prefix); ?>"><?php _e('View', WDFMInstance(self::PLUGIN)->prefix); ?></a> |</span>
|
490 |
+
<span><a href="<?php echo $edit_url; ?>" target="_blank" title="<?php _e("Edit submission", WDFMInstance(self::PLUGIN)->prefix); ?>"><?php _e('Edit', WDFMInstance(self::PLUGIN)->prefix); ?></a> |</span>
|
491 |
<?php if ( $pdf_data && isset($pdf_data[$group_id_s[$www]]) ){ ?>
|
492 |
+
<span><a href="<?php echo site_url() . '/' . $pdf_data[$group_id_s[$www]]; ?>" download ><?php _e('Download PDF', WDFMInstance(self::PLUGIN)->prefix); ?></a> |</span>
|
493 |
<?php } ?>
|
494 |
+
<span class="trash"><a href="<?php echo $delete_url; ?>" title="<?php _e("Edit submission", WDFMInstance(self::PLUGIN)->prefix); ?>" onclick="if (!confirm('<?php echo addslashes(__('Do you want to delete selected item?', WDFMInstance(self::PLUGIN)->prefix)); ?>')) {return false;}"><?php _e('Delete', WDFMInstance(self::PLUGIN)->prefix); ?></a></span>
|
495 |
|
496 |
+
<button class="toggle-row" type="button"><span class="screen-reader-text"><?php _e("Show more details", WDFMInstance(self::PLUGIN)->prefix); ?></span></button>
|
497 |
</div>
|
498 |
</td>
|
499 |
+
<td class="submitterip_fc sub-align" id="submitterip_fc" <?php echo $style_ip; ?> data-colname="<?php _e('Show submitter information', WDFMInstance(self::PLUGIN)->prefix);?>">
|
500 |
+
<p><a class="thickbox-preview" href="<?php echo $ip_infoin_popup_url; ?>" title="<?php _e("Show submitter information", WDFMInstance(self::PLUGIN)->prefix); ?>" <?php echo (!in_array($data->ip, $blocked_ips)) ? '' : 'style="color: #FF0000;"'; ?>><?php echo $data->ip; ?></a></p>
|
501 |
<div class="row-actions">
|
502 |
<?php if( !in_array($data->ip, $blocked_ips) ){ ?>
|
503 |
+
<span><a href="<?php echo $block_url; ?>" title="<?php _e("Block IP", WDFMInstance(self::PLUGIN)->prefix); ?>"><?php _e('Block IP', WDFMInstance(self::PLUGIN)->prefix); ?></a></span>
|
504 |
<?php } else { ?>
|
505 |
+
<span><a href="<?php echo $unblock_url; ?>" title="<?php _e("Unblock IP ", WDFMInstance(self::PLUGIN)->prefix); ?>"><?php _e('Unblock IP', WDFMInstance(self::PLUGIN)->prefix); ?></a></span>
|
506 |
<?php } ?>
|
507 |
</div>
|
508 |
</td>
|
509 |
+
<td class="table_large_col submitterusername_fc sub-align" id="submitterusername_fc" <?php echo $style_username; ?> data-colname="<?php _e('Submitter\'s Username', WDFMInstance(self::PLUGIN)->prefix);?>">
|
510 |
<p><?php echo $username; ?></p>
|
511 |
</td>
|
512 |
+
<td class="table_large_col submitteremail_fc sub-align" id="submitteremail_fc" <?php echo $style_useremail; ?> data-colname="<?php _e('Submitter\'s Email Address', WDFMInstance(self::PLUGIN)->prefix);?>">
|
513 |
<p><?php echo $useremail; ?></p>
|
514 |
</td>
|
515 |
+
<?php
|
516 |
for ( $h = 0; $h < $m; $h++ ) {
|
517 |
$ispaypal = false;
|
518 |
if ( $sorted_label_types[$h] == 'type_stripe' ) {
|
529 |
if ( strpos($temp[$g]->element_value, "***map***") ) {
|
530 |
$map_params = explode('***map***', $temp[$g]->element_value);
|
531 |
?>
|
532 |
+
<td class="table_large_col <?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('Show on Map', WDFMInstance(self::PLUGIN)->prefix);?>">
|
533 |
<a class="thickbox-preview" href="<?php echo add_query_arg(array(
|
534 |
+
'action' => 'FormMakerMapEditinPopup' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
535 |
'long' => $map_params[0],
|
536 |
'lat' => $map_params[1],
|
537 |
'width' => '620',
|
538 |
'height' => '550',
|
539 |
'TB_iframe' => '1',
|
540 |
+
), admin_url('admin-ajax.php')); ?>" title="<?php _e("Show on Map", WDFMInstance(self::PLUGIN)->prefix); ?>"><?php _e("Show on Map", WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
541 |
</td>
|
542 |
<?php
|
543 |
}
|
544 |
elseif ( strpos($temp[$g]->element_value, "*@@url@@*") ) {
|
545 |
?>
|
546 |
+
<td class="<?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('URL', WDFMInstance(self::PLUGIN)->prefix);?>">
|
547 |
<?php
|
548 |
$new_files = explode("*@@url@@*", $temp[$g]->element_value);
|
549 |
foreach ( $new_files as $new_file ) {
|
564 |
$view_star_rating_array = $this->model->view_for_star_rating($temp[$g]->element_value, $temp[$g]->element_label);
|
565 |
$stars = $view_star_rating_array[0];
|
566 |
?>
|
567 |
+
<td align="center" class="<?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('Star rating', WDFMInstance(self::PLUGIN)->prefix);?>"><?php echo $stars; ?></td>
|
568 |
<?php
|
569 |
}
|
570 |
elseif ( strpos($temp[$g]->element_value, "***matrix***") ) {
|
571 |
?>
|
572 |
+
<td class="table_large_col <?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('Matrix', WDFMInstance(self::PLUGIN)->prefix);?>">
|
573 |
<a class="thickbox-preview" href="<?php echo add_query_arg(array(
|
574 |
+
'action' => 'show_matrix' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
575 |
'matrix_params' => str_replace('#', '%23', urlencode($temp[$g]->element_value)),
|
576 |
'width' => '620',
|
577 |
'height' => '550',
|
578 |
'TB_iframe' => '1',
|
579 |
+
), admin_url('admin-ajax.php')); ?>" title="<?php _e("Show Matrix", WDFMInstance(self::PLUGIN)->prefix); ?>"><?php _e("Show Matrix", WDFMInstance(self::PLUGIN)->prefix); ?></a>
|
580 |
</td>
|
581 |
<?php
|
582 |
}
|
591 |
$view_grading_array = $this->model->view_for_grading($temp[$g]->element_value);
|
592 |
$items = $view_grading_array[0];
|
593 |
?>
|
594 |
+
<td class="<?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php _e('Grading', WDFMInstance(self::PLUGIN)->prefix);?>">
|
595 |
<p><?php echo $items; ?></p>
|
596 |
</td>
|
597 |
<?php
|
598 |
}
|
599 |
+
else {
|
600 |
// check is paypal status
|
601 |
if($sorted_labels_id[$h] == 0 && !empty($temp[$g]->element_value) ) {
|
602 |
$ispaypal = true;
|
619 |
?>
|
620 |
<td class="<?php echo $sorted_labels_id[$h]; ?>_fc sub-align" id="<?php echo $sorted_labels_id[$h]; ?>_fc" <?php echo $styleStr; ?> data-colname="<?php echo !empty($label_name_ids[$sorted_labels_id[$h]]) ? $label_name_ids[$sorted_labels_id[$h]] : ''; ?>">
|
621 |
<p><?php echo $temp[$g]->element_value; ?>
|
622 |
+
<span style="color:#2DA068;">( Verified <img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url . '/images/verified.png'; ?>" /> )</span>
|
623 |
</p>
|
624 |
</td>
|
625 |
<?php }
|
653 |
}
|
654 |
if ( $ispaypal ) {
|
655 |
?>
|
656 |
+
<td class="payment_info_fc sub-align" id="payment_info_fc" <?php echo $style_payment_info; ?> data-colname="<?php _e('Paypal information', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
657 |
<a class="thickbox-preview" href="<?php echo add_query_arg(array(
|
658 |
+
'action' => 'paypal_info' . WDFMInstance(self::PLUGIN)->plugin_postfix,
|
659 |
'id' => $i,
|
660 |
'width' => '600',
|
661 |
'height' => '500',
|
662 |
'TB_iframe' => '1',
|
663 |
+
), admin_url('admin-ajax.php')); ?>" title="<?php _e("Paypal information", WDFMInstance(self::PLUGIN)->prefix); ?>">
|
664 |
+
<img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url . '/images/info.png'; ?>" />
|
665 |
</a>
|
666 |
</td>
|
667 |
<?php
|
673 |
}
|
674 |
}
|
675 |
else {
|
676 |
+
echo WDW_FM_Library(self::PLUGIN)->no_items('submissions');
|
677 |
}
|
678 |
?>
|
679 |
</tbody>
|
690 |
}
|
691 |
}
|
692 |
if ( $is_stats ) {
|
693 |
+
$ajax_nonce = wp_create_nonce( WDFMInstance(self::PLUGIN)->nonce );
|
694 |
+
?>
|
695 |
<div class="fm-statistics">
|
696 |
+
<h2><?php echo _e('Statistics', WDFMInstance(self::PLUGIN)->prefix);?></h2>
|
697 |
<table class="stats">
|
698 |
<tr>
|
699 |
<td colspan="3">
|
700 |
<select id="sorted_label_key">
|
701 |
+
<option value=""><?php echo _e('- Select -', WDFMInstance(self::PLUGIN)->prefix);?></option>
|
702 |
<?php
|
703 |
foreach ( $sorted_label_types as $key => $sorted_label_type ) {
|
704 |
if ( $sorted_label_type == "type_checkbox" || $sorted_label_type == "type_radio" || $sorted_label_type == "type_own_select" || $sorted_label_type == "type_country" || $sorted_label_type == "type_paypal_select" || $sorted_label_type == "type_paypal_radio" || $sorted_label_type == "type_paypal_checkbox" || $sorted_label_type == "type_paypal_shipping" ) {
|
709 |
}
|
710 |
?>
|
711 |
</select>
|
712 |
+
<p class="fm_error_sorted_label_key"><?php echo _e('Please select the field!', WDFMInstance(self::PLUGIN)->prefix);?></p>
|
713 |
</td>
|
714 |
</tr>
|
715 |
<tr>
|
716 |
<td>
|
717 |
+
<label style="margin-left: 7px;"><?php echo _e('Date From:', WDFMInstance(self::PLUGIN)->prefix);?></label>
|
718 |
</td>
|
719 |
<td>
|
720 |
<input class="inputbox" type="text" name="startstats" id="startstats" size="9" maxlength="9" />
|
721 |
+
<?php echo _e('To:', WDFMInstance(self::PLUGIN)->prefix);?>
|
722 |
<input class="inputbox" type="text" name="endstats" id="endstats" size="9" maxlength="9" />
|
723 |
</td>
|
724 |
<td>
|
725 |
<span class="fm-div_stats-loading spinner"></span>
|
726 |
+
<button class="button" onclick="show_stats(); return false;"><?php _e('Show', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
727 |
</td>
|
728 |
</tr>
|
729 |
</table>
|
730 |
<div id="div_stats"></div>
|
731 |
</div>
|
732 |
+
<script>
|
733 |
+
show_stats_url = "<?php echo add_query_arg( array('action' => 'get_stats' . WDFMInstance(self::PLUGIN)->plugin_postfix, 'task' => 'show_stats', 'current_id' => $form_id ), $page_url); ?>";
|
734 |
</script>
|
735 |
<?php
|
736 |
}
|
801 |
}
|
802 |
</script>
|
803 |
<div id="ChBDiv">
|
804 |
+
<p class="add-col-header"><?php _e('Select columns', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
805 |
<div class="fm_check_labels">
|
806 |
<input type="checkbox" <?php echo ( !$lists['hide_label_list'] ) ? 'checked="checked"' : ''; ?> onclick="clickLabChBAll(this)" id="ChBAll" />
|
807 |
+
<label for="ChBAll"><?php _e('All', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
808 |
</div>
|
809 |
<?php
|
810 |
foreach ( $templabels as $key => $curlabel ) {
|
835 |
?>
|
836 |
<div class="fm_check_labels">
|
837 |
<input type="checkbox" onclick="clickLabChB('payment_info', this)" id="fm_check_payment_info" <?php echo (strpos($lists['hide_label_list'], '@payment_info@') === FALSE) ? 'checked="checked"' : ''; ?> />
|
838 |
+
<label for="fm_check_payment_info"><?php _e('Payment info', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
839 |
</div>
|
840 |
<?php
|
841 |
}
|
842 |
?>
|
843 |
<div class="done-cont">
|
844 |
+
<button onclick="toggleChBDiv(false); return false;" class="button button-primary"><?php _e('Done', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
845 |
</div>
|
846 |
</div>
|
847 |
<script type="text/javascript">
|
856 |
url: "<?php echo add_query_arg(array(
|
857 |
'form_id' => $form_id,
|
858 |
'send_header' => 0,
|
859 |
+
), admin_url('admin-ajax.php')); ?>&action=generete_" + type + "<?php echo WDFMInstance(self::PLUGIN)->plugin_postfix; ?>&limitstart=" + limit,
|
860 |
data: {search_labels: '<?php echo $searched_ids; ?>', verified_emails: jQuery('#verified_emails').val()},
|
861 |
beforeSend: function () {
|
862 |
if (<?php echo $subs_count; ?> >=
|
894 |
window.location = "<?php echo add_query_arg(array(
|
895 |
'form_id' => $form_id,
|
896 |
'send_header' => 1,
|
897 |
+
), admin_url('admin-ajax.php')); ?>&action=generete_" + type + "<?php echo WDFMInstance(self::PLUGIN)->plugin_postfix; ?>&limitstart=" + limit;
|
898 |
}
|
899 |
}
|
900 |
});
|
1009 |
<table class="adminlist">
|
1010 |
<thead>
|
1011 |
<tr>
|
1012 |
+
<th width="20%"><?php _e('Choices', WDFMInstance(self::PLUGIN)->prefix); ?></th>
|
1013 |
+
<th><?php _e('Percentage', WDFMInstance(self::PLUGIN)->prefix); ?></th>
|
1014 |
+
<th width="10%" style="text-align: left;"><?php _e('Count', WDFMInstance(self::PLUGIN)->prefix); ?></th>
|
1015 |
</tr>
|
1016 |
</thead>
|
1017 |
<?php
|
1051 |
if ( $unanswered ) {
|
1052 |
?>
|
1053 |
<tr>
|
1054 |
+
<td colspan="2" style="text-align:right; color: #000;"><?php _e('Unanswered', WDFMInstance(self::PLUGIN)->prefix); ?></td>
|
1055 |
<td><strong style="margin-left:10px;"><?php echo $unanswered; ?></strong></td>
|
1056 |
</tr>
|
1057 |
<?php
|
1058 |
}
|
1059 |
?>
|
1060 |
<tr>
|
1061 |
+
<td colspan="2" style="text-align:right; color: #000;"><strong><?php _e('Total', WDFMInstance(self::PLUGIN)->prefix); ?></strong></td>
|
1062 |
<td><strong style="margin-left:10px;"><?php echo $all; ?></strong></td>
|
1063 |
</tr>
|
1064 |
</table>
|
1068 |
}
|
1069 |
|
1070 |
public function edit( $params ) {
|
1071 |
+
// TODO: Change this function to standard.
|
1072 |
+
echo $this->topbar();
|
1073 |
+
|
1074 |
$form = $params['form'];
|
1075 |
$current_id = $params['current_id'];
|
1076 |
$rows = $params['rows'];
|
1083 |
<div class="wrap">
|
1084 |
<?php
|
1085 |
// Generate message container by message id or directly by message.
|
1086 |
+
$message_id = WDW_FM_Library(self::PLUGIN)->get('message', 0);
|
1087 |
+
$message = WDW_FM_Library(self::PLUGIN)->get('msg', '');
|
1088 |
+
echo WDW_FM_Library(self::PLUGIN)->message_id($message_id, $message);
|
1089 |
?>
|
1090 |
+
<form action="admin.php?page=submissions<?php echo WDFMInstance(self::PLUGIN)->menu_postfix; ?>" method="post" id="adminForm" name="adminForm" class="form_maker_submissions_edit wd-form">
|
1091 |
<div class="wd-page-title wd-header">
|
1092 |
+
<h1 class="wp-heading-inline"><?php _e('Edit Submission', WDFMInstance(self::PLUGIN)->prefix); ?></h1>
|
1093 |
</div>
|
1094 |
<div class="wd-buttons">
|
1095 |
+
<button class="button button-primary button-large" onclick="fm_set_input_value('task', 'save'); fm_set_input_value('current_id', <?php echo $current_id; ?>); fm_form_submit(event, 'adminForm');"><?php _e('Save', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
1096 |
</div>
|
1097 |
<div class="wd-table">
|
1098 |
<div class="wd-table-col wd-table-col-50 wd-table-col-left">
|
1099 |
<div class="wd-box-section">
|
1100 |
<div class="wd-box-content non-editable">
|
1101 |
<div class="wd-group">
|
1102 |
+
<label class="wd-label" for="id"><?php _e('Form', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1103 |
<span><?php echo $form->title; ?></span>
|
1104 |
</div>
|
1105 |
<div class="wd-group">
|
1106 |
+
<label class="wd-label" for="id"><?php _e('ID', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1107 |
<span><?php echo $rows[0]->group_id; ?></span>
|
1108 |
</div>
|
1109 |
<div class="wd-group">
|
1110 |
+
<label class="wd-label" for="id"><?php _e('Date', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1111 |
<span><?php echo $rows[0]->date; ?></span>
|
1112 |
</div>
|
1113 |
<div class="wd-group">
|
1114 |
+
<label class="wd-label" for="id"><?php _e('IP', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1115 |
<span><?php echo $rows[0]->ip; ?></span>
|
1116 |
</div>
|
1117 |
<div class="wd-group">
|
1118 |
+
<label class="wd-label" for="id"><?php _e('Submitter\'s Username', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1119 |
<span><?php echo $username; ?></span>
|
1120 |
</div>
|
1121 |
<div class="wd-group">
|
1122 |
+
<label class="wd-label" for="id"><?php _e('Submitter\'s Email Address', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
1123 |
<span><?php echo $useremail; ?></span>
|
1124 |
</div>
|
1125 |
</div>
|
1154 |
<label class="wd-label"><?php echo $labels_name[$key]; ?></label>
|
1155 |
<select name="submission_0" id="submission_0">
|
1156 |
<option value=""></option>
|
1157 |
+
<option value="Canceled"><?php echo _e('Canceled', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1158 |
+
<option value="Cleared"><?php echo _e('Cleared', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1159 |
+
<option value="Cleared by payment review"><?php echo _e('Cleared by payment review', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1160 |
+
<option value="Completed"><?php echo _e('Completed', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1161 |
+
<option value="Denied"><?php echo _e('Denied', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1162 |
+
<option value="Failed"><?php echo _e('Failed', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1163 |
+
<option value="Held"><?php echo _e('Held', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1164 |
+
<option value="In progress"><?php echo _e('In progress', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1165 |
+
<option value="On hold"><?php echo _e('On hold', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1166 |
+
<option value="Paid"><?php echo _e('Paid', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1167 |
+
<option value="Partially refunded"><?php echo _e('Partially refunded', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1168 |
+
<option value="Pending verification"><?php echo _e('Pending verification', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1169 |
+
<option value="Placed"><?php echo _e('Placed', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1170 |
+
<option value="Processing"><?php echo _e('Processing', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1171 |
+
<option value="Refunded"><?php echo _e('Refunded', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1172 |
+
<option value="Refused"><?php echo _e('Refused', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1173 |
+
<option value="Removed"><?php echo _e('Removed', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1174 |
+
<option value="Returned"><?php echo _e('Returned', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1175 |
+
<option value="Reversed"><?php echo _e('Reversed', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1176 |
+
<option value="Temporary hold"><?php echo _e('Temporary hold', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1177 |
+
<option value="Unclaimed"><?php echo _e('Unclaimed', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1178 |
</select>
|
1179 |
<script>
|
1180 |
var element = document.getElementById("submission_0");
|
1284 |
</div>
|
1285 |
</div>
|
1286 |
</div>
|
1287 |
+
<?php wp_nonce_field(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce); ?>
|
1288 |
<input type="hidden" name="option" value="com_formmaker" />
|
1289 |
<input type="hidden" id="current_id" name="current_id" value="<?php echo $rows[0]->group_id; ?>" />
|
1290 |
<input type="hidden" name="form_id" value="<?php echo $rows[0]->form_id; ?>" />
|
1291 |
<input type="hidden" name="date" value="<?php echo $rows[0]->date; ?>" />
|
1292 |
<input type="hidden" name="ip" value="<?php echo $rows[0]->ip; ?>" />
|
1293 |
<input type="hidden" id="task" name="task" value="" />
|
1294 |
+
<input type="hidden" value="<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>" id="form_plugins_url" />
|
1295 |
</form>
|
1296 |
</div>
|
1297 |
<?php
|
1307 |
$page_url = $params['page_url'];
|
1308 |
?>
|
1309 |
<select name="form_id" id="form_id">
|
1310 |
+
<option value="0"><?php _e('- Select a form -', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
1311 |
<?php
|
1312 |
foreach ( $params['forms'] as $form ) {
|
1313 |
$selected = ( $form->id == $params['id'] ) ? 'selected="selected"' : '';
|
admin/views/Themes_fm.php
CHANGED
@@ -4,10 +4,10 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
4 |
* FMViewThemes_fm constructor.
|
5 |
*/
|
6 |
public function __construct() {
|
7 |
-
wp_enqueue_style('
|
8 |
-
wp_enqueue_style('
|
9 |
wp_enqueue_script('jquery');
|
10 |
-
wp_enqueue_script('
|
11 |
}
|
12 |
|
13 |
/**
|
@@ -20,10 +20,10 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
20 |
echo $this->body($params);
|
21 |
// Pass the content to form.
|
22 |
$form_attr = array(
|
23 |
-
'id' =>
|
24 |
-
'name' =>
|
25 |
-
'class' =>
|
26 |
-
'action' => add_query_arg(array( 'page' => 'themes' .
|
27 |
);
|
28 |
echo $this->form(ob_get_clean(), $form_attr);
|
29 |
}
|
@@ -43,7 +43,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
43 |
$rows_data = $params['rows_data'];
|
44 |
$page_url = add_query_arg(array(
|
45 |
'page' => $page,
|
46 |
-
|
47 |
), admin_url('admin.php'));
|
48 |
echo $this->title(array(
|
49 |
'title' => $params['page_title'],
|
@@ -64,11 +64,11 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
64 |
<thead>
|
65 |
<tr>
|
66 |
<td id="cb" class="column-cb check-column">
|
67 |
-
<label class="screen-reader-text" for="cb-select-all-1"><?php _e('Select all',
|
68 |
<input id="check_all" type="checkbox" />
|
69 |
</td>
|
70 |
-
<?php echo
|
71 |
-
<?php echo
|
72 |
</tr>
|
73 |
</thead>
|
74 |
<tbody>
|
@@ -86,20 +86,20 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
86 |
<th class="check-column">
|
87 |
<input id="check_<?php echo $row_data->id; ?>" name="check[<?php echo $row_data->id; ?>]" type="checkbox" />
|
88 |
</th>
|
89 |
-
<td class="column-primary" data-colname="<?php _e('Title',
|
90 |
<strong>
|
91 |
<a href="<?php echo $edit_url; ?>"><?php echo $row_data->title; ?></a>
|
92 |
</strong>
|
93 |
<div class="row-actions">
|
94 |
-
<span><a href="<?php echo $edit_url; ?>"><?php _e('Edit',
|
95 |
-
<span><a href="<?php echo $duplicate_url; ?>"><?php _e('Duplicate',
|
96 |
-
<span class="trash"><a onclick="if (!confirm('<?php echo addslashes(__('Do you want to delete selected item?',
|
97 |
</div>
|
98 |
<button class="toggle-row" type="button">
|
99 |
-
<span class="screen-reader-text"><?php _e('Show more details',
|
100 |
</button>
|
101 |
</td>
|
102 |
-
<td class="col_default" data-colname="<?php _e('Default',
|
103 |
<?php
|
104 |
$default = ($row_data->default) ? 1 : 0;
|
105 |
$default_image = ($row_data->default) ? 'default' : 'notdefault';
|
@@ -109,7 +109,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
109 |
<?php
|
110 |
}
|
111 |
?>
|
112 |
-
<img src="<?php echo
|
113 |
<?php
|
114 |
if ($default) {
|
115 |
?>
|
@@ -123,7 +123,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
123 |
}
|
124 |
}
|
125 |
else {
|
126 |
-
echo
|
127 |
}
|
128 |
?>
|
129 |
</tbody>
|
@@ -140,15 +140,15 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
140 |
ob_start();
|
141 |
$buttons = array(
|
142 |
'save' => array(
|
143 |
-
'title' => __('Save',
|
144 |
'value' => 'save',
|
145 |
-
'onclick' => 'if (fm_check_required(\'title\', \'' . __('Title',
|
146 |
'class' => 'button-primary',
|
147 |
),
|
148 |
);
|
149 |
echo $this->buttons($buttons);
|
150 |
echo $this->title(array(
|
151 |
-
'title' => __('Title: ',
|
152 |
'title_name' => 'title',
|
153 |
'title_id' => 'title',
|
154 |
'title_value' => $params['page_title'],
|
@@ -158,11 +158,11 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
158 |
echo $this->edit_body($params);
|
159 |
// Pass the content to form.
|
160 |
$form_attr = array(
|
161 |
-
'id' =>
|
162 |
'current_id' => $params['id'],
|
163 |
-
'name' =>
|
164 |
-
'class' =>
|
165 |
-
'action' => add_query_arg(array( 'page' => 'themes' .
|
166 |
);
|
167 |
echo $this->form(ob_get_clean(), $form_attr);
|
168 |
}
|
@@ -173,24 +173,24 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
173 |
* @param $params
|
174 |
*/
|
175 |
public function edit_body( $params ) {
|
176 |
-
wp_enqueue_style('
|
177 |
-
wp_enqueue_style('
|
178 |
-
wp_enqueue_style('
|
179 |
-
wp_enqueue_script('
|
180 |
-
wp_enqueue_script('
|
181 |
-
wp_enqueue_script('
|
182 |
|
183 |
$row = $params['row'];
|
184 |
$param_values = $params['param_values'];
|
185 |
$fonts = $params['fonts'];
|
186 |
|
187 |
-
wp_enqueue_style('
|
188 |
|
189 |
$tabs = $params['tabs'];
|
190 |
$all_params = $params['all_params'];
|
191 |
|
192 |
-
$active_tab =
|
193 |
-
$pagination =
|
194 |
?>
|
195 |
<div ng-app="ThemeParams" class="fm-table">
|
196 |
<div ng-controller="FMTheme">
|
@@ -221,7 +221,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
221 |
$show_hide_class = $active_tab == $pkey ? '' : 'fm-hide';
|
222 |
echo '<div id="'.$pkey.'-content" class="fm-themes-container '.$show_hide_class.'">';
|
223 |
if ($row->version == 1 && $pkey == 'custom_css') {
|
224 |
-
echo '<div class="error inline"><p>' . __('This theme is outdated. Theme Options are only available in new themes provided by Form Maker. You can use Custom CSS panel to edit form styling, or alternatively select a new theme for your form.',
|
225 |
}
|
226 |
foreach($params as $param){
|
227 |
if($param["type"] == 'panel') {
|
@@ -302,16 +302,16 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
302 |
</div>
|
303 |
<div class="fm-preview-form col-md-6 col-sm-7" style="display:none;">
|
304 |
<div class="form-example-preview fm-sidebar col-md-12">
|
305 |
-
<p><?php _e('Preview',
|
306 |
<div class="fm-row">
|
307 |
-
<label><?php _e('Pagination Type: ',
|
308 |
<div class="pagination-type" ng-init="pagination='<?php echo $pagination; ?>'">
|
309 |
<input type="radio" id="step" name="pagination-type" value="step" ng-model="pagination"/>
|
310 |
-
<label for="step"><?php _e('Step',
|
311 |
<input type="radio" id="percentage" name="pagination-type" value="percentage" ng-model="pagination" />
|
312 |
-
<label for="percentage"><?php _e('Percentage',
|
313 |
<input type="radio" id="none" name="pagination-type" value="none" ng-model="pagination" />
|
314 |
-
<label for="none"><?php _e('None',
|
315 |
</div>
|
316 |
</div>
|
317 |
<div class="fm-clear"></div>
|
@@ -339,14 +339,14 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
339 |
<div class="fm-form" ng-class="{borderRight : AGPBorderRight, borderLeft : AGPBorderLeft, borderBottom : AGPBorderBottom, borderTop : AGPBorderTop}">
|
340 |
<div ng-show="HPAlign != 'bottom' && HPAlign != 'right'" ng-class="{borderRight : HPBorderRight, borderLeft : HPBorderLeft, borderBottom : HPBorderBottom, borderTop : HPBorderTop, alignLeft : HPAlign == 'left'}" class="fm-form-header">
|
341 |
<div ng-show="HIPAlign != 'bottom' && HIPAlign != 'right'" ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="himage">
|
342 |
-
<img src="<?php echo
|
343 |
</div>
|
344 |
<div ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="htext">
|
345 |
-
<div class="htitle"><?php _e('Subscribe to our newsletter ',
|
346 |
-
<div class="hdescription"><?php _e('Join our mailing list to receive the latest news from our team.',
|
347 |
</div>
|
348 |
<div ng-show="HIPAlign == 'bottom' || HIPAlign == 'right'" ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="himage">
|
349 |
-
<img src="<?php echo
|
350 |
</div>
|
351 |
</div>
|
352 |
<div class="fm-form-content" ng-class="{isBG : GPBackground != '', borderRight : GPBorderRight, borderLeft : GPBorderLeft, borderBottom : GPBorderBottom, borderTop : GPBorderTop, alignLeft : HPAlign == 'left' || HPAlign == 'right'}">
|
@@ -356,7 +356,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
356 |
<div class="fm-column">
|
357 |
<div class="fm-row">
|
358 |
<div type="type_submitter_mail" class="wdform-field">
|
359 |
-
<div class="wdform-label-section" style="float: left; width: 90px;"><span class="wdform-label"><?php _e('E-mail:',
|
360 |
</div>
|
361 |
<div class="wdform-element-section" style="width: 150px;">
|
362 |
<input type="text" value="example@example.com" style="width: 100%;" ng-class="{borderRight : IPBorderRight, borderLeft : IPBorderLeft, borderBottom : IPBorderBottom, borderTop : IPBorderTop}" />
|
@@ -366,11 +366,11 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
366 |
<div class="fm-row">
|
367 |
<div type="type_country" class="wdform-field">
|
368 |
<div class="wdform-label-section" style="float: left; width: 90px;">
|
369 |
-
<span class="wdform-label"><?php _e('Country:',
|
370 |
</div>
|
371 |
<div class="wdform-element-section wdform_select" style=" width: 150px;">
|
372 |
<select style="width: 100%;" ng-class="{isBG : SBPBackground != '', borderRight : IPBorderRight, borderLeft : IPBorderLeft, borderBottom : IPBorderBottom, borderTop : IPBorderTop}">
|
373 |
-
<option value="Armenia"><?php _e('Armenia',
|
374 |
</select>
|
375 |
</div>
|
376 |
</div>
|
@@ -379,7 +379,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
379 |
<div class="fm-row">
|
380 |
<div type="type_radio" class="wdform-field">
|
381 |
<div class="wdform-label-section" style="float: left; width: 90px;">
|
382 |
-
<span class="wdform-label"><?php _e('Radio:',
|
383 |
</div>
|
384 |
<div class="wdform-element-section " style="display:table;">
|
385 |
<div style="display: table-row; vertical-align:top">
|
@@ -387,7 +387,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
387 |
<div class="radio-div check-rad">
|
388 |
<input type="radio" id="em-rad-op-1" value="option 1" ng-hide="{{DefaultVar}}">
|
389 |
<label for="em-rad-op-1" class="mini_label">
|
390 |
-
<span ng-class="{borderRight : SCPBorderRight, borderLeft : SCPBorderLeft, borderBottom : SCPBorderBottom, borderTop : SCPBorderTop}"></span><?php _e('option 1',
|
391 |
</label>
|
392 |
</div>
|
393 |
</div>
|
@@ -398,14 +398,14 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
398 |
<div class="fm-row">
|
399 |
<div type="type_checkbox" class="wdform-field">
|
400 |
<div class="wdform-label-section" style="float: left; width: 90px;">
|
401 |
-
<span class="wdform-label"><?php _e('Checkbox:',
|
402 |
</div>
|
403 |
<div class="wdform-element-section" style="display: table;">
|
404 |
<div style="display: table-row; vertical-align:top">
|
405 |
<div style="display: table-cell;">
|
406 |
<div class="checkbox-div forlabs" ng-class="{isBG : MCCPBackground != ''}">
|
407 |
<input type="checkbox" id="em-ch-op-1" value="option 1" ng-hide="{{DefaultVar}}">
|
408 |
-
<label for="em-ch-op-1" class="mini_label"><span ng-class="{borderRight : MCPBorderRight, borderLeft : MCPBorderLeft, borderBottom : MCPBorderBottom, borderTop : MCPBorderTop}"></span><?php _e('option 1',
|
409 |
</div>
|
410 |
</div>
|
411 |
</div>
|
@@ -416,8 +416,8 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
416 |
<div type="type_submit_reset" class="wdform-field subscribe-reset">
|
417 |
<div class="wdform-label-section" style="display: table-cell;"></div>
|
418 |
<div class="wdform-element-section" style="display: table-cell;">
|
419 |
-
<button type="button" class="button button-large fm-button-subscribe" ng-class="{borderRight : SPBorderRight, borderLeft : SPBorderLeft, borderBottom : SPBorderBottom, borderTop : SPBorderTop, borderHoverRight : SHPBorderRight, borderHoverLeft : SHPBorderLeft, borderHoverBottom : SHPBorderBottom, borderHoverTop : SHPBorderTop}" ><?php _e('Submit',
|
420 |
-
<button type="button" class="button button-large fm-button-reset" ng-class="{borderRight : BPBorderRight, borderLeft : BPBorderLeft, borderBottom : BPBorderBottom, borderTop : BPBorderTop, borderHoverRight : BHPBorderRight, borderHoverLeft : BHPBorderLeft, borderHoverBottom : BHPBorderBottom, borderHoverTop : BHPBorderTop}"><?php _e('Reset',
|
421 |
</div>
|
422 |
</div>
|
423 |
</div>
|
@@ -434,13 +434,13 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
434 |
<div style="display: table-row-group;">
|
435 |
<div style="display: table-row;">
|
436 |
<div class="fm-previous-page" style="display: table-cell; width: 45%;">
|
437 |
-
<div class="fm-wdform-page-button" ng-class="{borderRight : PBPBorderRight, borderLeft : PBPBorderLeft, borderBottom : PBPBorderBottom, borderTop : PBPBorderTop, borderHoverRight : PBHPBorderRight, borderHoverLeft : PBHPBorderLeft, borderHoverBottom : PBHPBorderBottom, borderHoverTop : PBHPBorderTop}"><span class="dashicons dashicons-arrow-left-alt2"></span><?php _e('Previous',
|
438 |
</div>
|
439 |
<div class="page-numbers text-center" style="display: table-cell;">
|
440 |
<span>2/3</span>
|
441 |
</div>
|
442 |
<div class="fm-next-page" style="display: table-cell; width: 45%; text-align: right;">
|
443 |
-
<div class="fm-wdform-page-button" ng-class="{borderRight : NBPBorderRight, borderLeft : NBPBorderLeft, borderBottom : NBPBorderBottom, borderTop : NBPBorderTop, borderHoverRight : NBHPBorderRight, borderHoverLeft : NBHPBorderLeft, borderHoverBottom : NBHPBorderBottom, borderHoverTop : NBHPBorderTop}"><?php _e('Next',
|
444 |
</div>
|
445 |
</div>
|
446 |
</div>
|
@@ -452,14 +452,14 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
452 |
</div>
|
453 |
<div ng-show="HPAlign == 'bottom' || HPAlign == 'right'" ng-class="{borderRight : HPBorderRight, borderLeft : HPBorderLeft, borderBottom : HPBorderBottom, borderTop : HPBorderTop, alignLeft : HPAlign == 'right'}" class="fm-form-header">
|
454 |
<div ng-show="HIPAlign != 'bottom' && HIPAlign != 'right'" ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="himage">
|
455 |
-
<img src="<?php echo
|
456 |
</div>
|
457 |
<div ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="htext">
|
458 |
-
<div class="htitle"><?php _e('Subscribe to our newsletter',
|
459 |
-
<div class="hdescription"><?php _e('Join our mailing list to receive the latest news from our team.',
|
460 |
</div>
|
461 |
<div ng-show="HIPAlign == 'bottom' || HIPAlign == 'right'" ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="himage">
|
462 |
-
<img src="<?php echo
|
463 |
</div>
|
464 |
</div>
|
465 |
</div>
|
@@ -513,7 +513,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
513 |
}
|
514 |
|
515 |
.fm-form-content.isBG{
|
516 |
-
background:url(<?php echo
|
517 |
background-size: {{GPBGSize1}} {{GPPBGSize2}} !important;
|
518 |
}
|
519 |
|
@@ -593,7 +593,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
593 |
|
594 |
.fm-form-content select.isBG{
|
595 |
background-color: {{IPBGColor}} !important;
|
596 |
-
background-image: url(<?php echo
|
597 |
background-repeat: {{SBPBGRepeat}} !important;
|
598 |
}
|
599 |
|
@@ -880,7 +880,7 @@ class FMViewThemes_fmc extends FMAdminView_fmc {
|
|
880 |
}
|
881 |
|
882 |
.checkbox-div.isBG input[type='checkbox']:checked + label span:after{
|
883 |
-
background:{{MCCPBGColor}} url(<?php echo
|
884 |
}
|
885 |
|
886 |
.checkbox-div label span.borderRight {
|
4 |
* FMViewThemes_fm constructor.
|
5 |
*/
|
6 |
public function __construct() {
|
7 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-tables');
|
8 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-first');
|
9 |
wp_enqueue_script('jquery');
|
10 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-admin');
|
11 |
}
|
12 |
|
13 |
/**
|
20 |
echo $this->body($params);
|
21 |
// Pass the content to form.
|
22 |
$form_attr = array(
|
23 |
+
'id' => WDFMInstance(self::PLUGIN)->prefix . '_themes',
|
24 |
+
'name' => WDFMInstance(self::PLUGIN)->prefix . '_themes',
|
25 |
+
'class' => WDFMInstance(self::PLUGIN)->prefix . '_themes wd-form',
|
26 |
+
'action' => add_query_arg(array( 'page' => 'themes' . WDFMInstance(self::PLUGIN)->menu_postfix ), 'admin.php'),
|
27 |
);
|
28 |
echo $this->form(ob_get_clean(), $form_attr);
|
29 |
}
|
43 |
$rows_data = $params['rows_data'];
|
44 |
$page_url = add_query_arg(array(
|
45 |
'page' => $page,
|
46 |
+
WDFMInstance(self::PLUGIN)->nonce => wp_create_nonce(WDFMInstance(self::PLUGIN)->nonce),
|
47 |
), admin_url('admin.php'));
|
48 |
echo $this->title(array(
|
49 |
'title' => $params['page_title'],
|
64 |
<thead>
|
65 |
<tr>
|
66 |
<td id="cb" class="column-cb check-column">
|
67 |
+
<label class="screen-reader-text" for="cb-select-all-1"><?php _e('Select all', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
68 |
<input id="check_all" type="checkbox" />
|
69 |
</td>
|
70 |
+
<?php echo WDW_FM_Library(self::PLUGIN)->ordering('title', $orderby, $order, __('Title', WDFMInstance(self::PLUGIN)->prefix), $page_url, 'column-primary'); ?>
|
71 |
+
<?php echo WDW_FM_Library(self::PLUGIN)->ordering('default', $orderby, $order, __('Default', WDFMInstance(self::PLUGIN)->prefix), $page_url, 'column-primary'); ?>
|
72 |
</tr>
|
73 |
</thead>
|
74 |
<tbody>
|
86 |
<th class="check-column">
|
87 |
<input id="check_<?php echo $row_data->id; ?>" name="check[<?php echo $row_data->id; ?>]" type="checkbox" />
|
88 |
</th>
|
89 |
+
<td class="column-primary" data-colname="<?php _e('Title', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
90 |
<strong>
|
91 |
<a href="<?php echo $edit_url; ?>"><?php echo $row_data->title; ?></a>
|
92 |
</strong>
|
93 |
<div class="row-actions">
|
94 |
+
<span><a href="<?php echo $edit_url; ?>"><?php _e('Edit', WDFMInstance(self::PLUGIN)->prefix); ?></a> |</span>
|
95 |
+
<span><a href="<?php echo $duplicate_url; ?>"><?php _e('Duplicate', WDFMInstance(self::PLUGIN)->prefix); ?></a> |</span>
|
96 |
+
<span class="trash"><a onclick="if (!confirm('<?php echo addslashes(__('Do you want to delete selected item?', WDFMInstance(self::PLUGIN)->prefix)); ?>')) {return false;}" href="<?php echo $delete_url; ?>"><?php _e('Delete', WDFMInstance(self::PLUGIN)->prefix); ?></a></span>
|
97 |
</div>
|
98 |
<button class="toggle-row" type="button">
|
99 |
+
<span class="screen-reader-text"><?php _e('Show more details', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
100 |
</button>
|
101 |
</td>
|
102 |
+
<td class="col_default" data-colname="<?php _e('Default', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
103 |
<?php
|
104 |
$default = ($row_data->default) ? 1 : 0;
|
105 |
$default_image = ($row_data->default) ? 'default' : 'notdefault';
|
109 |
<?php
|
110 |
}
|
111 |
?>
|
112 |
+
<img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url . '/images/' . $default_image . '.png?ver=' . WDFMInstance(self::PLUGIN)->plugin_version . ''; ?>" />
|
113 |
<?php
|
114 |
if ($default) {
|
115 |
?>
|
123 |
}
|
124 |
}
|
125 |
else {
|
126 |
+
echo WDW_FM_Library(self::PLUGIN)->no_items('themes');
|
127 |
}
|
128 |
?>
|
129 |
</tbody>
|
140 |
ob_start();
|
141 |
$buttons = array(
|
142 |
'save' => array(
|
143 |
+
'title' => __('Save', WDFMInstance(self::PLUGIN)->prefix),
|
144 |
'value' => 'save',
|
145 |
+
'onclick' => 'if (fm_check_required(\'title\', \'' . __('Title', WDFMInstance(self::PLUGIN)->prefix) . '\') || !fm_theme_submit_button(\'' . WDFMInstance(self::PLUGIN)->prefix . '_themes\', ' . $params['row']->version . ')) {return false;}; fm_set_input_value(\'task\', \'apply\');',
|
146 |
'class' => 'button-primary',
|
147 |
),
|
148 |
);
|
149 |
echo $this->buttons($buttons);
|
150 |
echo $this->title(array(
|
151 |
+
'title' => __('Title: ', WDFMInstance(self::PLUGIN)->prefix),
|
152 |
'title_name' => 'title',
|
153 |
'title_id' => 'title',
|
154 |
'title_value' => $params['page_title'],
|
158 |
echo $this->edit_body($params);
|
159 |
// Pass the content to form.
|
160 |
$form_attr = array(
|
161 |
+
'id' => WDFMInstance(self::PLUGIN)->prefix . '_themes',
|
162 |
'current_id' => $params['id'],
|
163 |
+
'name' => WDFMInstance(self::PLUGIN)->prefix . '_themes',
|
164 |
+
'class' => WDFMInstance(self::PLUGIN)->prefix . '_themes wd-form',
|
165 |
+
'action' => add_query_arg(array( 'page' => 'themes' . WDFMInstance(self::PLUGIN)->menu_postfix ), 'admin.php'),
|
166 |
);
|
167 |
echo $this->form(ob_get_clean(), $form_attr);
|
168 |
}
|
173 |
* @param $params
|
174 |
*/
|
175 |
public function edit_body( $params ) {
|
176 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-bootstrap');
|
177 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style');
|
178 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-colorpicker');
|
179 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-colorpicker');
|
180 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-ng-js');
|
181 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-themes');
|
182 |
|
183 |
$row = $params['row'];
|
184 |
$param_values = $params['param_values'];
|
185 |
$fonts = $params['fonts'];
|
186 |
|
187 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-googlefonts', 'https://fonts.googleapis.com/css?family=' . $fonts . '&subset=greek,latin,greek-ext,vietnamese,cyrillic-ext,latin-ext,cyrillic', null, null);
|
188 |
|
189 |
$tabs = $params['tabs'];
|
190 |
$all_params = $params['all_params'];
|
191 |
|
192 |
+
$active_tab = WDW_FM_Library(self::PLUGIN)->get('active_tab', ($row->version == 1 ? 'custom_css' : 'global'));
|
193 |
+
$pagination = WDW_FM_Library(self::PLUGIN)->get('pagination', 'none');
|
194 |
?>
|
195 |
<div ng-app="ThemeParams" class="fm-table">
|
196 |
<div ng-controller="FMTheme">
|
221 |
$show_hide_class = $active_tab == $pkey ? '' : 'fm-hide';
|
222 |
echo '<div id="'.$pkey.'-content" class="fm-themes-container '.$show_hide_class.'">';
|
223 |
if ($row->version == 1 && $pkey == 'custom_css') {
|
224 |
+
echo '<div class="error inline"><p>' . __('This theme is outdated. Theme Options are only available in new themes provided by Form Maker. You can use Custom CSS panel to edit form styling, or alternatively select a new theme for your form.', WDFMInstance(self::PLUGIN)->prefix) . '</p></div>';
|
225 |
}
|
226 |
foreach($params as $param){
|
227 |
if($param["type"] == 'panel') {
|
302 |
</div>
|
303 |
<div class="fm-preview-form col-md-6 col-sm-7" style="display:none;">
|
304 |
<div class="form-example-preview fm-sidebar col-md-12">
|
305 |
+
<p><?php _e('Preview', WDFMInstance(self::PLUGIN)->prefix); ?></p>
|
306 |
<div class="fm-row">
|
307 |
+
<label><?php _e('Pagination Type: ', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
308 |
<div class="pagination-type" ng-init="pagination='<?php echo $pagination; ?>'">
|
309 |
<input type="radio" id="step" name="pagination-type" value="step" ng-model="pagination"/>
|
310 |
+
<label for="step"><?php _e('Step', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
311 |
<input type="radio" id="percentage" name="pagination-type" value="percentage" ng-model="pagination" />
|
312 |
+
<label for="percentage"><?php _e('Percentage', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
313 |
<input type="radio" id="none" name="pagination-type" value="none" ng-model="pagination" />
|
314 |
+
<label for="none"><?php _e('None', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
315 |
</div>
|
316 |
</div>
|
317 |
<div class="fm-clear"></div>
|
339 |
<div class="fm-form" ng-class="{borderRight : AGPBorderRight, borderLeft : AGPBorderLeft, borderBottom : AGPBorderBottom, borderTop : AGPBorderTop}">
|
340 |
<div ng-show="HPAlign != 'bottom' && HPAlign != 'right'" ng-class="{borderRight : HPBorderRight, borderLeft : HPBorderLeft, borderBottom : HPBorderBottom, borderTop : HPBorderTop, alignLeft : HPAlign == 'left'}" class="fm-form-header">
|
341 |
<div ng-show="HIPAlign != 'bottom' && HIPAlign != 'right'" ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="himage">
|
342 |
+
<img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>/images/preview_header.png" />
|
343 |
</div>
|
344 |
<div ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="htext">
|
345 |
+
<div class="htitle"><?php _e('Subscribe to our newsletter ', WDFMInstance(self::PLUGIN)->prefix); ?></div>
|
346 |
+
<div class="hdescription"><?php _e('Join our mailing list to receive the latest news from our team.', WDFMInstance(self::PLUGIN)->prefix); ?></div>
|
347 |
</div>
|
348 |
<div ng-show="HIPAlign == 'bottom' || HIPAlign == 'right'" ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="himage">
|
349 |
+
<img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>/images/preview_header.png" />
|
350 |
</div>
|
351 |
</div>
|
352 |
<div class="fm-form-content" ng-class="{isBG : GPBackground != '', borderRight : GPBorderRight, borderLeft : GPBorderLeft, borderBottom : GPBorderBottom, borderTop : GPBorderTop, alignLeft : HPAlign == 'left' || HPAlign == 'right'}">
|
356 |
<div class="fm-column">
|
357 |
<div class="fm-row">
|
358 |
<div type="type_submitter_mail" class="wdform-field">
|
359 |
+
<div class="wdform-label-section" style="float: left; width: 90px;"><span class="wdform-label"><?php _e('E-mail:', WDFMInstance(self::PLUGIN)->prefix); ?></span><span class="wdform-required">*</span>
|
360 |
</div>
|
361 |
<div class="wdform-element-section" style="width: 150px;">
|
362 |
<input type="text" value="example@example.com" style="width: 100%;" ng-class="{borderRight : IPBorderRight, borderLeft : IPBorderLeft, borderBottom : IPBorderBottom, borderTop : IPBorderTop}" />
|
366 |
<div class="fm-row">
|
367 |
<div type="type_country" class="wdform-field">
|
368 |
<div class="wdform-label-section" style="float: left; width: 90px;">
|
369 |
+
<span class="wdform-label"><?php _e('Country:', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
370 |
</div>
|
371 |
<div class="wdform-element-section wdform_select" style=" width: 150px;">
|
372 |
<select style="width: 100%;" ng-class="{isBG : SBPBackground != '', borderRight : IPBorderRight, borderLeft : IPBorderLeft, borderBottom : IPBorderBottom, borderTop : IPBorderTop}">
|
373 |
+
<option value="Armenia"><?php _e('Armenia', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
374 |
</select>
|
375 |
</div>
|
376 |
</div>
|
379 |
<div class="fm-row">
|
380 |
<div type="type_radio" class="wdform-field">
|
381 |
<div class="wdform-label-section" style="float: left; width: 90px;">
|
382 |
+
<span class="wdform-label"><?php _e('Radio:', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
383 |
</div>
|
384 |
<div class="wdform-element-section " style="display:table;">
|
385 |
<div style="display: table-row; vertical-align:top">
|
387 |
<div class="radio-div check-rad">
|
388 |
<input type="radio" id="em-rad-op-1" value="option 1" ng-hide="{{DefaultVar}}">
|
389 |
<label for="em-rad-op-1" class="mini_label">
|
390 |
+
<span ng-class="{borderRight : SCPBorderRight, borderLeft : SCPBorderLeft, borderBottom : SCPBorderBottom, borderTop : SCPBorderTop}"></span><?php _e('option 1', WDFMInstance(self::PLUGIN)->prefix); ?>
|
391 |
</label>
|
392 |
</div>
|
393 |
</div>
|
398 |
<div class="fm-row">
|
399 |
<div type="type_checkbox" class="wdform-field">
|
400 |
<div class="wdform-label-section" style="float: left; width: 90px;">
|
401 |
+
<span class="wdform-label"><?php _e('Checkbox:', WDFMInstance(self::PLUGIN)->prefix); ?></span>
|
402 |
</div>
|
403 |
<div class="wdform-element-section" style="display: table;">
|
404 |
<div style="display: table-row; vertical-align:top">
|
405 |
<div style="display: table-cell;">
|
406 |
<div class="checkbox-div forlabs" ng-class="{isBG : MCCPBackground != ''}">
|
407 |
<input type="checkbox" id="em-ch-op-1" value="option 1" ng-hide="{{DefaultVar}}">
|
408 |
+
<label for="em-ch-op-1" class="mini_label"><span ng-class="{borderRight : MCPBorderRight, borderLeft : MCPBorderLeft, borderBottom : MCPBorderBottom, borderTop : MCPBorderTop}"></span><?php _e('option 1', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
409 |
</div>
|
410 |
</div>
|
411 |
</div>
|
416 |
<div type="type_submit_reset" class="wdform-field subscribe-reset">
|
417 |
<div class="wdform-label-section" style="display: table-cell;"></div>
|
418 |
<div class="wdform-element-section" style="display: table-cell;">
|
419 |
+
<button type="button" class="button button-large fm-button-subscribe" ng-class="{borderRight : SPBorderRight, borderLeft : SPBorderLeft, borderBottom : SPBorderBottom, borderTop : SPBorderTop, borderHoverRight : SHPBorderRight, borderHoverLeft : SHPBorderLeft, borderHoverBottom : SHPBorderBottom, borderHoverTop : SHPBorderTop}" ><?php _e('Submit', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
420 |
+
<button type="button" class="button button-large fm-button-reset" ng-class="{borderRight : BPBorderRight, borderLeft : BPBorderLeft, borderBottom : BPBorderBottom, borderTop : BPBorderTop, borderHoverRight : BHPBorderRight, borderHoverLeft : BHPBorderLeft, borderHoverBottom : BHPBorderBottom, borderHoverTop : BHPBorderTop}"><?php _e('Reset', WDFMInstance(self::PLUGIN)->prefix); ?></button>
|
421 |
</div>
|
422 |
</div>
|
423 |
</div>
|
434 |
<div style="display: table-row-group;">
|
435 |
<div style="display: table-row;">
|
436 |
<div class="fm-previous-page" style="display: table-cell; width: 45%;">
|
437 |
+
<div class="fm-wdform-page-button" ng-class="{borderRight : PBPBorderRight, borderLeft : PBPBorderLeft, borderBottom : PBPBorderBottom, borderTop : PBPBorderTop, borderHoverRight : PBHPBorderRight, borderHoverLeft : PBHPBorderLeft, borderHoverBottom : PBHPBorderBottom, borderHoverTop : PBHPBorderTop}"><span class="dashicons dashicons-arrow-left-alt2"></span><?php _e('Previous', WDFMInstance(self::PLUGIN)->prefix); ?></div>
|
438 |
</div>
|
439 |
<div class="page-numbers text-center" style="display: table-cell;">
|
440 |
<span>2/3</span>
|
441 |
</div>
|
442 |
<div class="fm-next-page" style="display: table-cell; width: 45%; text-align: right;">
|
443 |
+
<div class="fm-wdform-page-button" ng-class="{borderRight : NBPBorderRight, borderLeft : NBPBorderLeft, borderBottom : NBPBorderBottom, borderTop : NBPBorderTop, borderHoverRight : NBHPBorderRight, borderHoverLeft : NBHPBorderLeft, borderHoverBottom : NBHPBorderBottom, borderHoverTop : NBHPBorderTop}"><?php _e('Next', WDFMInstance(self::PLUGIN)->prefix); ?><span class="dashicons dashicons-arrow-right-alt2"></span></div>
|
444 |
</div>
|
445 |
</div>
|
446 |
</div>
|
452 |
</div>
|
453 |
<div ng-show="HPAlign == 'bottom' || HPAlign == 'right'" ng-class="{borderRight : HPBorderRight, borderLeft : HPBorderLeft, borderBottom : HPBorderBottom, borderTop : HPBorderTop, alignLeft : HPAlign == 'right'}" class="fm-form-header">
|
454 |
<div ng-show="HIPAlign != 'bottom' && HIPAlign != 'right'" ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="himage">
|
455 |
+
<img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>/images/preview_header.png" />
|
456 |
</div>
|
457 |
<div ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="htext">
|
458 |
+
<div class="htitle"><?php _e('Subscribe to our newsletter', WDFMInstance(self::PLUGIN)->prefix); ?></div>
|
459 |
+
<div class="hdescription"><?php _e('Join our mailing list to receive the latest news from our team.', WDFMInstance(self::PLUGIN)->prefix); ?></div>
|
460 |
</div>
|
461 |
<div ng-show="HIPAlign == 'bottom' || HIPAlign == 'right'" ng-class="{imageRight : HIPAlign == 'right', imageLeft : HIPAlign == 'left', imageBottom : HIPAlign == 'bottom', imageTop : HIPAlign == 'top'}" class="himage">
|
462 |
+
<img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>/images/preview_header.png" />
|
463 |
</div>
|
464 |
</div>
|
465 |
</div>
|
513 |
}
|
514 |
|
515 |
.fm-form-content.isBG{
|
516 |
+
background:url(<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>/{{GPBackground}}) {{GPBackgroundRepeat}} {{GPBGPosition1}} {{GPBGPosition2}} !important;
|
517 |
background-size: {{GPBGSize1}} {{GPPBGSize2}} !important;
|
518 |
}
|
519 |
|
593 |
|
594 |
.fm-form-content select.isBG{
|
595 |
background-color: {{IPBGColor}} !important;
|
596 |
+
background-image: url(<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>/{{SBPBackground}}) !important;
|
597 |
background-repeat: {{SBPBGRepeat}} !important;
|
598 |
}
|
599 |
|
880 |
}
|
881 |
|
882 |
.checkbox-div.isBG input[type='checkbox']:checked + label span:after{
|
883 |
+
background:{{MCCPBGColor}} url(<?php echo WDFMInstance(self::PLUGIN)->plugin_url; ?>/{{MCCPBackground}}) {{MCCPBGRepeat}} {{MCCPBGPos1}} {{MCCPBGPos2}} !important;
|
884 |
}
|
885 |
|
886 |
.checkbox-div label span.borderRight {
|
admin/views/Uninstall_fm.php
CHANGED
@@ -1,15 +1,15 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
class FMViewUninstall_fmc {
|
4 |
/**
|
5 |
* FMViewUninstall_fm constructor.
|
6 |
*/
|
7 |
public function __construct() {
|
8 |
-
wp_enqueue_style('
|
9 |
-
wp_enqueue_script('
|
10 |
-
if (
|
11 |
-
wp_enqueue_style('
|
12 |
-
wp_enqueue_script('
|
13 |
}
|
14 |
}
|
15 |
|
@@ -18,13 +18,13 @@ class FMViewUninstall_fmc {
|
|
18 |
$prefix = $wpdb->prefix;
|
19 |
$addons = $params['addons'];
|
20 |
?>
|
21 |
-
<form method="post" action="admin.php?page=uninstall<?php echo
|
22 |
-
<?php wp_nonce_field(
|
23 |
<div class="wrap">
|
24 |
<div class="uninstall-banner">
|
25 |
<div class="uninstall_icon">
|
26 |
</div>
|
27 |
-
<div class="fm-logo-title">Uninstall
|
28 |
</div>
|
29 |
<br />
|
30 |
<div class="goodbye-text">
|
@@ -34,10 +34,10 @@ class FMViewUninstall_fmc {
|
|
34 |
<a href="https://web-dorado.com/support/contact-us.html" target='_blank'>Contact us</a> and tell what you didn't like for our plugins further improvement and development. Thank you !!!
|
35 |
</div>
|
36 |
<div class="goodbye-text" style="color: red;">
|
37 |
-
Note, that uninstalling
|
38 |
</div>
|
39 |
<p>
|
40 |
-
Deactivating
|
41 |
</p>
|
42 |
<p style="color: red;">
|
43 |
<strong>WARNING:</strong>
|
@@ -58,6 +58,7 @@ class FMViewUninstall_fmc {
|
|
58 |
<li><?php echo $prefix; ?>formmaker</li>
|
59 |
<li><?php echo $prefix; ?>formmaker_backup</li>
|
60 |
<li><?php echo $prefix; ?>formmaker_blocked</li>
|
|
|
61 |
<li><?php echo $prefix; ?>formmaker_submits</li>
|
62 |
<li><?php echo $prefix; ?>formmaker_views</li>
|
63 |
<li><?php echo $prefix; ?>formmaker_themes</li>
|
@@ -83,13 +84,13 @@ class FMViewUninstall_fmc {
|
|
83 |
</tr>
|
84 |
</table>
|
85 |
<p style="text-align: center;">
|
86 |
-
Do you really want to uninstall
|
87 |
</p>
|
88 |
<p style="text-align: center;">
|
89 |
<input type="checkbox" name="Form Maker" id="check_yes" value="yes" /> <label for="check_yes">Yes</label>
|
90 |
</p>
|
91 |
<p style="text-align: center;">
|
92 |
-
<input type="submit" value="UNINSTALL" class="button-primary" onclick="if (check_yes.checked) { if (confirm('You are About to Uninstall
|
93 |
</p>
|
94 |
</div>
|
95 |
<input id="task" name="task" type="hidden" value="" />
|
@@ -102,9 +103,9 @@ class FMViewUninstall_fmc {
|
|
102 |
$addons = $params['addons']; //array
|
103 |
$deactivate_url = add_query_arg(array(
|
104 |
'action' => 'deactivate',
|
105 |
-
'plugin' =>
|
106 |
), admin_url('plugins.php'));
|
107 |
-
$deactivate_url = wp_nonce_url($deactivate_url, 'deactivate-plugin_' .
|
108 |
?>
|
109 |
<div id="message" class="updated fade">
|
110 |
<p>The following Database Tables successfully deleted:</p>
|
@@ -112,6 +113,7 @@ class FMViewUninstall_fmc {
|
|
112 |
<p><?php echo $prefix; ?>formmaker_backup,</p>
|
113 |
<p><?php echo $prefix; ?>formmaker_blocked,</p>
|
114 |
<p><?php echo $prefix; ?>formmaker_sessions,</p>
|
|
|
115 |
<p><?php echo $prefix; ?>formmaker_submits,</p>
|
116 |
<p><?php echo $prefix; ?>formmaker_themes,</p>
|
117 |
<p><?php echo $prefix; ?>formmaker_views,</p>
|
@@ -133,7 +135,7 @@ class FMViewUninstall_fmc {
|
|
133 |
?>
|
134 |
</div>
|
135 |
<div class="wrap">
|
136 |
-
<h2>Uninstall
|
137 |
<p>
|
138 |
<strong><a href="<?php echo $deactivate_url; ?>" class="fm_deactivate_link" data-uninstall="1">Click Here</a> To Finish the Uninstallation and Form Maker
|
139 |
will be Deactivated Automatically.</strong></p>
|
1 |
<?php
|
2 |
|
3 |
+
class FMViewUninstall_fmc extends FMAdminView_fmc {
|
4 |
/**
|
5 |
* FMViewUninstall_fm constructor.
|
6 |
*/
|
7 |
public function __construct() {
|
8 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-tables');
|
9 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-admin');
|
10 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
11 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-deactivate-css');
|
12 |
+
wp_enqueue_script(WDFMInstance(self::PLUGIN)->handle_prefix . '-deactivate-popup');
|
13 |
}
|
14 |
}
|
15 |
|
18 |
$prefix = $wpdb->prefix;
|
19 |
$addons = $params['addons'];
|
20 |
?>
|
21 |
+
<form method="post" action="admin.php?page=uninstall<?php echo WDFMInstance(self::PLUGIN)->menu_postfix; ?>" style="width:95%;">
|
22 |
+
<?php wp_nonce_field(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce); ?>
|
23 |
<div class="wrap">
|
24 |
<div class="uninstall-banner">
|
25 |
<div class="uninstall_icon">
|
26 |
</div>
|
27 |
+
<div class="fm-logo-title">Uninstall <?php echo WDFMInstance(self::PLUGIN)->nicename; ?></div>
|
28 |
</div>
|
29 |
<br />
|
30 |
<div class="goodbye-text">
|
34 |
<a href="https://web-dorado.com/support/contact-us.html" target='_blank'>Contact us</a> and tell what you didn't like for our plugins further improvement and development. Thank you !!!
|
35 |
</div>
|
36 |
<div class="goodbye-text" style="color: red;">
|
37 |
+
Note, that uninstalling <?php echo WDFMInstance(self::PLUGIN)->nicename; ?> will remove all forms, submissions and other data on the plugin.<br />Please make sure you don't have any important information before you proceed.
|
38 |
</div>
|
39 |
<p>
|
40 |
+
Deactivating <?php echo WDFMInstance(self::PLUGIN)->nicename; ?> plugin does not remove any data that may have been created, such as the Forms and the Submissions. To completely remove this plugin, you can uninstall it here.
|
41 |
</p>
|
42 |
<p style="color: red;">
|
43 |
<strong>WARNING:</strong>
|
58 |
<li><?php echo $prefix; ?>formmaker</li>
|
59 |
<li><?php echo $prefix; ?>formmaker_backup</li>
|
60 |
<li><?php echo $prefix; ?>formmaker_blocked</li>
|
61 |
+
<li><?php echo $prefix; ?>formmaker_groups</li>
|
62 |
<li><?php echo $prefix; ?>formmaker_submits</li>
|
63 |
<li><?php echo $prefix; ?>formmaker_views</li>
|
64 |
<li><?php echo $prefix; ?>formmaker_themes</li>
|
84 |
</tr>
|
85 |
</table>
|
86 |
<p style="text-align: center;">
|
87 |
+
Do you really want to uninstall <?php echo WDFMInstance(self::PLUGIN)->nicename; ?>?
|
88 |
</p>
|
89 |
<p style="text-align: center;">
|
90 |
<input type="checkbox" name="Form Maker" id="check_yes" value="yes" /> <label for="check_yes">Yes</label>
|
91 |
</p>
|
92 |
<p style="text-align: center;">
|
93 |
+
<input type="submit" value="UNINSTALL" class="button-primary" onclick="if (check_yes.checked) { if (confirm('You are About to Uninstall <?php echo WDFMInstance(self::PLUGIN)->nicename; ?> from WordPress.\nThis Action Is Not Reversible.')) { fm_set_input_value('task', 'uninstall'); } else { return false; } } else { return false; }" />
|
94 |
</p>
|
95 |
</div>
|
96 |
<input id="task" name="task" type="hidden" value="" />
|
103 |
$addons = $params['addons']; //array
|
104 |
$deactivate_url = add_query_arg(array(
|
105 |
'action' => 'deactivate',
|
106 |
+
'plugin' => WDFMInstance(self::PLUGIN)->main_file,
|
107 |
), admin_url('plugins.php'));
|
108 |
+
$deactivate_url = wp_nonce_url($deactivate_url, 'deactivate-plugin_' . WDFMInstance(self::PLUGIN)->main_file);
|
109 |
?>
|
110 |
<div id="message" class="updated fade">
|
111 |
<p>The following Database Tables successfully deleted:</p>
|
113 |
<p><?php echo $prefix; ?>formmaker_backup,</p>
|
114 |
<p><?php echo $prefix; ?>formmaker_blocked,</p>
|
115 |
<p><?php echo $prefix; ?>formmaker_sessions,</p>
|
116 |
+
<p><?php echo $prefix; ?>formmaker_groups,</p>
|
117 |
<p><?php echo $prefix; ?>formmaker_submits,</p>
|
118 |
<p><?php echo $prefix; ?>formmaker_themes,</p>
|
119 |
<p><?php echo $prefix; ?>formmaker_views,</p>
|
135 |
?>
|
136 |
</div>
|
137 |
<div class="wrap">
|
138 |
+
<h2>Uninstall <?php echo WDFMInstance(self::PLUGIN)->nicename; ?></h2>
|
139 |
<p>
|
140 |
<strong><a href="<?php echo $deactivate_url; ?>" class="fm_deactivate_link" data-uninstall="1">Click Here</a> To Finish the Uninstallation and Form Maker
|
141 |
will be Deactivated Automatically.</strong></p>
|
admin/views/view.php
CHANGED
@@ -5,6 +5,13 @@ defined('ABSPATH') || die('Access Denied');
|
|
5 |
* Admin view class.
|
6 |
*/
|
7 |
class FMAdminView_fmc {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
8 |
/**
|
9 |
* Generate form.
|
10 |
*
|
@@ -14,21 +21,23 @@ class FMAdminView_fmc {
|
|
14 |
* @return string Form html.
|
15 |
*/
|
16 |
protected function form($content = '', $attr = array()) {
|
|
|
17 |
ob_start();
|
18 |
// Form.
|
19 |
$action = isset($attr['action']) ? esc_attr($attr['action']) : '';
|
20 |
$method = isset($attr['method']) ? esc_attr($attr['method']) : 'post';
|
21 |
-
$name = isset($attr['name']) ? esc_attr($attr['name']) :
|
22 |
$id = isset($attr['id']) ? esc_attr($attr['id']) : '';
|
23 |
-
$class = isset($attr['class']) ? esc_attr($attr['class']) :
|
24 |
$style = isset($attr['style']) ? esc_attr($attr['style']) : '';
|
25 |
$current_id = isset($attr['current_id']) ? esc_attr($attr['current_id']) : '';
|
26 |
-
|
|
|
27 |
<?php
|
28 |
// Generate message container by message id or directly by message.
|
29 |
-
$message_id =
|
30 |
-
$message =
|
31 |
-
echo
|
32 |
?>
|
33 |
<form
|
34 |
<?php echo $action ? 'action="' . $action . '"' : ''; ?>
|
@@ -40,7 +49,7 @@ class FMAdminView_fmc {
|
|
40 |
><?php
|
41 |
echo $content;
|
42 |
// Add nonce to form.
|
43 |
-
wp_nonce_field(
|
44 |
?>
|
45 |
<input id="task" name="task" type="hidden" value=""/>
|
46 |
<input id="current_id" name="current_id" type="hidden" value="<?php echo $current_id; ?>"/>
|
@@ -56,7 +65,7 @@ class FMAdminView_fmc {
|
|
56 |
*
|
57 |
* @return string Title html.
|
58 |
*/
|
59 |
-
protected function title($params) {
|
60 |
$title = !empty($params['title']) ? $params['title'] : '';
|
61 |
$title_class = !empty($params['title_class']) ? $params['title_class'] : '';
|
62 |
$title_name = !empty($params['title_name']) ? $params['title_name'] : '';
|
@@ -64,13 +73,12 @@ class FMAdminView_fmc {
|
|
64 |
$title_value = !empty($params['title_value']) ? $params['title_value'] : '';
|
65 |
$add_new_button = !empty($params['add_new_button']) ? $params['add_new_button'] : '';
|
66 |
|
67 |
-
|
68 |
if ( !empty($add_new_button) && is_array($add_new_button) ) {
|
69 |
foreach ( $add_new_button as $key => $val ) {
|
70 |
$attributes .= $key . '="' . $val . '"';
|
71 |
}
|
72 |
}
|
73 |
-
|
74 |
ob_start();
|
75 |
?><div class="wd-page-title <?php echo $title_class; ?>">
|
76 |
<h1 class="wp-heading-inline"><?php echo $title; ?>
|
@@ -85,7 +93,7 @@ class FMAdminView_fmc {
|
|
85 |
if ( $add_new_button ) {
|
86 |
?>
|
87 |
<a class="page-title-action" <?php echo $attributes; ?>>
|
88 |
-
<?php _e('Add New',
|
89 |
</a>
|
90 |
<?php
|
91 |
}
|
@@ -104,7 +112,7 @@ class FMAdminView_fmc {
|
|
104 |
*
|
105 |
* @return array Buttons html.
|
106 |
*/
|
107 |
-
protected function buttons($buttons = array(), $single = FALSE, $parent = array()) {
|
108 |
ob_start();
|
109 |
if ( !$single ) {
|
110 |
$parent_id = isset($parent['id']) ? esc_attr($parent['id']) : '';
|
@@ -149,12 +157,12 @@ class FMAdminView_fmc {
|
|
149 |
* @return string
|
150 |
*/
|
151 |
protected function search() {
|
152 |
-
$search =
|
153 |
ob_start();
|
154 |
?>
|
155 |
<p class="search-box">
|
156 |
<input name="s" value="<?php echo $search; ?>" type="search" onkeypress="return input_search(event, this)" />
|
157 |
-
<input class="button" value="<?php _e('Search',
|
158 |
</p>
|
159 |
<?php
|
160 |
|
@@ -171,10 +179,10 @@ class FMAdminView_fmc {
|
|
171 |
* @return string
|
172 |
*/
|
173 |
protected function pagination($page_url, $total, $items_per_page = 20) {
|
174 |
-
$page_number =
|
175 |
-
$search =
|
176 |
-
$orderby =
|
177 |
-
$order =
|
178 |
$url_arg = array();
|
179 |
if( !empty($search) ) {
|
180 |
$url_arg['s'] = $search;
|
@@ -202,7 +210,7 @@ class FMAdminView_fmc {
|
|
202 |
?>
|
203 |
<div class="tablenav-pages">
|
204 |
<span class="displaying-num">
|
205 |
-
<?php printf(_n('%s item', '%s items', $total,
|
206 |
</span>
|
207 |
<?php
|
208 |
if ( $total > $items_per_page ) {
|
@@ -217,16 +225,16 @@ class FMAdminView_fmc {
|
|
217 |
}
|
218 |
else {
|
219 |
?>
|
220 |
-
<a href="<?php echo add_query_arg(array('paged' => 1), $page_url); ?>" class="first-page"><span class="screen-reader-text"><?php _e('First page',
|
221 |
-
<a href="<?php echo add_query_arg(array('paged' => ($page_number == 1 ? 1 : ($page_number - 1))), $page_url); ?>" class="previous-page"><span class="screen-reader-text"><?php _e('Previous page',
|
222 |
<?php
|
223 |
}
|
224 |
?>
|
225 |
<span class="paging-input">
|
226 |
-
<label for="current-page-selector" class="screen-reader-text"><?php _e('Current Page',
|
227 |
<input type="text" class="current-page" name="current_page" value="<?php echo $page_number; ?>" onkeypress="return input_pagination(event, this)" size="1" />
|
228 |
<span class="tablenav-paging-text">
|
229 |
-
<?php _e('of',
|
230 |
<span class="total-pages"><?php echo $pages_count; ?></span>
|
231 |
</span>
|
232 |
</span>
|
@@ -239,8 +247,8 @@ class FMAdminView_fmc {
|
|
239 |
}
|
240 |
else {
|
241 |
?>
|
242 |
-
<a href="<?php echo add_query_arg(array('paged' => ($page_number >= $pages_count ? $pages_count : ($page_number + 1))), $page_url); ?>" class="next-page"><span class="screen-reader-text"><?php _e('Next page',
|
243 |
-
<a href="<?php echo add_query_arg(array('paged' => $pages_count), $page_url); ?>" class="last-page"><span class="screen-reader-text"><?php _e('Last page',
|
244 |
<?php
|
245 |
}
|
246 |
?>
|
@@ -258,9 +266,9 @@ class FMAdminView_fmc {
|
|
258 |
ob_start();
|
259 |
?>
|
260 |
<div class="alignleft actions bulkactions">
|
261 |
-
<label for="bulk-action-selector-top" class="screen-reader-text"><?php _e('Select bulk action',
|
262 |
<select name="bulk_action" id="bulk-action-selector-top">
|
263 |
-
<option value="-1"><?php _e('Bulk Actions',
|
264 |
<?php
|
265 |
foreach ( $actions as $key => $action ) {
|
266 |
?>
|
@@ -269,7 +277,7 @@ class FMAdminView_fmc {
|
|
269 |
}
|
270 |
?>
|
271 |
</select>
|
272 |
-
<input type="button" id="doaction" class="button action" onclick="wd_bulk_action(this)" value="<?php _e('Apply',
|
273 |
</div>
|
274 |
<?php
|
275 |
|
@@ -277,8 +285,292 @@ class FMAdminView_fmc {
|
|
277 |
}
|
278 |
|
279 |
function import_popup_div() {
|
280 |
-
if (
|
281 |
do_action('fm_popup_import_content');
|
282 |
}
|
283 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
284 |
}
|
5 |
* Admin view class.
|
6 |
*/
|
7 |
class FMAdminView_fmc {
|
8 |
+
/**
|
9 |
+
* PLUGIN = 2 points to Contact Form Maker
|
10 |
+
*/
|
11 |
+
const PLUGIN = 2;
|
12 |
+
|
13 |
+
private $premium_link = 'https://web-dorado.com/files/fromContactForm.php';
|
14 |
+
|
15 |
/**
|
16 |
* Generate form.
|
17 |
*
|
21 |
* @return string Form html.
|
22 |
*/
|
23 |
protected function form($content = '', $attr = array()) {
|
24 |
+
echo $this->topbar();
|
25 |
ob_start();
|
26 |
// Form.
|
27 |
$action = isset($attr['action']) ? esc_attr($attr['action']) : '';
|
28 |
$method = isset($attr['method']) ? esc_attr($attr['method']) : 'post';
|
29 |
+
$name = isset($attr['name']) ? esc_attr($attr['name']) : WDFMInstance(self::PLUGIN)->prefix . '_form';
|
30 |
$id = isset($attr['id']) ? esc_attr($attr['id']) : '';
|
31 |
+
$class = isset($attr['class']) ? esc_attr($attr['class']) : WDFMInstance(self::PLUGIN)->prefix . '_form';
|
32 |
$style = isset($attr['style']) ? esc_attr($attr['style']) : '';
|
33 |
$current_id = isset($attr['current_id']) ? esc_attr($attr['current_id']) : '';
|
34 |
+
?>
|
35 |
+
<div id="fm-form-admin" class="wrap">
|
36 |
<?php
|
37 |
// Generate message container by message id or directly by message.
|
38 |
+
$message_id = WDW_FM_Library(self::PLUGIN)->get('message', 0);
|
39 |
+
$message = WDW_FM_Library(self::PLUGIN)->get('msg', '');
|
40 |
+
echo WDW_FM_Library(self::PLUGIN)->message_id($message_id, $message);
|
41 |
?>
|
42 |
<form
|
43 |
<?php echo $action ? 'action="' . $action . '"' : ''; ?>
|
49 |
><?php
|
50 |
echo $content;
|
51 |
// Add nonce to form.
|
52 |
+
wp_nonce_field(WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce);
|
53 |
?>
|
54 |
<input id="task" name="task" type="hidden" value=""/>
|
55 |
<input id="current_id" name="current_id" type="hidden" value="<?php echo $current_id; ?>"/>
|
65 |
*
|
66 |
* @return string Title html.
|
67 |
*/
|
68 |
+
protected function title( $params = array() ) {
|
69 |
$title = !empty($params['title']) ? $params['title'] : '';
|
70 |
$title_class = !empty($params['title_class']) ? $params['title_class'] : '';
|
71 |
$title_name = !empty($params['title_name']) ? $params['title_name'] : '';
|
73 |
$title_value = !empty($params['title_value']) ? $params['title_value'] : '';
|
74 |
$add_new_button = !empty($params['add_new_button']) ? $params['add_new_button'] : '';
|
75 |
|
76 |
+
$attributes = '';
|
77 |
if ( !empty($add_new_button) && is_array($add_new_button) ) {
|
78 |
foreach ( $add_new_button as $key => $val ) {
|
79 |
$attributes .= $key . '="' . $val . '"';
|
80 |
}
|
81 |
}
|
|
|
82 |
ob_start();
|
83 |
?><div class="wd-page-title <?php echo $title_class; ?>">
|
84 |
<h1 class="wp-heading-inline"><?php echo $title; ?>
|
93 |
if ( $add_new_button ) {
|
94 |
?>
|
95 |
<a class="page-title-action" <?php echo $attributes; ?>>
|
96 |
+
<?php _e('Add New', WDFMInstance(self::PLUGIN)->prefix); ?>
|
97 |
</a>
|
98 |
<?php
|
99 |
}
|
112 |
*
|
113 |
* @return array Buttons html.
|
114 |
*/
|
115 |
+
protected function buttons( $buttons = array(), $single = FALSE, $parent = array() ) {
|
116 |
ob_start();
|
117 |
if ( !$single ) {
|
118 |
$parent_id = isset($parent['id']) ? esc_attr($parent['id']) : '';
|
157 |
* @return string
|
158 |
*/
|
159 |
protected function search() {
|
160 |
+
$search = WDW_FM_Library(self::PLUGIN)->get('s', '');
|
161 |
ob_start();
|
162 |
?>
|
163 |
<p class="search-box">
|
164 |
<input name="s" value="<?php echo $search; ?>" type="search" onkeypress="return input_search(event, this)" />
|
165 |
+
<input class="button" value="<?php _e('Search', WDFMInstance(self::PLUGIN)->prefix); ?>" type="button" onclick="search(this)" />
|
166 |
</p>
|
167 |
<?php
|
168 |
|
179 |
* @return string
|
180 |
*/
|
181 |
protected function pagination($page_url, $total, $items_per_page = 20) {
|
182 |
+
$page_number = WDW_FM_Library(self::PLUGIN)->get('paged', 1);
|
183 |
+
$search = WDW_FM_Library(self::PLUGIN)->get('s', '');
|
184 |
+
$orderby = WDW_FM_Library(self::PLUGIN)->get('orderby', '');
|
185 |
+
$order = WDW_FM_Library(self::PLUGIN)->get('order', '');
|
186 |
$url_arg = array();
|
187 |
if( !empty($search) ) {
|
188 |
$url_arg['s'] = $search;
|
210 |
?>
|
211 |
<div class="tablenav-pages">
|
212 |
<span class="displaying-num">
|
213 |
+
<?php printf(_n('%s item', '%s items', $total, WDFMInstance(self::PLUGIN)->prefix), $total); ?>
|
214 |
</span>
|
215 |
<?php
|
216 |
if ( $total > $items_per_page ) {
|
225 |
}
|
226 |
else {
|
227 |
?>
|
228 |
+
<a href="<?php echo add_query_arg(array('paged' => 1), $page_url); ?>" class="first-page"><span class="screen-reader-text"><?php _e('First page', WDFMInstance(self::PLUGIN)->prefix); ?></span><span aria-hidden="true">«</span></a>
|
229 |
+
<a href="<?php echo add_query_arg(array('paged' => ($page_number == 1 ? 1 : ($page_number - 1))), $page_url); ?>" class="previous-page"><span class="screen-reader-text"><?php _e('Previous page', WDFMInstance(self::PLUGIN)->prefix); ?></span><span aria-hidden="true">‹</span></a>
|
230 |
<?php
|
231 |
}
|
232 |
?>
|
233 |
<span class="paging-input">
|
234 |
+
<label for="current-page-selector" class="screen-reader-text"><?php _e('Current Page', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
235 |
<input type="text" class="current-page" name="current_page" value="<?php echo $page_number; ?>" onkeypress="return input_pagination(event, this)" size="1" />
|
236 |
<span class="tablenav-paging-text">
|
237 |
+
<?php _e('of', WDFMInstance(self::PLUGIN)->prefix); ?>
|
238 |
<span class="total-pages"><?php echo $pages_count; ?></span>
|
239 |
</span>
|
240 |
</span>
|
247 |
}
|
248 |
else {
|
249 |
?>
|
250 |
+
<a href="<?php echo add_query_arg(array('paged' => ($page_number >= $pages_count ? $pages_count : ($page_number + 1))), $page_url); ?>" class="next-page"><span class="screen-reader-text"><?php _e('Next page', WDFMInstance(self::PLUGIN)->prefix); ?></span><span aria-hidden="true">›</span></a>
|
251 |
+
<a href="<?php echo add_query_arg(array('paged' => $pages_count), $page_url); ?>" class="last-page"><span class="screen-reader-text"><?php _e('Last page', WDFMInstance(self::PLUGIN)->prefix); ?></span><span aria-hidden="true">»</span></a>
|
252 |
<?php
|
253 |
}
|
254 |
?>
|
266 |
ob_start();
|
267 |
?>
|
268 |
<div class="alignleft actions bulkactions">
|
269 |
+
<label for="bulk-action-selector-top" class="screen-reader-text"><?php _e('Select bulk action', WDFMInstance(self::PLUGIN)->prefix); ?></label>
|
270 |
<select name="bulk_action" id="bulk-action-selector-top">
|
271 |
+
<option value="-1"><?php _e('Bulk Actions', WDFMInstance(self::PLUGIN)->prefix); ?></option>
|
272 |
<?php
|
273 |
foreach ( $actions as $key => $action ) {
|
274 |
?>
|
277 |
}
|
278 |
?>
|
279 |
</select>
|
280 |
+
<input type="button" id="doaction" class="button action" onclick="wd_bulk_action(this)" value="<?php _e('Apply', WDFMInstance(self::PLUGIN)->prefix); ?>" />
|
281 |
</div>
|
282 |
<?php
|
283 |
|
285 |
}
|
286 |
|
287 |
function import_popup_div() {
|
288 |
+
if (WDFMInstance(self::PLUGIN)->is_free != 2) {
|
289 |
do_action('fm_popup_import_content');
|
290 |
}
|
291 |
}
|
292 |
+
|
293 |
+
/**
|
294 |
+
* Generate top bar.
|
295 |
+
*
|
296 |
+
* @return string Top bar html.
|
297 |
+
*/
|
298 |
+
protected function topbar() {
|
299 |
+
$page = isset($_GET['page']) ? esc_html($_GET['page']) : '';
|
300 |
+
$page = str_replace(WDFMInstance(self::PLUGIN)->menu_postfix, '', $page);
|
301 |
+
$task = isset($_REQUEST['task']) ? esc_html($_REQUEST['task']) : '';
|
302 |
+
$user_guide_link = 'https://web-dorado.com/wordpress-form-maker/';
|
303 |
+
$show_content = true;
|
304 |
+
$show_guide_link = true;
|
305 |
+
$show_head = false;
|
306 |
+
switch ($page) {
|
307 |
+
case 'blocked_ips': {
|
308 |
+
$user_guide_link .= 'submissions.html';
|
309 |
+
break;
|
310 |
+
}
|
311 |
+
case 'options': {
|
312 |
+
$user_guide_link .= 'themes-and-options.html';
|
313 |
+
break;
|
314 |
+
}
|
315 |
+
case 'pricing': {
|
316 |
+
$show_content = false;
|
317 |
+
$show_guide_link = false;
|
318 |
+
$show_head = true;
|
319 |
+
$user_guide_link .= '';
|
320 |
+
break;
|
321 |
+
}
|
322 |
+
case 'manage': {
|
323 |
+
switch ( $task ) {
|
324 |
+
case 'add':
|
325 |
+
case 'edit':
|
326 |
+
case 'edit_old': {
|
327 |
+
$user_guide_link .= 'form-fields/basic-fields.html';
|
328 |
+
break;
|
329 |
+
}
|
330 |
+
case 'form_options':
|
331 |
+
case 'form_options_old': {
|
332 |
+
$user_guide_link .= 'form-options/general-options.html';
|
333 |
+
break;
|
334 |
+
}
|
335 |
+
case 'display_options': {
|
336 |
+
$user_guide_link .= 'display-options-publishing/configuring-display-options.html';
|
337 |
+
break;
|
338 |
+
}
|
339 |
+
default: {
|
340 |
+
$user_guide_link .= 'creating-form.html';
|
341 |
+
$show_content = false;
|
342 |
+
$show_head = true;
|
343 |
+
}
|
344 |
+
}
|
345 |
+
break;
|
346 |
+
}
|
347 |
+
case 'submissions': {
|
348 |
+
$user_guide_link .= 'submissions.html';
|
349 |
+
break;
|
350 |
+
}
|
351 |
+
case 'themes': {
|
352 |
+
$user_guide_link .= 'themes-and-options.html';
|
353 |
+
break;
|
354 |
+
}
|
355 |
+
case 'addons': {
|
356 |
+
$show_content = false;
|
357 |
+
$show_head = true;
|
358 |
+
$user_guide_link .= '';
|
359 |
+
break;
|
360 |
+
}
|
361 |
+
default: {
|
362 |
+
return '';
|
363 |
+
}
|
364 |
+
}
|
365 |
+
$show_content = $show_content && WDFMInstance(self::PLUGIN)->is_free;
|
366 |
+
$support_forum_link = 'https://wordpress.org/support/plugin/' . (WDFMInstance(self::PLUGIN)->is_free == 2 ? 'contact-form-maker' : 'form-maker');
|
367 |
+
$premium_link = $this->premium_link;
|
368 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-roboto');
|
369 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-pricing');
|
370 |
+
ob_start();
|
371 |
+
?>
|
372 |
+
<div class="wrap">
|
373 |
+
<h1 class="fm-head-notice"> </h1>
|
374 |
+
<div class="fm-topbar-container">
|
375 |
+
<?php
|
376 |
+
if ($show_content) {
|
377 |
+
?>
|
378 |
+
<div class="fm-topbar fm-topbar-content">
|
379 |
+
<div class="fm-topbar-content-container">
|
380 |
+
<div class="fm-topbar-content-title">
|
381 |
+
<?php _e('Form Maker Premium', WDFMInstance(self::PLUGIN)->prefix); ?>
|
382 |
+
</div>
|
383 |
+
<div class="fm-topbar-content-body">
|
384 |
+
<?php _e('Add unlimited fields, create multi-page forms with fully customizable themes and much more.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
385 |
+
</div>
|
386 |
+
</div>
|
387 |
+
<div class="fm-topbar-content-button-container">
|
388 |
+
<a href="<?php echo $premium_link; ?>" target="_blank" class="fm-topbar-upgrade-button"><?php _e( 'Upgrade', WDFMInstance(self::PLUGIN)->prefix ); ?></a>
|
389 |
+
</div>
|
390 |
+
</div>
|
391 |
+
<?php
|
392 |
+
}
|
393 |
+
?>
|
394 |
+
<div class="fm-topbar fm-topbar-links">
|
395 |
+
<div class="fm-topbar-links-container">
|
396 |
+
<?php if ( $show_guide_link ) { ?>
|
397 |
+
<a href="<?php echo $user_guide_link; ?>" target="_blank">
|
398 |
+
<div class="fm-topbar-links-item">
|
399 |
+
<?php _e('User guide', WDFMInstance(self::PLUGIN)->prefix); ?>
|
400 |
+
</div>
|
401 |
+
</a>
|
402 |
+
<?php
|
403 |
+
}
|
404 |
+
if (WDFMInstance(self::PLUGIN)->is_free) {
|
405 |
+
if ( $show_guide_link ) {
|
406 |
+
?>
|
407 |
+
<span class="fm-topbar-separator"></span>
|
408 |
+
<?php } ?>
|
409 |
+
<a href="<?php echo $support_forum_link; ?>" target="_blank">
|
410 |
+
<div class="fm-topbar-links-item">
|
411 |
+
<?php _e('Support Forum', WDFMInstance(self::PLUGIN)->prefix); ?>
|
412 |
+
</div>
|
413 |
+
</a>
|
414 |
+
<?php
|
415 |
+
}
|
416 |
+
?>
|
417 |
+
</div>
|
418 |
+
</div>
|
419 |
+
</div>
|
420 |
+
<?php if ( $show_head ) {
|
421 |
+
$menus = array(
|
422 |
+
'manage' => array(
|
423 |
+
'href' => add_query_arg( array('page' => 'manage' . WDFMInstance(self::PLUGIN)->menu_postfix ), admin_url('admin.php')),
|
424 |
+
'name' => __('Forms', WDFMInstance(self::PLUGIN)->prefix)
|
425 |
+
),
|
426 |
+
'addons' => array(
|
427 |
+
'href' => add_query_arg( array('page' => 'addons' . WDFMInstance(self::PLUGIN)->menu_postfix ), admin_url('admin.php')),
|
428 |
+
'name' => __('Add-ons', WDFMInstance(self::PLUGIN)->prefix)
|
429 |
+
),
|
430 |
+
'pricing' => array(
|
431 |
+
'href' => add_query_arg( array('page' => 'pricing' . WDFMInstance(self::PLUGIN)->menu_postfix ), admin_url('admin.php')),
|
432 |
+
'name' => __('Premium Version', WDFMInstance(self::PLUGIN)->prefix) .' <span class="fm-upgrade">' . __('Upgrade', WDFMInstance(self::PLUGIN)->prefix) . '</span>'
|
433 |
+
),
|
434 |
+
);
|
435 |
+
?>
|
436 |
+
<style>#wpbody-content>div:not(.wrap), .wrap .notice:not(#wd_bp_notice_cont) { display: none; }</style>
|
437 |
+
<div class="fm-head">
|
438 |
+
<div><img src="<?php echo WDFMInstance(self::PLUGIN)->plugin_url . '/images/FormMaker.png'; ?>"></div>
|
439 |
+
<ul class="fm-breadcrumbs">
|
440 |
+
<?php
|
441 |
+
foreach ( $menus as $key => $item ) {
|
442 |
+
if ( !WDFMInstance(self::PLUGIN)->is_free && $key == 'pricing' ) {
|
443 |
+
continue;
|
444 |
+
}
|
445 |
+
?>
|
446 |
+
<li class="fm-breadcrumb-item">
|
447 |
+
<a class="fm-breadcrumb-item-link<?php echo ( $key == $page ) ? ' fm-breadcrumb-item-link-active' : ''; ?>" href="<?php echo $item['href']; ?>"><?php echo $item['name']; ?></a>
|
448 |
+
</li>
|
449 |
+
<?php
|
450 |
+
}
|
451 |
+
?>
|
452 |
+
</ul>
|
453 |
+
</div>
|
454 |
+
<?php } ?>
|
455 |
+
</div>
|
456 |
+
<?php
|
457 |
+
return ob_get_clean();
|
458 |
+
}
|
459 |
+
|
460 |
+
/**
|
461 |
+
* @param $message
|
462 |
+
* @param string $premium_link
|
463 |
+
* @param string $premium_link_text
|
464 |
+
* @return string
|
465 |
+
*/
|
466 |
+
protected function free_message($message, $premium_link = '', $premium_link_text = '', $id = '') {
|
467 |
+
$upgrade = false;
|
468 |
+
if ('' == $premium_link) {
|
469 |
+
$premium_link = $this->premium_link;
|
470 |
+
}
|
471 |
+
if ('' == $premium_link_text) {
|
472 |
+
$premium_link_text = __( 'Upgrade', WDFMInstance(self::PLUGIN)->prefix );
|
473 |
+
$upgrade = true;
|
474 |
+
}
|
475 |
+
ob_start();
|
476 |
+
?>
|
477 |
+
<div class="fm-free-message" <?php if ($id) { echo 'id="' . $id . '"'; } ?>>
|
478 |
+
<div class="fm-free-message-body">
|
479 |
+
<?php echo $message; ?>
|
480 |
+
</div>
|
481 |
+
<div class="fm-free-message-button-container">
|
482 |
+
<a href="<?php echo $premium_link; ?>" target="_blank" class="fm-free-message-upgrade-button <?php if(!$upgrade) {echo 'fm-free-message-promo-button'; } ?>"><?php echo $premium_link_text; ?></a>
|
483 |
+
</div>
|
484 |
+
</div>
|
485 |
+
<?php
|
486 |
+
return ob_get_clean();
|
487 |
+
}
|
488 |
+
|
489 |
+
/**
|
490 |
+
* Generate stripe promo box.
|
491 |
+
*
|
492 |
+
* @param $message
|
493 |
+
* @param $addon_message
|
494 |
+
* @param $addon_link
|
495 |
+
*
|
496 |
+
* @return string Stripe promo box html.
|
497 |
+
*/
|
498 |
+
protected function promo_box($message, $addon_message, $addon_link, $id = '') {
|
499 |
+
$premium_link = $this->premium_link;
|
500 |
+
ob_start();
|
501 |
+
?>
|
502 |
+
<div class="fm-free-message fm-promo-message" <?php if ($id) { echo 'id="' . $id . '"'; } ?>>
|
503 |
+
<div class="fm-free-message-body">
|
504 |
+
<?php echo $message; ?>
|
505 |
+
</div>
|
506 |
+
<div class="fm-free-message-button-container">
|
507 |
+
<a href="<?php echo $premium_link; ?>" target="_blank" class="fm-free-message-upgrade-button"><?php _e( 'Upgrade', WDFMInstance(self::PLUGIN)->prefix ); ?></a>
|
508 |
+
</div>
|
509 |
+
<div class="fm-free-message-body fm-free-message-huge">
|
510 |
+
&
|
511 |
+
</div>
|
512 |
+
<div class="fm-free-message-body">
|
513 |
+
<?php echo $addon_message; ?>
|
514 |
+
</div>
|
515 |
+
<div class="fm-free-message-button-container">
|
516 |
+
<a href="<?php echo $addon_link; ?>" target="_blank" class="fm-free-message-upgrade-button fm-free-message-promo-button"><?php _e( 'Buy', WDFMInstance(self::PLUGIN)->prefix ); ?></a>
|
517 |
+
</div>
|
518 |
+
</div>
|
519 |
+
<?php
|
520 |
+
return ob_get_clean();
|
521 |
+
}
|
522 |
+
|
523 |
+
/**
|
524 |
+
* Generate limitation aler.
|
525 |
+
*
|
526 |
+
* @return string Limitation alert html.
|
527 |
+
*/
|
528 |
+
protected function limitation_alert() {
|
529 |
+
$premium_link = $this->premium_link;
|
530 |
+
ob_start();
|
531 |
+
?>
|
532 |
+
<div class="fm-limitation-alert-container fm-hidden">
|
533 |
+
<div class="fm-limitation-alert-overlay"></div>
|
534 |
+
<div class="fm-limitation-alert">
|
535 |
+
<span class="dashicons dashicons-no-alt"></span>
|
536 |
+
<div class="fm-limitation-alert-header">
|
537 |
+
<?php _e('The free version is limited up to 7 fields.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
538 |
+
</div>
|
539 |
+
<div class="fm-limitation-alert-header">
|
540 |
+
<?php _e('Upgrade to Premium version to add unlimited fields.', WDFMInstance(self::PLUGIN)->prefix); ?>
|
541 |
+
</div>
|
542 |
+
<div class="fm-limitation-alert-body">
|
543 |
+
<div class="fm-limitation-alert-header">
|
544 |
+
<?php _e('Premium Plan also includes:', WDFMInstance(self::PLUGIN)->prefix); ?>
|
545 |
+
</div>
|
546 |
+
<ul>
|
547 |
+
<li><?php _e('Payment integration fields', WDFMInstance(self::PLUGIN)->prefix); ?></li>
|
548 |
+
<li><?php _e('File upload field', WDFMInstance(self::PLUGIN)->prefix); ?></li>
|
549 |
+
<li><?php _e('Google Maps API Integration', WDFMInstance(self::PLUGIN)->prefix); ?></li>
|
550 |
+
<li><?php _e('Front-end Submissions', WDFMInstance(self::PLUGIN)->prefix); ?></li>
|
551 |
+
</ul>
|
552 |
+
</div>
|
553 |
+
<div class="fm-free-message-button-container">
|
554 |
+
<a href="<?php echo $premium_link; ?>" target="_blank" class="fm-free-message-upgrade-button"><?php _e( 'Upgrade', WDFMInstance(self::PLUGIN)->prefix ); ?></a>
|
555 |
+
</div>
|
556 |
+
</div>
|
557 |
+
</div>
|
558 |
+
<script>
|
559 |
+
function fm_limitation_alert(show) {
|
560 |
+
if (show) {
|
561 |
+
jQuery('.fm-limitation-alert-container').removeClass('fm-hidden');
|
562 |
+
}
|
563 |
+
else {
|
564 |
+
jQuery('.fm-limitation-alert-container').addClass('fm-hidden');
|
565 |
+
}
|
566 |
+
}
|
567 |
+
jQuery(document).ready(function() {
|
568 |
+
jQuery('.fm-limitation-alert-overlay, .fm-limitation-alert .dashicons-no-alt').on('click', function() {
|
569 |
+
fm_limitation_alert(false);
|
570 |
+
});
|
571 |
+
});
|
572 |
+
</script>
|
573 |
+
<?php
|
574 |
+
return ob_get_clean();
|
575 |
+
}
|
576 |
}
|
assets/add-ons-icon.png
DELETED
Binary file
|
assets/calculator.png
DELETED
Binary file
|
assets/conditional-emails-update.png
DELETED
Binary file
|
assets/dropbox-integration-update.png
DELETED
Binary file
|
assets/form-maker.png
DELETED
Binary file
|
assets/google_drive_integration.png
DELETED
Binary file
|
assets/import_export.png
DELETED
Binary file
|
assets/mailchimp.png
DELETED
Binary file
|
assets/pdf-integration.png
DELETED
Binary file
|
assets/post-generation-update.png
DELETED
Binary file
|
assets/pushover.png
DELETED
Binary file
|
assets/reg.png
DELETED
Binary file
|
assets/save-progress.png
DELETED
Binary file
|
assets/stripe-integration-update.png
DELETED
Binary file
|
assets/updates_icon.jpg
DELETED
Binary file
|
contact-form-maker.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Contact Form Maker
|
4 |
* Plugin URI: https://web-dorado.com/products/form-maker-wordpress.html
|
5 |
* Description: WordPress Contact Form Maker is a simple contact form builder, which allows the user with almost no knowledge of programming to create and edit different type of contact forms.
|
6 |
-
* Version: 1.12.
|
7 |
* Author: WebDorado Form Builder Team
|
8 |
* Author URI: https://web-dorado.com/wordpress-plugins-bundle.html
|
9 |
* License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
|
@@ -12,6 +12,11 @@
|
|
12 |
defined('ABSPATH') || die('Access Denied');
|
13 |
|
14 |
final class WDCFM {
|
|
|
|
|
|
|
|
|
|
|
15 |
/**
|
16 |
* The single instance of the class.
|
17 |
*/
|
@@ -24,7 +29,7 @@ final class WDCFM {
|
|
24 |
* Plugin directory url.
|
25 |
*/
|
26 |
public $plugin_url = '';
|
27 |
-
|
28 |
* Plugin front urls.
|
29 |
*/
|
30 |
public $front_urls = array();
|
@@ -57,12 +62,12 @@ final class WDCFM {
|
|
57 |
public $is_demo = false;
|
58 |
|
59 |
/**
|
60 |
-
* Main
|
61 |
*
|
62 |
* Ensures only one instance is loaded or can be loaded.
|
63 |
*
|
64 |
* @static
|
65 |
-
* @return
|
66 |
*/
|
67 |
public static function instance() {
|
68 |
if ( is_null( self::$_instance ) ) {
|
@@ -71,13 +76,12 @@ final class WDCFM {
|
|
71 |
return self::$_instance;
|
72 |
}
|
73 |
|
74 |
-
/**
|
75 |
-
* WDCFM Constructor.
|
76 |
-
*/
|
77 |
public function __construct() {
|
78 |
$this->define_constants();
|
79 |
require_once($this->plugin_dir . '/framework/WDW_FM_Library.php');
|
80 |
if (is_admin()) {
|
|
|
|
|
81 |
require_once(wp_normalize_path($this->plugin_dir . '/admin/views/view.php'));
|
82 |
}
|
83 |
$this->add_actions();
|
@@ -87,19 +91,20 @@ final class WDCFM {
|
|
87 |
* Define Constants.
|
88 |
*/
|
89 |
private function define_constants() {
|
90 |
-
|
91 |
$this->plugin_url = plugins_url(plugin_basename(dirname(__FILE__)));
|
92 |
-
|
93 |
$this->main_file = plugin_basename(__FILE__);
|
94 |
-
$this->plugin_version = '1.12.
|
95 |
-
$this->db_version = '2.12.
|
96 |
-
$this->
|
97 |
-
$this->
|
|
|
|
|
98 |
$this->css_prefix = 'fm_';
|
99 |
$this->js_prefix = 'fm_';
|
100 |
-
$this->
|
101 |
-
$this->
|
102 |
-
$this->plugin_postfix = '_fmc';
|
103 |
}
|
104 |
|
105 |
/**
|
@@ -174,7 +179,7 @@ final class WDCFM {
|
|
174 |
|
175 |
// Form Maker Widget.
|
176 |
if (class_exists('WP_Widget')) {
|
177 |
-
add_action('widgets_init',
|
178 |
}
|
179 |
|
180 |
// Form maker activation.
|
@@ -183,7 +188,6 @@ final class WDCFM {
|
|
183 |
&& (!isset($_GET['page']) || $_GET['page'] != 'uninstall' . $this->menu_postfix) ) {
|
184 |
add_action('admin_init', array($this, 'form_maker_activate'));
|
185 |
}
|
186 |
-
add_action('admin_notices', array($this, 'fm_topic'), 11);
|
187 |
|
188 |
// Register scripts/styles.
|
189 |
add_action('wp_enqueue_scripts', array($this, 'register_frontend_scripts'));
|
@@ -197,9 +201,13 @@ final class WDCFM {
|
|
197 |
add_action('admin_notices', array($this, 'fm_check_addons_compatibility'));
|
198 |
}
|
199 |
|
200 |
-
add_action('plugins_loaded', array($this, 'plugins_loaded'));
|
201 |
|
202 |
-
|
|
|
|
|
|
|
|
|
203 |
// Privacy policy.
|
204 |
add_action( 'admin_init', array($this, 'add_privacy_policy_content') );
|
205 |
}
|
@@ -209,14 +217,99 @@ final class WDCFM {
|
|
209 |
return;
|
210 |
}
|
211 |
|
212 |
-
$content = __( 'All data submitted by website visitors is stored in website database. With every form submission Form Maker plugin collects users’ IP address and WordPress user ID for logged in users.<br />In the following forms <b>[List of Forms that collect personal data]</b> we collect personal data, such as <b>[Types of personal data collected]</b>. We need this information to <b>[purpose of collecting personal data]</b>. Please see sections <b>[Links to sections]</b> on how your personal data is handled.',
|
213 |
|
214 |
wp_add_privacy_policy_content(
|
215 |
-
|
216 |
wp_kses_post( wpautop( $content, false ) )
|
217 |
);
|
218 |
}
|
219 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
220 |
/**
|
221 |
* Wordpress init actions.
|
222 |
*/
|
@@ -237,6 +330,11 @@ final class WDCFM {
|
|
237 |
public function plugins_loaded() {
|
238 |
// Languages localization.
|
239 |
load_plugin_textdomain($this->prefix, FALSE, basename(dirname(__FILE__)) . '/languages');
|
|
|
|
|
|
|
|
|
|
|
240 |
// Initialize add-ons.
|
241 |
if ($this->is_free != 2) {
|
242 |
do_action('fm_init_addons');
|
@@ -248,7 +346,7 @@ final class WDCFM {
|
|
248 |
*/
|
249 |
public function form_maker_options_panel() {
|
250 |
$parent_slug = !$this->is_free ? $this->menu_slug : null;
|
251 |
-
if( get_option( "cfm_subscribe_done" ) == 1 ) {
|
252 |
add_menu_page($this->nicename, $this->nicename, 'manage_options', $this->menu_slug, array( $this, 'form_maker' ), $this->plugin_url . '/images/FormMakerLogo-16.png');
|
253 |
$parent_slug = $this->menu_slug;
|
254 |
}
|
@@ -258,12 +356,12 @@ final class WDCFM {
|
|
258 |
|
259 |
add_submenu_page(null, __('Blocked IPs', $this->prefix), __('Blocked IPs', $this->prefix), 'manage_options', 'blocked_ips' . $this->menu_postfix, array($this, 'form_maker'));
|
260 |
add_submenu_page($parent_slug, __('Themes', $this->prefix), __('Themes', $this->prefix), 'manage_options', 'themes' . $this->menu_postfix, array($this, 'form_maker'));
|
261 |
-
|
262 |
-
|
263 |
-
add_submenu_page($parent_slug, __('
|
264 |
}
|
265 |
add_submenu_page(null, __('Uninstall', $this->prefix), __('Uninstall', $this->prefix), 'manage_options', 'uninstall' . $this->menu_postfix, array($this, 'form_maker'));
|
266 |
-
|
267 |
}
|
268 |
|
269 |
/**
|
@@ -284,7 +382,12 @@ final class WDCFM {
|
|
284 |
*/
|
285 |
private function set_front_upload_url() {
|
286 |
$wp_upload_dir = wp_upload_dir();
|
287 |
-
$upload_url =
|
|
|
|
|
|
|
|
|
|
|
288 |
|
289 |
return $upload_url;
|
290 |
}
|
@@ -340,13 +443,13 @@ final class WDCFM {
|
|
340 |
else {
|
341 |
die('Access Denied');
|
342 |
}
|
343 |
-
$page =
|
344 |
-
if (($page != '') && (($page == 'manage' . $this->menu_postfix) || ($page == 'options' . $this->menu_postfix) || ($page == 'submissions' . $this->menu_postfix) || ($page == 'blocked_ips' . $this->menu_postfix) || ($page == 'themes' . $this->menu_postfix) || ($page == 'uninstall' . $this->menu_postfix) || ($page == '
|
345 |
$page = ucfirst(substr($page, 0, strlen($page) - strlen($this->menu_postfix)));
|
346 |
// This ugly span is here to hide admin output while css files are not loaded. Temporary.
|
347 |
// todo: Remove span somehow.
|
348 |
echo '<div id="fm_loading"></div>';
|
349 |
-
echo '<span id="fm_admin_container" class="fm-form-container
|
350 |
require_once ($this->plugin_dir . '/admin/controllers/' . $page . '_fm.php');
|
351 |
$controller_class = 'FMController' . $page . $this->menu_postfix;
|
352 |
$controller = new $controller_class();
|
@@ -354,29 +457,13 @@ final class WDCFM {
|
|
354 |
echo '</span>';
|
355 |
}
|
356 |
}
|
357 |
-
|
358 |
-
/**
|
359 |
-
* Output for Add-on pages.
|
360 |
-
*/
|
361 |
-
public function fm_extensions() {
|
362 |
-
if ( function_exists('current_user_can') ) {
|
363 |
-
if ( !current_user_can('manage_options') ) {
|
364 |
-
die('Access Denied');
|
365 |
-
}
|
366 |
-
}
|
367 |
-
else {
|
368 |
-
die('Access Denied');
|
369 |
-
}
|
370 |
-
require_once($this->plugin_dir . '/featured/featured.php');
|
371 |
-
fm_extensions_page('form-maker');
|
372 |
-
}
|
373 |
|
374 |
-
|
375 |
* Register widgets.
|
376 |
*/
|
377 |
public function register_widgets() {
|
378 |
-
|
379 |
-
|
380 |
}
|
381 |
|
382 |
/**
|
@@ -384,41 +471,40 @@ final class WDCFM {
|
|
384 |
*/
|
385 |
public function register_admin_scripts() {
|
386 |
// Admin styles.
|
387 |
-
wp_register_style('
|
388 |
-
wp_register_style('
|
389 |
-
wp_register_style('
|
390 |
-
wp_register_style('
|
391 |
-
wp_register_style('
|
392 |
-
wp_register_style('
|
393 |
-
wp_register_style('
|
394 |
-
wp_register_style('
|
395 |
-
wp_register_style('
|
|
|
|
|
|
|
396 |
if (!$this->is_free) {
|
397 |
wp_register_style('jquery.fancybox', $this->plugin_url . '/js/fancybox/jquery.fancybox.css', array(), '2.1.5');
|
398 |
}
|
399 |
-
// Add-ons page
|
400 |
-
wp_register_style('fm-featured', $this->plugin_url . '/featured/style.css', array(), $this->plugin_version);
|
401 |
-
wp_register_style('fm-featured-admin', $this->plugin_url . '/featured/admin.css', array(), $this->plugin_version);
|
402 |
-
|
403 |
// Admin scripts.
|
404 |
-
$fm_settings = get_option('fmc_settings');
|
405 |
$google_map_key = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
406 |
|
407 |
wp_register_script('google-maps', 'https://maps.google.com/maps/api/js?v=3.exp' . $google_map_key);
|
408 |
-
wp_register_script('
|
409 |
-
|
410 |
-
wp_register_script('
|
411 |
-
|
412 |
-
wp_register_script('
|
413 |
-
wp_register_script('
|
414 |
-
wp_register_script('
|
415 |
-
wp_register_script('
|
416 |
-
wp_register_script('
|
417 |
-
wp_register_script('
|
418 |
-
wp_register_script('
|
419 |
-
wp_localize_script('
|
420 |
-
'countries' =>
|
421 |
-
'states' =>
|
422 |
'plugin_url' => $this->plugin_url,
|
423 |
'nothing_found' => __('Nothing found.', $this->prefix),
|
424 |
'captcha_created' => __('The captcha already has been created.', $this->prefix),
|
@@ -426,10 +512,6 @@ final class WDCFM {
|
|
426 |
'add' => __('Add', $this->prefix),
|
427 |
'add_field' => __('Add Field', $this->prefix),
|
428 |
'edit_field' => __('Edit Field', $this->prefix),
|
429 |
-
'disabled1' => __('This field type is disabled in free version.', $this->prefix),
|
430 |
-
'disabled2' => __('Please upgrade to Paid version.', $this->prefix),
|
431 |
-
'stripe1' => __('Please install ', $this->prefix),
|
432 |
-
'stripe2' => __(' add-on to use this feature.', $this->prefix),
|
433 |
'stripe3' => __('To use this feature, please go to Form Options > Payment Options and select "Stripe" as the Payment Method.', $this->prefix),
|
434 |
'sunday' => __('Sunday', $this->prefix),
|
435 |
'monday' => __('Monday', $this->prefix),
|
@@ -451,7 +533,7 @@ final class WDCFM {
|
|
451 |
'type_checkbox_description' => __('Multiple Choice field lets you have a list of Checkboxes. This field allows the submitter to choose more than one values.', $this->prefix).'<br><br>'.__('Just click (+) Option button and fill in all options you will need or click (+) From Database to fill the options from a database table.', $this->prefix).'<br><br>'.__('Relative Position lets you choose the position of options in relation to each other. Whereas Option Label Position lets you select the position of radio button label.', $this->prefix).'<br><br>'.__('In case you need to have option values to be different from option names, mark Enable option\'s value from Advanced options as checked.', $this->prefix).'<br><br>'.__('And by enabling Allow other, you can let the user to write their own specific value.', $this->prefix),
|
452 |
'type_recaptcha_description' => sprintf(__('Form Maker is integrated with Google ReCaptcha, which protects your forms from spam bots. Before adding ReCaptcha to your form, you need to configure Site and Secret Keys by registering your website on %s', $this->prefix),'<a href="https://www.google.com/recaptcha/intro/" target="_blank">'. __('Google ReCaptcha website', $this->prefix) .'</a>').'<br><br>'.__('After registering and creating the keys, copy them to Form Maker > Options page.', $this->prefix),
|
453 |
'type_submit_description' => __('The Submit button validates all form field values, saves them on MySQL database of your website, sends emails and performs other actions configured in Form Options. You can have more than one submit button in your form.', $this->prefix),
|
454 |
-
'type_captcha_description' => __('You can use this field as an alternative to ReCaptcha to protect your forms against spambots. It
|
455 |
'type_name_description' => __('This field lets the user write their name.', $this->prefix).'<br><br>'.__('To set a default value, just fill the field above.', $this->prefix).'<br><br>'.__('Enabling Autofill with user name setting will automatically fill in Name field with the name of the logged in user.', $this->prefix).'<br><br>'.__('In case you do not wish to receive the same data for the same Name field twice, activate Allow only unique values option.', $this->prefix),
|
456 |
'type_email_description' => __('This field is an input field that accepts an email address.', $this->prefix).'<br><br>'.__('To set a default value, just fill the field above.', $this->prefix).'<br><br>'.__('Using Confirmation Email setting in Advanced Options you can require the submitter to re-type their email address.', $this->prefix).'<br><br>'.__('Autofill with user email will autofill Email field with the email address of the logged in user.', $this->prefix).'<br><br>'.__('Upon successful submission of the Form, you have the option to send the submitted data (or just a confirmation message) to the email address entered here. To do this you need to set the corresponding options on Form Options > Email Options page.', $this->prefix),
|
457 |
'type_phone_description' => __('This field is an input for a phone number. It provides a list of country flags, which users can select and have their country code automatically added to the phone number.', $this->prefix).'<br><br>'.__('In case you do not wish to receive the same data for the same Phone field more than once, activate Allow only unique values setting from Advanced options.', $this->prefix),
|
@@ -466,7 +548,7 @@ final class WDCFM {
|
|
466 |
'type_stars_description' => __('Add Star rating field to your form with this field. You can display as many stars, as you will need, set the number using Number of Stars option.', $this->prefix),
|
467 |
'type_rating_description' => __('Place Rating field on your form to have radio buttons, which indicate rating from worst to best. You can set many radio buttons to display using Scale Range option.', $this->prefix),
|
468 |
'type_slider_description' => __('Slider field lets users specify the field value by dragging its handle from Min Value to Max Value.', $this->prefix),
|
469 |
-
'type_range_description' => __('You can use this field to let users choose a numeric range by providing values for 2 number inputs. Its Step option allows to set the increment/decrement of spinners
|
470 |
'type_grades_description' => __('Users will be able to grade specified items with this field. The sum of all values will appear below the field with Total parameter.', $this->prefix).'<br><br>'.__('Items option allows you to add multiple options to your Grades field.', $this->prefix),
|
471 |
'type_matrix_description' => __('Table of Fields lets you place a matrix on your form, which will let the submitter to answer a few questions with one field.', $this->prefix).'<br><br>'.__('It allows you to configure the matrix with radio buttons, checkboxes, text boxes or drop-downs. Use Input Type option to set this.', $this->prefix),
|
472 |
'type_hidden_description' => __('Hidden Input field is similar to Single Line Text field, but it is not visible to users. Hidden Fields are handy, in case you need to run a custom Javascript and submit the result with the info on your form.', $this->prefix).'<br><br>'.__('Name option of this field is mandatory. Note: we highly recommend you to avoid using spaces or special characters in Hidden Input name. You can write the custom Javascript code using the editor on Form Options > Javascript page.', $this->prefix),
|
@@ -483,73 +565,75 @@ final class WDCFM {
|
|
483 |
'type_stripe_description' => __('This field adds the credit card details inputs (card number, expiration date, etc.) and allows you to accept direct payments made by credit cards.', $this->prefix),
|
484 |
));
|
485 |
|
486 |
-
wp_register_script('
|
487 |
-
wp_register_script('
|
488 |
-
wp_register_script('
|
489 |
-
wp_register_script('
|
490 |
-
wp_register_script('
|
491 |
-
wp_register_script('
|
492 |
-
wp_register_script('
|
493 |
-
wp_register_script('
|
494 |
|
495 |
-
wp_register_script('
|
496 |
|
497 |
-
wp_register_script('
|
498 |
|
499 |
-
wp_register_script('
|
500 |
-
wp_register_script('
|
501 |
|
502 |
-
wp_localize_script('
|
503 |
-
'countries' =>
|
504 |
'delete_confirmation' => __('Do you want to delete selected items?', $this->prefix),
|
505 |
'select_at_least_one_item' => __('You must select at least one item.', $this->prefix),
|
|
|
506 |
));
|
507 |
if (!$this->is_free) {
|
508 |
wp_register_script('jquery.fancybox.pack', $this->plugin_url . '/js/fancybox/jquery.fancybox.pack.js', array(), '2.1.5');
|
509 |
}
|
510 |
else {
|
511 |
-
wp_register_style('
|
512 |
-
wp_register_script('
|
513 |
$admin_data = wp_get_current_user();
|
514 |
-
wp_localize_script( '
|
515 |
"prefix" => "fm" ,
|
516 |
"deactivate_class" => 'fm_deactivate_link',
|
517 |
"email" => $admin_data->data->user_email,
|
518 |
"plugin_wd_url" => "https://web-dorado.com/files/fromContactForm.php",
|
519 |
));
|
520 |
-
wp_register_style('fm-license' . $this->menu_postfix, $this->plugin_url . '/css/license.css', array(), $this->plugin_version);
|
521 |
}
|
|
|
522 |
}
|
523 |
|
524 |
/**
|
525 |
* Admin ajax scripts.
|
526 |
*/
|
527 |
public function register_admin_ajax_scripts() {
|
528 |
-
wp_register_style('
|
529 |
-
wp_register_style('
|
530 |
-
wp_register_style('
|
531 |
|
532 |
-
wp_register_script('
|
533 |
|
534 |
-
$fm_settings = get_option('fmc_settings');
|
535 |
$google_map_key = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
536 |
|
537 |
wp_register_script('google-maps', 'https://maps.google.com/maps/api/js?v=3.exp' . $google_map_key);
|
538 |
-
wp_register_script('
|
539 |
|
540 |
-
wp_localize_script('
|
541 |
'insert_form' => __('You must select a form', $this->prefix),
|
542 |
'update' => __('Update', $this->prefix),
|
543 |
));
|
|
|
|
|
|
|
544 |
}
|
545 |
|
546 |
/**
|
547 |
* admin-ajax actions for admin.
|
548 |
*/
|
549 |
public function form_maker_ajax() {
|
550 |
-
|
551 |
-
$page = WDW_FMC_Library::get('action');
|
552 |
-
|
553 |
if ( $page != 'formmakerwdcaptcha' . $this->plugin_postfix && $page != 'formmakerwdmathcaptcha' . $this->plugin_postfix && $page != 'checkpaypal' . $this->plugin_postfix ) {
|
554 |
if ( function_exists('current_user_can') ) {
|
555 |
if ( !current_user_can('manage_options') ) {
|
@@ -574,8 +658,22 @@ final class WDCFM {
|
|
574 |
* admin-ajax actions for site.
|
575 |
*/
|
576 |
public function form_maker_ajax_frontend() {
|
577 |
-
$
|
578 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
579 |
$this->register_frontend_ajax_scripts();
|
580 |
require_once ($this->plugin_dir . '/frontend/controllers/' . $page . '.php');
|
581 |
$controller_class = 'FMController' . ucfirst($page);
|
@@ -626,8 +724,8 @@ final class WDCFM {
|
|
626 |
echo __('Sorry, you are not allowed to access this page.', $this->prefix);
|
627 |
}
|
628 |
else {
|
629 |
-
$id =
|
630 |
-
$display_options =
|
631 |
$type = $display_options->type;
|
632 |
|
633 |
$attrs = array( 'id' => $id );
|
@@ -661,7 +759,12 @@ final class WDCFM {
|
|
661 |
public function FM_front_end_main($params = array(), $type = '') {
|
662 |
if ( !isset($params['type']) ) {
|
663 |
$form_id = isset($params['id']) ? (int) $params['id'] : 0;
|
664 |
-
|
|
|
|
|
|
|
|
|
|
|
665 |
}
|
666 |
else if (!$this->is_free) {
|
667 |
$shortcode_deafults = array(
|
@@ -679,7 +782,7 @@ final class WDCFM {
|
|
679 |
|
680 |
require_once($this->plugin_dir . '/frontend/controllers/form_submissions.php');
|
681 |
$controller = new FMControllerForm_submissions();
|
682 |
-
|
683 |
$submissions = $controller->execute($params);
|
684 |
|
685 |
echo $submissions;
|
@@ -692,7 +795,7 @@ final class WDCFM {
|
|
692 |
*/
|
693 |
public function fm_email_verification_shortcode() {
|
694 |
require_once($this->plugin_dir . '/frontend/controllers/verify_email.php');
|
695 |
-
$controller_class = '
|
696 |
$controller = new $controller_class();
|
697 |
$controller->execute();
|
698 |
}
|
@@ -714,9 +817,9 @@ final class WDCFM {
|
|
714 |
)
|
715 |
);
|
716 |
|
717 |
-
register_post_type('cfmemailverification', $args);
|
718 |
}
|
719 |
-
|
720 |
/**
|
721 |
* Register form preview custom post type.
|
722 |
*/
|
@@ -735,29 +838,30 @@ final class WDCFM {
|
|
735 |
);
|
736 |
|
737 |
register_post_type('form-maker' . $this->plugin_postfix, $args);
|
738 |
-
}
|
739 |
-
|
740 |
/**
|
741 |
* Frontend scripts/styles.
|
742 |
*/
|
743 |
public function register_frontend_scripts() {
|
744 |
-
|
|
|
745 |
|
746 |
-
$fm_settings = get_option('fmc_settings');
|
747 |
$google_map_key = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
748 |
wp_register_script('google-maps', 'https://maps.google.com/maps/api/js?v=3.exp' . $google_map_key);
|
749 |
|
750 |
-
wp_register_script('
|
751 |
|
752 |
-
wp_register_style('
|
753 |
-
wp_register_style('
|
754 |
|
755 |
-
wp_register_script('
|
756 |
-
wp_register_script('
|
757 |
|
758 |
-
wp_localize_script('
|
759 |
-
'states' =>
|
760 |
-
'plugin_url' => $
|
761 |
'form_maker_admin_ajax' => admin_url('admin-ajax.php'),
|
762 |
'fm_file_type_error' => addslashes(__('Can not upload this type of file', $this->prefix)),
|
763 |
'fm_field_is_required' => addslashes(__('Field is required', $this->prefix)),
|
@@ -772,20 +876,20 @@ final class WDCFM {
|
|
772 |
'year_validation' => addslashes(sprintf(__('The year must be between %s and %s', $this->prefix), '%%start%%', '%%end%%')),
|
773 |
));
|
774 |
|
775 |
-
$google_fonts =
|
776 |
$fonts = implode("|", str_replace(' ', '+', $google_fonts));
|
777 |
-
wp_register_style('
|
778 |
|
779 |
-
wp_register_style('
|
780 |
|
781 |
-
wp_register_script('
|
782 |
|
783 |
// Register admin styles to use in frontend submissions.
|
784 |
-
wp_register_script('gmap_form_back', $
|
785 |
|
786 |
if (!$this->is_free) {
|
787 |
-
wp_register_script('
|
788 |
-
wp_register_style('
|
789 |
}
|
790 |
}
|
791 |
|
@@ -793,10 +897,11 @@ final class WDCFM {
|
|
793 |
* Frontend ajax scripts.
|
794 |
*/
|
795 |
public function register_frontend_ajax_scripts() {
|
796 |
-
$
|
|
|
797 |
$google_map_key = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
798 |
wp_register_script('google-maps', 'https://maps.google.com/maps/api/js?v=3.exp' . $google_map_key);
|
799 |
-
wp_register_script('
|
800 |
}
|
801 |
|
802 |
/**
|
@@ -804,7 +909,12 @@ final class WDCFM {
|
|
804 |
*/
|
805 |
public function form_maker_on_activate() {
|
806 |
$this->form_maker_activate();
|
807 |
-
|
|
|
|
|
|
|
|
|
|
|
808 |
$this->init();
|
809 |
flush_rewrite_rules();
|
810 |
}
|
@@ -828,17 +938,22 @@ final class WDCFM {
|
|
828 |
}
|
829 |
else {
|
830 |
add_option("wd_form_maker_version", $new_version, '', 'no');
|
831 |
-
|
|
|
|
|
|
|
|
|
|
|
832 |
$email_verification_post = array(
|
833 |
'post_title' => 'Email Verification',
|
834 |
'post_content' => '[email_verification]',
|
835 |
'post_status' => 'publish',
|
836 |
'post_author' => 1,
|
837 |
-
'post_type' => 'cfmemailverification',
|
838 |
);
|
839 |
$mail_verification_post_id = wp_insert_post($email_verification_post);
|
840 |
|
841 |
-
add_option('fmc_settings', array('public_key' => '', 'private_key' => '', 'csv_delimiter' => ',', 'map_key' => ''));
|
842 |
$wpdb->update($wpdb->prefix . "formmaker", array(
|
843 |
'mail_verification_post_id' => $mail_verification_post_id,
|
844 |
), array('id' => 1), array(
|
@@ -854,193 +969,26 @@ final class WDCFM {
|
|
854 |
foreach ($mail_verification_post_ids as $mail_verification_post_id) {
|
855 |
$update_email_ver_post_type = array(
|
856 |
'ID' => (int)$mail_verification_post_id->mail_verification_post_id,
|
857 |
-
'post_type' => 'cfmemailverification',
|
858 |
);
|
859 |
wp_update_post($update_email_ver_post_type);
|
860 |
}
|
861 |
}
|
862 |
-
|
|
|
|
|
|
|
|
|
|
|
863 |
update_option("wd_form_maker_version", $new_version);
|
864 |
|
865 |
-
if (FALSE === $fm_settings = get_option('fmc_settings')) {
|
866 |
$recaptcha_keys = $wpdb->get_row('SELECT `public_key`, `private_key` FROM ' . $wpdb->prefix . 'formmaker WHERE public_key!="" and private_key!=""', ARRAY_A);
|
867 |
$public_key = isset($recaptcha_keys['public_key']) ? $recaptcha_keys['public_key'] : '';
|
868 |
$private_key = isset($recaptcha_keys['private_key']) ? $recaptcha_keys['private_key'] : '';
|
869 |
-
add_option('fmc_settings', array('public_key' => $public_key, 'private_key' => $private_key, 'csv_delimiter' => ',', 'map_key' => ''));
|
870 |
-
}
|
871 |
-
}
|
872 |
-
}
|
873 |
-
|
874 |
-
/**
|
875 |
-
* Form maker topics at page top.
|
876 |
-
*/
|
877 |
-
public function fm_topic() {
|
878 |
-
$page = isset($_GET['page']) ? $_GET['page'] : '';
|
879 |
-
$page = str_replace($this->menu_postfix, '', $page);
|
880 |
-
$task = isset($_REQUEST['task']) ? $_REQUEST['task'] : '';
|
881 |
-
$user_guide_link = 'https://web-dorado.com/wordpress-form-maker/';
|
882 |
-
$support_forum_link = 'https://wordpress.org/support/plugin/contact-form-maker';
|
883 |
-
$pro_icon = $this->plugin_url . '/images/wd_logo.png';
|
884 |
-
$pro_link = 'https://web-dorado.com/files/fromContactForm.php';
|
885 |
-
$support_icon = $this->plugin_url . '/images/support.png';
|
886 |
-
$prefix = $this->prefix;
|
887 |
-
switch ($page) {
|
888 |
-
case 'blocked_ips': {
|
889 |
-
$help_text = __('block IPs', $this->prefix);
|
890 |
-
$user_guide_link .= 'blocking-ips.html';
|
891 |
-
break;
|
892 |
-
}
|
893 |
-
case 'options': {
|
894 |
-
$help_text = __('edit form settings', $this->prefix);
|
895 |
-
$user_guide_link .= 'themes-and-options.html';
|
896 |
-
break;
|
897 |
-
}
|
898 |
-
case 'licensing': {
|
899 |
-
$help_text = '';
|
900 |
-
$user_guide_link .= '';
|
901 |
-
break;
|
902 |
-
}
|
903 |
-
case 'manage': {
|
904 |
-
switch ($task) {
|
905 |
-
case 'edit':
|
906 |
-
case 'edit_old': {
|
907 |
-
$help_text = __('add fields to your form', $this->prefix);
|
908 |
-
$user_guide_link .= 'form-fields/basic-fields.html';
|
909 |
-
break;
|
910 |
-
}
|
911 |
-
case 'form_options':
|
912 |
-
case 'form_options_old': {
|
913 |
-
$help_text = __('edit form options', $this->prefix);
|
914 |
-
$user_guide_link .= 'form-options/general-options.html';
|
915 |
-
break;
|
916 |
-
}
|
917 |
-
case 'display_options': {
|
918 |
-
$help_text = __('edit display options', $this->prefix);
|
919 |
-
$user_guide_link .= 'display-options-publishing/configuring-display-options.html';
|
920 |
-
break;
|
921 |
-
}
|
922 |
-
default: {
|
923 |
-
$help_text = __('create, edit forms', $this->prefix);
|
924 |
-
$user_guide_link .= 'creating-form.html';
|
925 |
-
}
|
926 |
-
}
|
927 |
-
break;
|
928 |
-
}
|
929 |
-
case 'submissions': {
|
930 |
-
$help_text = __('view and manage form submissions', $this->prefix);
|
931 |
-
$user_guide_link .= 'submissions.html';
|
932 |
-
break;
|
933 |
-
}
|
934 |
-
case 'themes': {
|
935 |
-
$help_text = __('create, edit form themes', $this->prefix);
|
936 |
-
$user_guide_link .= 'themes-and-options.html';
|
937 |
-
break;
|
938 |
-
}
|
939 |
-
default: {
|
940 |
-
return '';
|
941 |
}
|
942 |
}
|
943 |
-
ob_start();
|
944 |
-
?>
|
945 |
-
<style>
|
946 |
-
.wd_topic {
|
947 |
-
background-color: #ffffff;
|
948 |
-
border: none;
|
949 |
-
box-sizing: border-box;
|
950 |
-
clear: both;
|
951 |
-
color: #6e7990;
|
952 |
-
font-size: 14px;
|
953 |
-
font-weight: bold;
|
954 |
-
line-height: 44px;
|
955 |
-
margin: 0;
|
956 |
-
padding: 0 0 0 15px;
|
957 |
-
vertical-align: middle;
|
958 |
-
width: 98%;
|
959 |
-
}
|
960 |
-
.wd_topic .wd_help_topic {
|
961 |
-
float: left;
|
962 |
-
}
|
963 |
-
.wd_topic .wd_help_topic a {
|
964 |
-
color: #0073aa;
|
965 |
-
}
|
966 |
-
.wd_topic .wd_help_topic a:hover {
|
967 |
-
color: #00A0D2;
|
968 |
-
}
|
969 |
-
.wd_topic .wd_support {
|
970 |
-
float: right;
|
971 |
-
margin: 0 10px;
|
972 |
-
}
|
973 |
-
.wd_topic .wd_support img {
|
974 |
-
vertical-align: middle;
|
975 |
-
}
|
976 |
-
.wd_topic .wd_support a {
|
977 |
-
text-decoration: none;
|
978 |
-
color: #6E7990;
|
979 |
-
}
|
980 |
-
.wd_topic .wd_pro {
|
981 |
-
float: right;
|
982 |
-
padding: 0;
|
983 |
-
}
|
984 |
-
.wd_topic .wd_pro a {
|
985 |
-
border: none;
|
986 |
-
box-shadow: none !important;
|
987 |
-
text-decoration: none;
|
988 |
-
}
|
989 |
-
.wd_topic .wd_pro img {
|
990 |
-
border: none;
|
991 |
-
display: inline-block;
|
992 |
-
vertical-align: middle;
|
993 |
-
}
|
994 |
-
.wd_topic .wd_pro a,
|
995 |
-
.wd_topic .wd_pro a:active,
|
996 |
-
.wd_topic .wd_pro a:visited,
|
997 |
-
.wd_topic .wd_pro a:hover {
|
998 |
-
background-color: #D8D8D8;
|
999 |
-
color: #175c8b;
|
1000 |
-
display: inline-block;
|
1001 |
-
font-size: 11px;
|
1002 |
-
font-weight: bold;
|
1003 |
-
padding: 0 10px;
|
1004 |
-
vertical-align: middle;
|
1005 |
-
}
|
1006 |
-
</style>
|
1007 |
-
<div class="update-nag wd_topic">
|
1008 |
-
<?php
|
1009 |
-
if ($help_text) {
|
1010 |
-
?>
|
1011 |
-
<span class="wd_help_topic">
|
1012 |
-
<?php echo sprintf(__('This section allows you to %s.', $prefix), $help_text); ?>
|
1013 |
-
<a target="_blank" href="<?php echo $user_guide_link; ?>">
|
1014 |
-
<?php _e('Read More in User Manual', $prefix); ?>
|
1015 |
-
</a>
|
1016 |
-
</span>
|
1017 |
-
<?php
|
1018 |
-
}
|
1019 |
-
if ($this->is_free) {
|
1020 |
-
$text = strtoupper(__('Upgrade to paid version', $prefix));
|
1021 |
-
?>
|
1022 |
-
<div class="wd_pro">
|
1023 |
-
<a target="_blank" href="<?php echo $pro_link; ?>">
|
1024 |
-
<img alt="web-dorado.com" title="<?php echo $text; ?>" src="<?php echo $pro_icon; ?>" />
|
1025 |
-
<span><?php echo $text; ?></span>
|
1026 |
-
</a>
|
1027 |
-
</div>
|
1028 |
-
<?php
|
1029 |
-
}
|
1030 |
-
if ($this->is_free) {
|
1031 |
-
?>
|
1032 |
-
<span class="wd_support">
|
1033 |
-
<a target="_blank" href="<?php echo $support_forum_link; ?>">
|
1034 |
-
<img src="<?php echo $support_icon; ?>" />
|
1035 |
-
<?php _e('Support Forum', $prefix); ?>
|
1036 |
-
</a>
|
1037 |
-
</span>
|
1038 |
-
<?php
|
1039 |
-
}
|
1040 |
-
?>
|
1041 |
-
</div>
|
1042 |
-
<?php
|
1043 |
-
echo ob_get_clean();
|
1044 |
}
|
1045 |
|
1046 |
/**
|
@@ -1053,13 +1001,13 @@ final class WDCFM {
|
|
1053 |
}
|
1054 |
global $cfm_options;
|
1055 |
$cfm_options = array(
|
1056 |
-
"prefix" =>
|
1057 |
-
"wd_plugin_id" => 183,
|
1058 |
-
"plugin_title" =>
|
1059 |
-
"plugin_wordpress_slug" =>
|
1060 |
"plugin_dir" => $this->plugin_dir,
|
1061 |
"plugin_main_file" => __FILE__,
|
1062 |
-
"description" => __('WordPress Contact Form Maker is a simple contact form builder, which allows the user with almost no knowledge of programming to create and edit different type of contact forms.', $this->prefix),
|
1063 |
// from web-dorado.com
|
1064 |
"plugin_features" => array(
|
1065 |
0 => array(
|
@@ -1081,24 +1029,24 @@ final class WDCFM {
|
|
1081 |
4 => array(
|
1082 |
"title" => __("Themes", $this->prefix),
|
1083 |
"description" => __("The WordPress Form Maker plugin comes with a wide range of customizable themes. You can choose from a list of existing themes or simply create the one that better fits your brand and website.", $this->prefix),
|
1084 |
-
)
|
1085 |
),
|
1086 |
// user guide from web-dorado.com
|
1087 |
"user_guide" => array(
|
1088 |
0 => array(
|
1089 |
"main_title" => __("Installing", $this->prefix),
|
1090 |
"url" => "https://web-dorado.com/wordpress-form-maker/introduction.html",
|
1091 |
-
"titles" => array()
|
1092 |
),
|
1093 |
1 => array(
|
1094 |
"main_title" => __("Creating a new Form", $this->prefix),
|
1095 |
"url" => "https://web-dorado.com/wordpress-form-maker/creating-form.html",
|
1096 |
-
"titles" => array()
|
1097 |
),
|
1098 |
2 => array(
|
1099 |
"main_title" => __("Configuring Form Options", $this->prefix),
|
1100 |
"url" => "https://web-dorado.com/wordpress-form-maker/form-options/general-options.html",
|
1101 |
-
"titles" => array()
|
1102 |
),
|
1103 |
3 => array(
|
1104 |
"main_title" => __("Description of The Form Fields", $this->prefix),
|
@@ -1108,34 +1056,34 @@ final class WDCFM {
|
|
1108 |
"title" => __("Selecting Options from Database", $this->prefix),
|
1109 |
"url" => "https://web-dorado.com/wordpress-form-maker/description-of-form-fields/selecting-options-from-database.html",
|
1110 |
),
|
1111 |
-
)
|
1112 |
),
|
1113 |
4 => array(
|
1114 |
"main_title" => __("Publishing the Created Form", $this->prefix),
|
1115 |
"url" => "https://web-dorado.com/wordpress-form-maker/creating-form.html",
|
1116 |
-
"titles" => array()
|
1117 |
),
|
1118 |
5 => array(
|
1119 |
"main_title" => __("Blocking IPs", $this->prefix),
|
1120 |
"url" => "https://web-dorado.com/wordpress-form-maker/submissions.html",
|
1121 |
-
"titles" => array()
|
1122 |
),
|
1123 |
6 => array(
|
1124 |
"main_title" => __("Managing Submissions", $this->prefix),
|
1125 |
"url" => "https://web-dorado.com/wordpress-form-maker/submissions.html",
|
1126 |
-
"titles" => array()
|
1127 |
),
|
1128 |
7 => array(
|
1129 |
"main_title" => __("Publishing Submissions", $this->prefix),
|
1130 |
"url" => "https://web-dorado.com/wordpress-form-maker/other-publishing-options.html",
|
1131 |
-
"titles" => array()
|
1132 |
),
|
1133 |
),
|
1134 |
"video_youtube_id" => "tN3_c6MhqFk", // e.g. https://www.youtube.com/watch?v=acaexefeP7o youtube id is the acaexefeP7o
|
1135 |
"plugin_wd_url" => "https://web-dorado.com/files/fromContactForm.php",
|
1136 |
"plugin_wd_demo_link" => "http://wpdemo.web-dorado.com",
|
1137 |
"plugin_wd_addons_link" => "https://web-dorado.com/products/wordpress-form/add-ons.html",
|
1138 |
-
"after_subscribe" => admin_url('admin.php?page=
|
1139 |
"plugin_wizard_link" => '',
|
1140 |
"plugin_menu_title" => $this->nicename,
|
1141 |
"plugin_menu_icon" => $this->plugin_url . '/images/FormMakerLogo-16.png',
|
@@ -1160,14 +1108,14 @@ final class WDCFM {
|
|
1160 |
ob_start();
|
1161 |
$url = add_query_arg(array('action' => 'FMShortocde' . $this->plugin_postfix, 'task' => 'form', 'TB_iframe' => '1'), admin_url('admin-ajax.php'));
|
1162 |
?>
|
1163 |
-
<a onclick="tb_click.call(this); fm_set_shortcode_popup_dimensions(400, 140); return false;" href="<?php echo $url; ?>" class="button" title="<?php _e('Insert
|
1164 |
<span class="wp-media-buttons-icon" style="background: url('<?php echo $this->plugin_url; ?>/images/fm-media-form-button.png') no-repeat scroll left top rgba(0, 0, 0, 0);"></span>
|
1165 |
-
<?php _e('Add
|
1166 |
</a>
|
1167 |
<?php
|
1168 |
$url = add_query_arg(array('action' => 'FMShortocde' . $this->plugin_postfix, 'task' => 'submissions', 'TB_iframe' => '1'), admin_url('admin-ajax.php'));
|
1169 |
?>
|
1170 |
-
<a onclick="tb_click.call(this); fm_set_shortcode_popup_dimensions(
|
1171 |
<span class="wp-media-buttons-icon" style="background: url('<?php echo $this->plugin_url; ?>/images/fm-media-submissions-button.png') no-repeat scroll left top rgba(0, 0, 0, 0);"></span>
|
1172 |
<?php _e('Add Submissions', $this->prefix); ?>
|
1173 |
</a>
|
@@ -1183,6 +1131,7 @@ final class WDCFM {
|
|
1183 |
*
|
1184 |
*/
|
1185 |
function fm_check_addons_compatibility() {
|
|
|
1186 |
$add_ons = array(
|
1187 |
'form-maker-export-import' => array('version' => '2.0.7', 'file' => 'fm_exp_imp.php'),
|
1188 |
'form-maker-save-progress' => array('version' => '1.0.1', 'file' => 'fm_save.php'),
|
@@ -1193,7 +1142,7 @@ final class WDCFM {
|
|
1193 |
'form-maker-post-generation' => array('version' => '1.0.2', 'file' => 'fm_post_generation.php'),
|
1194 |
'form-maker-dropbox-integration' => array('version' => '1.1.1', 'file' => 'fm_dropbox_integration.php'),
|
1195 |
'form-maker-gdrive-integration' => array('version' => '1.0.0', 'file' => 'fm_gdrive_integration.php'),
|
1196 |
-
'form-maker-pdf-integration' => array('version' => '1.
|
1197 |
'form-maker-stripe' => array('version' => '1.0.1', 'file' => 'fm_stripe.php'),
|
1198 |
'form-maker-calculator' => array('version' => '1.0.3', 'file' => 'fm_calculator.php'),
|
1199 |
);
|
@@ -1237,16 +1186,28 @@ final class WDCFM {
|
|
1237 |
}
|
1238 |
|
1239 |
/**
|
1240 |
-
* Main instance of
|
1241 |
*
|
1242 |
-
* @return
|
1243 |
*/
|
1244 |
-
|
1245 |
-
|
|
|
|
|
|
|
|
|
|
|
1246 |
}
|
1247 |
|
1248 |
-
|
1249 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1250 |
}
|
1251 |
|
1252 |
/**
|
@@ -1256,7 +1217,7 @@ if (!function_exists('WDFM') || WDFM()->is_free == 1) {
|
|
1256 |
* @param string $type
|
1257 |
*/
|
1258 |
function wd_contact_form_maker($id, $type = 'embedded') {
|
1259 |
-
require_once (
|
1260 |
$controller = new FMControllerForm_maker_fmc();
|
1261 |
$form = $controller->execute($id, $type);
|
1262 |
echo $form;
|
@@ -1279,9 +1240,9 @@ function fmc_bp_install_notice() {
|
|
1279 |
$meta_value = get_option('wd_bk_notice_status');
|
1280 |
if ( $meta_value === '' || $meta_value === FALSE ) {
|
1281 |
ob_start();
|
1282 |
-
$prefix =
|
1283 |
-
$nicename =
|
1284 |
-
$url =
|
1285 |
$dismiss_url = add_query_arg(array( 'action' => 'wd_bp_dismiss' ), admin_url('admin-ajax.php'));
|
1286 |
$install_url = esc_url(wp_nonce_url(self_admin_url('update.php?action=install-plugin&plugin=backup-wd'), 'install-plugin_backup-wd'));
|
1287 |
?>
|
@@ -1352,7 +1313,7 @@ if ( !function_exists('wd_bps_install_notice_status') ) {
|
|
1352 |
function fmc_add_plugin_meta_links($meta_fields, $file) {
|
1353 |
if ( plugin_basename(__FILE__) == $file ) {
|
1354 |
$plugin_url = "https://wordpress.org/support/plugin/contact-form-maker";
|
1355 |
-
$prefix =
|
1356 |
$meta_fields[] = "<a href='" . $plugin_url . "' target='_blank'>" . __('Support Forum', $prefix) . "</a>";
|
1357 |
$meta_fields[] = "<a href='" . $plugin_url . "/reviews#new-post' target='_blank' title='" . __('Rate', $prefix) . "'>
|
1358 |
<i class='wdi-rate-stars'>"
|
@@ -1376,6 +1337,6 @@ function fmc_add_plugin_meta_links($meta_fields, $file) {
|
|
1376 |
return $meta_fields;
|
1377 |
}
|
1378 |
|
1379 |
-
if (
|
1380 |
add_filter("plugin_row_meta", 'fmc_add_plugin_meta_links', 10, 2);
|
1381 |
}
|
3 |
* Plugin Name: Contact Form Maker
|
4 |
* Plugin URI: https://web-dorado.com/products/form-maker-wordpress.html
|
5 |
* Description: WordPress Contact Form Maker is a simple contact form builder, which allows the user with almost no knowledge of programming to create and edit different type of contact forms.
|
6 |
+
* Version: 1.12.28
|
7 |
* Author: WebDorado Form Builder Team
|
8 |
* Author URI: https://web-dorado.com/wordpress-plugins-bundle.html
|
9 |
* License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
|
12 |
defined('ABSPATH') || die('Access Denied');
|
13 |
|
14 |
final class WDCFM {
|
15 |
+
/**
|
16 |
+
* PLUGIN = 2 points to Contact Form Maker
|
17 |
+
*/
|
18 |
+
const PLUGIN = 2;
|
19 |
+
|
20 |
/**
|
21 |
* The single instance of the class.
|
22 |
*/
|
29 |
* Plugin directory url.
|
30 |
*/
|
31 |
public $plugin_url = '';
|
32 |
+
/**
|
33 |
* Plugin front urls.
|
34 |
*/
|
35 |
public $front_urls = array();
|
62 |
public $is_demo = false;
|
63 |
|
64 |
/**
|
65 |
+
* Main WDFM Instance.
|
66 |
*
|
67 |
* Ensures only one instance is loaded or can be loaded.
|
68 |
*
|
69 |
* @static
|
70 |
+
* @return WDFM - Main instance.
|
71 |
*/
|
72 |
public static function instance() {
|
73 |
if ( is_null( self::$_instance ) ) {
|
76 |
return self::$_instance;
|
77 |
}
|
78 |
|
|
|
|
|
|
|
79 |
public function __construct() {
|
80 |
$this->define_constants();
|
81 |
require_once($this->plugin_dir . '/framework/WDW_FM_Library.php');
|
82 |
if (is_admin()) {
|
83 |
+
require_once(wp_normalize_path($this->plugin_dir . '/admin/controllers/controller.php'));
|
84 |
+
require_once(wp_normalize_path($this->plugin_dir . '/admin/models/model.php'));
|
85 |
require_once(wp_normalize_path($this->plugin_dir . '/admin/views/view.php'));
|
86 |
}
|
87 |
$this->add_actions();
|
91 |
* Define Constants.
|
92 |
*/
|
93 |
private function define_constants() {
|
94 |
+
$this->plugin_dir = WP_PLUGIN_DIR . "/" . plugin_basename(dirname(__FILE__));
|
95 |
$this->plugin_url = plugins_url(plugin_basename(dirname(__FILE__)));
|
96 |
+
$this->front_urls = $this->get_front_urls();
|
97 |
$this->main_file = plugin_basename(__FILE__);
|
98 |
+
$this->plugin_version = '1.12.28';
|
99 |
+
$this->db_version = '2.12.28';
|
100 |
+
$this->menu_postfix = ($this->is_free == 2 ? '_fmc' : '_fm');
|
101 |
+
$this->plugin_postfix = ($this->is_free == 2 ? '_fmc' : '');
|
102 |
+
$this->menu_slug = 'manage' . $this->menu_postfix;
|
103 |
+
$this->prefix = 'form_maker' . $this->plugin_postfix;
|
104 |
$this->css_prefix = 'fm_';
|
105 |
$this->js_prefix = 'fm_';
|
106 |
+
$this->handle_prefix = ($this->is_free == 2 ? 'fmc' : 'fm');
|
107 |
+
$this->nicename = ($this->is_free == 2 ? __('Contact Form', $this->prefix) : __('Form Maker', $this->prefix));
|
|
|
108 |
}
|
109 |
|
110 |
/**
|
179 |
|
180 |
// Form Maker Widget.
|
181 |
if (class_exists('WP_Widget')) {
|
182 |
+
add_action('widgets_init', array($this, 'register_widgets'));
|
183 |
}
|
184 |
|
185 |
// Form maker activation.
|
188 |
&& (!isset($_GET['page']) || $_GET['page'] != 'uninstall' . $this->menu_postfix) ) {
|
189 |
add_action('admin_init', array($this, 'form_maker_activate'));
|
190 |
}
|
|
|
191 |
|
192 |
// Register scripts/styles.
|
193 |
add_action('wp_enqueue_scripts', array($this, 'register_frontend_scripts'));
|
201 |
add_action('admin_notices', array($this, 'fm_check_addons_compatibility'));
|
202 |
}
|
203 |
|
204 |
+
add_action('plugins_loaded', array($this, 'plugins_loaded'), 9);
|
205 |
|
206 |
+
add_filter('wpseo_whitelist_permalink_vars', array($this, 'add_query_vars_seo'));
|
207 |
+
|
208 |
+
// Enqueue block editor assets for Gutenberg.
|
209 |
+
add_filter('tw_get_block_editor_assets', array($this, 'register_block_editor_assets'));
|
210 |
+
add_action( 'enqueue_block_editor_assets', array($this, 'enqueue_block_editor_assets') );
|
211 |
// Privacy policy.
|
212 |
add_action( 'admin_init', array($this, 'add_privacy_policy_content') );
|
213 |
}
|
217 |
return;
|
218 |
}
|
219 |
|
220 |
+
$content = __( 'All data submitted by website visitors is stored in website database. With every form submission Form Maker plugin collects users’ IP address and WordPress user ID for logged in users.<br />In the following forms <b>[List of Forms that collect personal data]</b> we collect personal data, such as <b>[Types of personal data collected]</b>. We need this information to <b>[purpose of collecting personal data]</b>. Please see sections <b>[Links to sections]</b> on how your personal data is handled.', WDFMInstance(self::PLUGIN)->prefix );
|
221 |
|
222 |
wp_add_privacy_policy_content(
|
223 |
+
WDFMInstance(self::PLUGIN)->nicename,
|
224 |
wp_kses_post( wpautop( $content, false ) )
|
225 |
);
|
226 |
}
|
227 |
|
228 |
+
public function register_block_editor_assets($assets) {
|
229 |
+
$version = '2.0.0';
|
230 |
+
$js_path = $this->plugin_url . '/js/tw-gb/block.js';
|
231 |
+
$css_path = $this->plugin_url . '/css/tw-gb/block.css';
|
232 |
+
if (!isset($assets['version']) || version_compare($assets['version'], $version) === -1) {
|
233 |
+
$assets['version'] = $version;
|
234 |
+
$assets['js_path'] = $js_path;
|
235 |
+
$assets['css_path'] = $css_path;
|
236 |
+
}
|
237 |
+
return $assets;
|
238 |
+
}
|
239 |
+
|
240 |
+
public function enqueue_block_editor_assets() {
|
241 |
+
if ($this->is_free == 2) {
|
242 |
+
$key = 'tw/contact-form-maker';
|
243 |
+
$key_submissions = 'tw/cfm-submissions';
|
244 |
+
}
|
245 |
+
else {
|
246 |
+
$key = 'tw/form-maker';
|
247 |
+
$key_submissions = 'tw/fm-submissions';
|
248 |
+
}
|
249 |
+
$plugin_name = $this->nicename;
|
250 |
+
$plugin_name_submissions = __('Submissions', WDFMInstance(self::PLUGIN)->prefix);
|
251 |
+
$icon_url = $this->plugin_url . '/images/tw-gb/icon_colored.svg';
|
252 |
+
$icon_svg = $this->plugin_url . '/images/tw-gb/icon.svg';
|
253 |
+
$url = add_query_arg(array('action' => 'FMShortocde' . $this->plugin_postfix, 'task' => 'submissions'), admin_url('admin-ajax.php'));
|
254 |
+
$data = WDW_FM_Library(self::PLUGIN)->get_shortcode_data();
|
255 |
+
?>
|
256 |
+
<script>
|
257 |
+
if ( !window['tw_gb'] ) {
|
258 |
+
window['tw_gb'] = {};
|
259 |
+
}
|
260 |
+
if ( !window['tw_gb']['<?php echo $key; ?>'] ) {
|
261 |
+
window['tw_gb']['<?php echo $key; ?>'] = {
|
262 |
+
title: '<?php echo $plugin_name; ?>',
|
263 |
+
titleSelect: '<?php echo sprintf(__('Select %s', $this->prefix), $plugin_name); ?>',
|
264 |
+
iconUrl: '<?php echo $icon_url; ?>',
|
265 |
+
iconSvg: {
|
266 |
+
width: '20',
|
267 |
+
height: '20',
|
268 |
+
src: '<?php echo $icon_svg; ?>'
|
269 |
+
},
|
270 |
+
isPopup: false,
|
271 |
+
data: '<?php echo $data; ?>'
|
272 |
+
}
|
273 |
+
}
|
274 |
+
if ( !window['tw_gb']['<?php echo $key_submissions; ?>'] ) {
|
275 |
+
window['tw_gb']['<?php echo $key_submissions; ?>'] = {
|
276 |
+
title: '<?php echo $plugin_name_submissions; ?>',
|
277 |
+
titleSelect: '<?php echo sprintf(__('Select %s', $this->prefix), $plugin_name); ?>',
|
278 |
+
iconUrl: '<?php echo $icon_url; ?>',
|
279 |
+
iconSvg: {
|
280 |
+
width: '20',
|
281 |
+
height: '20',
|
282 |
+
src: '<?php echo $icon_svg; ?>'
|
283 |
+
},
|
284 |
+
isPopup: true,
|
285 |
+
containerClass: 'tw-container-wrap-520-400',
|
286 |
+
data: {
|
287 |
+
shortcodeUrl: '<?php echo $url; ?>'
|
288 |
+
}
|
289 |
+
}
|
290 |
+
}
|
291 |
+
</script>
|
292 |
+
<?php
|
293 |
+
// Remove previously registered or enqueued versions
|
294 |
+
$wp_scripts = wp_scripts();
|
295 |
+
foreach ($wp_scripts->registered as $key => $value) {
|
296 |
+
// Check for an older versions with prefix.
|
297 |
+
if (strpos($key, 'tw-gb-block') > 0) {
|
298 |
+
wp_deregister_script( $key );
|
299 |
+
wp_deregister_style( $key );
|
300 |
+
}
|
301 |
+
}
|
302 |
+
// Get the last version from all 10Web plugins.
|
303 |
+
$assets = apply_filters('tw_get_block_editor_assets', array());
|
304 |
+
// Not performing unregister or unenqueue as in old versions all are with prefixes.
|
305 |
+
wp_enqueue_script('tw-gb-block', $assets['js_path'], array( 'wp-blocks', 'wp-element' ), $assets['version']);
|
306 |
+
wp_localize_script('tw-gb-block', 'tw_obj', array(
|
307 |
+
'nothing_selected' => __('Nothing selected.', $this->prefix),
|
308 |
+
'empty_item' => __('- Select -', $this->prefix),
|
309 |
+
));
|
310 |
+
wp_enqueue_style('tw-gb-block', $assets['css_path'], array( 'wp-edit-blocks' ), $assets['version']);
|
311 |
+
}
|
312 |
+
|
313 |
/**
|
314 |
* Wordpress init actions.
|
315 |
*/
|
330 |
public function plugins_loaded() {
|
331 |
// Languages localization.
|
332 |
load_plugin_textdomain($this->prefix, FALSE, basename(dirname(__FILE__)) . '/languages');
|
333 |
+
|
334 |
+
if ($this->is_free != 2 && !function_exists('WDFM')) {
|
335 |
+
require_once($this->plugin_dir . '/WDFM.php');
|
336 |
+
}
|
337 |
+
|
338 |
// Initialize add-ons.
|
339 |
if ($this->is_free != 2) {
|
340 |
do_action('fm_init_addons');
|
346 |
*/
|
347 |
public function form_maker_options_panel() {
|
348 |
$parent_slug = !$this->is_free ? $this->menu_slug : null;
|
349 |
+
if( !$this->is_free || ($this->is_free == 1 && get_option( "fm_subscribe_done" ) == 1) || ($this->is_free == 2 && get_option( "cfm_subscribe_done" ) == 1) ) {
|
350 |
add_menu_page($this->nicename, $this->nicename, 'manage_options', $this->menu_slug, array( $this, 'form_maker' ), $this->plugin_url . '/images/FormMakerLogo-16.png');
|
351 |
$parent_slug = $this->menu_slug;
|
352 |
}
|
356 |
|
357 |
add_submenu_page(null, __('Blocked IPs', $this->prefix), __('Blocked IPs', $this->prefix), 'manage_options', 'blocked_ips' . $this->menu_postfix, array($this, 'form_maker'));
|
358 |
add_submenu_page($parent_slug, __('Themes', $this->prefix), __('Themes', $this->prefix), 'manage_options', 'themes' . $this->menu_postfix, array($this, 'form_maker'));
|
359 |
+
add_submenu_page($parent_slug, __('Options', $this->prefix), __('Options', $this->prefix), 'manage_options', 'options' . $this->menu_postfix, array($this, 'form_maker'));
|
360 |
+
if ( $this->is_free ) {
|
361 |
+
add_submenu_page($parent_slug, __('Premium Version', $this->prefix), __('Premium Version', $this->prefix), 'manage_options', 'pricing' . $this->menu_postfix, array($this, 'form_maker'));
|
362 |
}
|
363 |
add_submenu_page(null, __('Uninstall', $this->prefix), __('Uninstall', $this->prefix), 'manage_options', 'uninstall' . $this->menu_postfix, array($this, 'form_maker'));
|
364 |
+
add_submenu_page($parent_slug, __('Add-ons', $this->prefix), __('Add-ons', $this->prefix), 'manage_options', 'addons' . $this->menu_postfix, array($this , 'form_maker'));
|
365 |
}
|
366 |
|
367 |
/**
|
382 |
*/
|
383 |
private function set_front_upload_url() {
|
384 |
$wp_upload_dir = wp_upload_dir();
|
385 |
+
$upload_url = $wp_upload_dir['baseurl'];
|
386 |
+
$http = 'http://';
|
387 |
+
$https = 'https://';
|
388 |
+
if ( $_SERVER['SERVER_PORT'] == 443 || strpos(get_option('home'), $https) > -1 ) {
|
389 |
+
$upload_url = str_replace($http, $https, $wp_upload_dir['baseurl']);
|
390 |
+
}
|
391 |
|
392 |
return $upload_url;
|
393 |
}
|
443 |
else {
|
444 |
die('Access Denied');
|
445 |
}
|
446 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
447 |
+
if (($page != '') && (($page == 'manage' . $this->menu_postfix) || ($page == 'options' . $this->menu_postfix) || ($page == 'submissions' . $this->menu_postfix) || ($page == 'blocked_ips' . $this->menu_postfix) || ($page == 'themes' . $this->menu_postfix) || ($page == 'uninstall' . $this->menu_postfix) || ($page == 'addons' . $this->menu_postfix) || ($this->is_free && $page == 'pricing' . $this->menu_postfix))) {
|
448 |
$page = ucfirst(substr($page, 0, strlen($page) - strlen($this->menu_postfix)));
|
449 |
// This ugly span is here to hide admin output while css files are not loaded. Temporary.
|
450 |
// todo: Remove span somehow.
|
451 |
echo '<div id="fm_loading"></div>';
|
452 |
+
echo '<span id="fm_admin_container" class="fm-form-container hidden">';
|
453 |
require_once ($this->plugin_dir . '/admin/controllers/' . $page . '_fm.php');
|
454 |
$controller_class = 'FMController' . $page . $this->menu_postfix;
|
455 |
$controller = new $controller_class();
|
457 |
echo '</span>';
|
458 |
}
|
459 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
460 |
|
461 |
+
/**
|
462 |
* Register widgets.
|
463 |
*/
|
464 |
public function register_widgets() {
|
465 |
+
require_once($this->plugin_dir . '/admin/controllers/Widget.php');
|
466 |
+
register_widget('FMControllerWidget' . $this->plugin_postfix);
|
467 |
}
|
468 |
|
469 |
/**
|
471 |
*/
|
472 |
public function register_admin_scripts() {
|
473 |
// Admin styles.
|
474 |
+
wp_register_style($this->handle_prefix . '-tables', $this->plugin_url . '/css/form_maker_tables.css', array(), $this->plugin_version);
|
475 |
+
wp_register_style($this->handle_prefix . '-first', $this->plugin_url . '/css/form_maker_first.css', array(), $this->plugin_version);
|
476 |
+
wp_register_style($this->handle_prefix . '-phone_field_css', $this->plugin_url . '/css/intlTelInput.css', array(), $this->plugin_version);
|
477 |
+
wp_register_style($this->handle_prefix . '-jquery-ui', $this->plugin_url . '/css/jquery-ui.custom.css', array(), $this->plugin_version);
|
478 |
+
wp_register_style($this->handle_prefix . '-style', $this->plugin_url . '/css/style.css', array(), $this->plugin_version);
|
479 |
+
wp_register_style($this->handle_prefix . '-codemirror', $this->plugin_url . '/css/codemirror.css', array(), $this->plugin_version);
|
480 |
+
wp_register_style($this->handle_prefix . '-layout', $this->plugin_url . '/css/form_maker_layout.css', array(), $this->plugin_version);
|
481 |
+
wp_register_style($this->handle_prefix . '-bootstrap', $this->plugin_url . '/css/fm-bootstrap.css', array(), $this->plugin_version);
|
482 |
+
wp_register_style($this->handle_prefix . '-colorpicker', $this->plugin_url . '/css/spectrum.css', array(), $this->plugin_version);
|
483 |
+
// Roboto font for top bar.
|
484 |
+
wp_register_style($this->handle_prefix . '-roboto', 'https://fonts.googleapis.com/css?family=Roboto:300,400,500,700');
|
485 |
+
|
486 |
if (!$this->is_free) {
|
487 |
wp_register_style('jquery.fancybox', $this->plugin_url . '/js/fancybox/jquery.fancybox.css', array(), '2.1.5');
|
488 |
}
|
|
|
|
|
|
|
|
|
489 |
// Admin scripts.
|
490 |
+
$fm_settings = get_option($this->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
491 |
$google_map_key = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
492 |
|
493 |
wp_register_script('google-maps', 'https://maps.google.com/maps/api/js?v=3.exp' . $google_map_key);
|
494 |
+
wp_register_script($this->handle_prefix . '-gmap_form', $this->plugin_url . '/js/if_gmap_back_end.js', array(), $this->plugin_version);
|
495 |
+
|
496 |
+
wp_register_script($this->handle_prefix . '-phone_field', $this->plugin_url . '/js/intlTelInput.js', array(), '11.0.0');
|
497 |
+
|
498 |
+
wp_register_script($this->handle_prefix . '-admin', $this->plugin_url . '/js/form_maker_admin.js', array(), $this->plugin_version);
|
499 |
+
wp_register_script($this->handle_prefix . '-manage', $this->plugin_url . '/js/form_maker_manage.js', array(), $this->plugin_version);
|
500 |
+
wp_register_script($this->handle_prefix . '-manage-edit', $this->plugin_url . '/js/form_maker_manage_edit.js', array(), $this->plugin_version);
|
501 |
+
wp_register_script($this->handle_prefix . '-formmaker_div', $this->plugin_url . '/js/formmaker_div.js', array(), $this->plugin_version);
|
502 |
+
wp_register_script($this->handle_prefix . '-form-options', $this->plugin_url . '/js/form_maker_form_options.js', array(), $this->plugin_version);
|
503 |
+
wp_register_script($this->handle_prefix . '-form-advanced-layout', $this->plugin_url . '/js/form_maker_form_advanced_layout.js', array(), $this->plugin_version);
|
504 |
+
wp_register_script($this->handle_prefix . '-add-fields', $this->plugin_url . '/js/add_field.js', array($this->handle_prefix . '-formmaker_div'), $this->plugin_version);
|
505 |
+
wp_localize_script($this->handle_prefix . '-add-fields', 'form_maker', array(
|
506 |
+
'countries' => WDW_FM_Library(self::PLUGIN)->get_countries(),
|
507 |
+
'states' => WDW_FM_Library(self::PLUGIN)->get_states(),
|
508 |
'plugin_url' => $this->plugin_url,
|
509 |
'nothing_found' => __('Nothing found.', $this->prefix),
|
510 |
'captcha_created' => __('The captcha already has been created.', $this->prefix),
|
512 |
'add' => __('Add', $this->prefix),
|
513 |
'add_field' => __('Add Field', $this->prefix),
|
514 |
'edit_field' => __('Edit Field', $this->prefix),
|
|
|
|
|
|
|
|
|
515 |
'stripe3' => __('To use this feature, please go to Form Options > Payment Options and select "Stripe" as the Payment Method.', $this->prefix),
|
516 |
'sunday' => __('Sunday', $this->prefix),
|
517 |
'monday' => __('Monday', $this->prefix),
|
533 |
'type_checkbox_description' => __('Multiple Choice field lets you have a list of Checkboxes. This field allows the submitter to choose more than one values.', $this->prefix).'<br><br>'.__('Just click (+) Option button and fill in all options you will need or click (+) From Database to fill the options from a database table.', $this->prefix).'<br><br>'.__('Relative Position lets you choose the position of options in relation to each other. Whereas Option Label Position lets you select the position of radio button label.', $this->prefix).'<br><br>'.__('In case you need to have option values to be different from option names, mark Enable option\'s value from Advanced options as checked.', $this->prefix).'<br><br>'.__('And by enabling Allow other, you can let the user to write their own specific value.', $this->prefix),
|
534 |
'type_recaptcha_description' => sprintf(__('Form Maker is integrated with Google ReCaptcha, which protects your forms from spam bots. Before adding ReCaptcha to your form, you need to configure Site and Secret Keys by registering your website on %s', $this->prefix),'<a href="https://www.google.com/recaptcha/intro/" target="_blank">'. __('Google ReCaptcha website', $this->prefix) .'</a>').'<br><br>'.__('After registering and creating the keys, copy them to Form Maker > Options page.', $this->prefix),
|
535 |
'type_submit_description' => __('The Submit button validates all form field values, saves them on MySQL database of your website, sends emails and performs other actions configured in Form Options. You can have more than one submit button in your form.', $this->prefix),
|
536 |
+
'type_captcha_description' => __('You can use this field as an alternative to ReCaptcha to protect your forms against spambots. It’s a random combination of numbers and letters, and users need to type them in correctly to submit the form.', $this->prefix).'<br><br>'.__('You can specify the number of symbols in Simple Captcha using Symbols (3 - 9) option.', $this->prefix),
|
537 |
'type_name_description' => __('This field lets the user write their name.', $this->prefix).'<br><br>'.__('To set a default value, just fill the field above.', $this->prefix).'<br><br>'.__('Enabling Autofill with user name setting will automatically fill in Name field with the name of the logged in user.', $this->prefix).'<br><br>'.__('In case you do not wish to receive the same data for the same Name field twice, activate Allow only unique values option.', $this->prefix),
|
538 |
'type_email_description' => __('This field is an input field that accepts an email address.', $this->prefix).'<br><br>'.__('To set a default value, just fill the field above.', $this->prefix).'<br><br>'.__('Using Confirmation Email setting in Advanced Options you can require the submitter to re-type their email address.', $this->prefix).'<br><br>'.__('Autofill with user email will autofill Email field with the email address of the logged in user.', $this->prefix).'<br><br>'.__('Upon successful submission of the Form, you have the option to send the submitted data (or just a confirmation message) to the email address entered here. To do this you need to set the corresponding options on Form Options > Email Options page.', $this->prefix),
|
539 |
'type_phone_description' => __('This field is an input for a phone number. It provides a list of country flags, which users can select and have their country code automatically added to the phone number.', $this->prefix).'<br><br>'.__('In case you do not wish to receive the same data for the same Phone field more than once, activate Allow only unique values setting from Advanced options.', $this->prefix),
|
548 |
'type_stars_description' => __('Add Star rating field to your form with this field. You can display as many stars, as you will need, set the number using Number of Stars option.', $this->prefix),
|
549 |
'type_rating_description' => __('Place Rating field on your form to have radio buttons, which indicate rating from worst to best. You can set many radio buttons to display using Scale Range option.', $this->prefix),
|
550 |
'type_slider_description' => __('Slider field lets users specify the field value by dragging its handle from Min Value to Max Value.', $this->prefix),
|
551 |
+
'type_range_description' => __('You can use this field to let users choose a numeric range by providing values for 2 number inputs. Its Step option allows to set the increment/decrement of spinners’ values, when users click on up or down arrows.', $this->prefix),
|
552 |
'type_grades_description' => __('Users will be able to grade specified items with this field. The sum of all values will appear below the field with Total parameter.', $this->prefix).'<br><br>'.__('Items option allows you to add multiple options to your Grades field.', $this->prefix),
|
553 |
'type_matrix_description' => __('Table of Fields lets you place a matrix on your form, which will let the submitter to answer a few questions with one field.', $this->prefix).'<br><br>'.__('It allows you to configure the matrix with radio buttons, checkboxes, text boxes or drop-downs. Use Input Type option to set this.', $this->prefix),
|
554 |
'type_hidden_description' => __('Hidden Input field is similar to Single Line Text field, but it is not visible to users. Hidden Fields are handy, in case you need to run a custom Javascript and submit the result with the info on your form.', $this->prefix).'<br><br>'.__('Name option of this field is mandatory. Note: we highly recommend you to avoid using spaces or special characters in Hidden Input name. You can write the custom Javascript code using the editor on Form Options > Javascript page.', $this->prefix),
|
565 |
'type_stripe_description' => __('This field adds the credit card details inputs (card number, expiration date, etc.) and allows you to accept direct payments made by credit cards.', $this->prefix),
|
566 |
));
|
567 |
|
568 |
+
wp_register_script($this->handle_prefix . '-codemirror', $this->plugin_url . '/js/layout/codemirror.js', array(), '2.3');
|
569 |
+
wp_register_script($this->handle_prefix . '-clike', $this->plugin_url . '/js/layout/clike.js', array(), '1.0.0');
|
570 |
+
wp_register_script($this->handle_prefix . '-formatting', $this->plugin_url . '/js/layout/formatting.js', array(), '1.0.0');
|
571 |
+
wp_register_script($this->handle_prefix . '-css', $this->plugin_url . '/js/layout/css.js', array(), '1.0.0');
|
572 |
+
wp_register_script($this->handle_prefix . '-javascript', $this->plugin_url . '/js/layout/javascript.js', array(), '1.0.0');
|
573 |
+
wp_register_script($this->handle_prefix . '-xml', $this->plugin_url . '/js/layout/xml.js', array(), '1.0.0');
|
574 |
+
wp_register_script($this->handle_prefix . '-php', $this->plugin_url . '/js/layout/php.js', array(), '1.0.0');
|
575 |
+
wp_register_script($this->handle_prefix . '-htmlmixed', $this->plugin_url . '/js/layout/htmlmixed.js', array(), '1.0.0');
|
576 |
|
577 |
+
wp_register_script($this->handle_prefix . '-colorpicker', $this->plugin_url . '/js/spectrum.js', array(), $this->plugin_version);
|
578 |
|
579 |
+
wp_register_script($this->handle_prefix . '-themes', $this->plugin_url . '/js/themes.js', array(), $this->plugin_version);
|
580 |
|
581 |
+
wp_register_script($this->handle_prefix . '-submissions', $this->plugin_url . '/js/form_maker_submissions.js', array(), $this->plugin_version);
|
582 |
+
wp_register_script($this->handle_prefix . '-ng-js', 'https://ajax.googleapis.com/ajax/libs/angularjs/1.5.0/angular.min.js', array(), '1.5.0');
|
583 |
|
584 |
+
wp_localize_script($this->handle_prefix . '-admin', 'form_maker', array(
|
585 |
+
'countries' => WDW_FM_Library(self::PLUGIN)->get_countries(),
|
586 |
'delete_confirmation' => __('Do you want to delete selected items?', $this->prefix),
|
587 |
'select_at_least_one_item' => __('You must select at least one item.', $this->prefix),
|
588 |
+
'add_placeholder' => __('Add placeholder', $this->prefix),
|
589 |
));
|
590 |
if (!$this->is_free) {
|
591 |
wp_register_script('jquery.fancybox.pack', $this->plugin_url . '/js/fancybox/jquery.fancybox.pack.js', array(), '2.1.5');
|
592 |
}
|
593 |
else {
|
594 |
+
wp_register_style($this->handle_prefix . '-deactivate-css', $this->plugin_url . '/wd/assets/css/deactivate_popup.css', array(), $this->plugin_version);
|
595 |
+
wp_register_script($this->handle_prefix . '-deactivate-popup', $this->plugin_url . '/wd/assets/js/deactivate_popup.js', array(), $this->plugin_version, true );
|
596 |
$admin_data = wp_get_current_user();
|
597 |
+
wp_localize_script( $this->handle_prefix . '-deactivate-popup', ($this->is_free == 2 ? 'cfmWDDeactivateVars' : 'fmWDDeactivateVars'), array(
|
598 |
"prefix" => "fm" ,
|
599 |
"deactivate_class" => 'fm_deactivate_link',
|
600 |
"email" => $admin_data->data->user_email,
|
601 |
"plugin_wd_url" => "https://web-dorado.com/files/fromContactForm.php",
|
602 |
));
|
|
|
603 |
}
|
604 |
+
wp_register_style($this->handle_prefix . '-pricing', $this->plugin_url . '/css/pricing.css', array(), $this->plugin_version);
|
605 |
}
|
606 |
|
607 |
/**
|
608 |
* Admin ajax scripts.
|
609 |
*/
|
610 |
public function register_admin_ajax_scripts() {
|
611 |
+
wp_register_style($this->handle_prefix . '-tables', $this->plugin_url . '/css/form_maker_tables.css', array(), $this->plugin_version);
|
612 |
+
wp_register_style($this->handle_prefix . '-style', $this->plugin_url . '/css/style.css', array(), $this->plugin_version);
|
613 |
+
wp_register_style($this->handle_prefix . '-jquery-ui', $this->plugin_url . '/css/jquery-ui.custom.css', array(), $this->plugin_version);
|
614 |
|
615 |
+
wp_register_script($this->handle_prefix . '-shortcode' . $this->menu_postfix, $this->plugin_url . '/js/shortcode.js', array('jquery'), $this->plugin_version);
|
616 |
|
617 |
+
$fm_settings = get_option($this->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
618 |
$google_map_key = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
619 |
|
620 |
wp_register_script('google-maps', 'https://maps.google.com/maps/api/js?v=3.exp' . $google_map_key);
|
621 |
+
wp_register_script($this->handle_prefix . '-gmap_form', $this->plugin_url . '/js/if_gmap_back_end.js', array(), $this->plugin_version);
|
622 |
|
623 |
+
wp_localize_script($this->handle_prefix . '-shortcode' . $this->menu_postfix, 'form_maker', array(
|
624 |
'insert_form' => __('You must select a form', $this->prefix),
|
625 |
'update' => __('Update', $this->prefix),
|
626 |
));
|
627 |
+
wp_register_style($this->handle_prefix . '-pricing', $this->plugin_url . '/css/pricing.css', array(), $this->plugin_version);
|
628 |
+
// Roboto font for submissions shortcode.
|
629 |
+
wp_register_style($this->handle_prefix . '-roboto', 'https://fonts.googleapis.com/css?family=Roboto:300,400,500,700');
|
630 |
}
|
631 |
|
632 |
/**
|
633 |
* admin-ajax actions for admin.
|
634 |
*/
|
635 |
public function form_maker_ajax() {
|
636 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('action');
|
|
|
|
|
637 |
if ( $page != 'formmakerwdcaptcha' . $this->plugin_postfix && $page != 'formmakerwdmathcaptcha' . $this->plugin_postfix && $page != 'checkpaypal' . $this->plugin_postfix ) {
|
638 |
if ( function_exists('current_user_can') ) {
|
639 |
if ( !current_user_can('manage_options') ) {
|
658 |
* admin-ajax actions for site.
|
659 |
*/
|
660 |
public function form_maker_ajax_frontend() {
|
661 |
+
$allowed_pages = array(
|
662 |
+
'form_submissions',
|
663 |
+
);
|
664 |
+
$allowed_actions = array(
|
665 |
+
'frontend_generate_xml',
|
666 |
+
'frontend_generate_csv',
|
667 |
+
'frontend_paypal_info',
|
668 |
+
'frontend_show_matrix',
|
669 |
+
'frontend_show_map',
|
670 |
+
'get_frontend_stats',
|
671 |
+
);
|
672 |
+
|
673 |
+
$action = WDW_FM_Library(self::PLUGIN)->get('action');
|
674 |
+
$page = WDW_FM_Library(self::PLUGIN)->get('page');
|
675 |
+
if ( !empty($page) && in_array($page, $allowed_pages)
|
676 |
+
&& !empty($action) && in_array($action, $allowed_actions) ) {
|
677 |
$this->register_frontend_ajax_scripts();
|
678 |
require_once ($this->plugin_dir . '/frontend/controllers/' . $page . '.php');
|
679 |
$controller_class = 'FMController' . ucfirst($page);
|
724 |
echo __('Sorry, you are not allowed to access this page.', $this->prefix);
|
725 |
}
|
726 |
else {
|
727 |
+
$id = WDW_FM_Library(self::PLUGIN)->get('wdform_id', 0);
|
728 |
+
$display_options = WDW_FM_Library(self::PLUGIN)->display_options( $id );
|
729 |
$type = $display_options->type;
|
730 |
|
731 |
$attrs = array( 'id' => $id );
|
759 |
public function FM_front_end_main($params = array(), $type = '') {
|
760 |
if ( !isset($params['type']) ) {
|
761 |
$form_id = isset($params['id']) ? (int) $params['id'] : 0;
|
762 |
+
if ($this->is_free == 2) {
|
763 |
+
wd_contact_form_maker($form_id, $type);
|
764 |
+
}
|
765 |
+
else {
|
766 |
+
wd_form_maker( $form_id, $type );
|
767 |
+
}
|
768 |
}
|
769 |
else if (!$this->is_free) {
|
770 |
$shortcode_deafults = array(
|
782 |
|
783 |
require_once($this->plugin_dir . '/frontend/controllers/form_submissions.php');
|
784 |
$controller = new FMControllerForm_submissions();
|
785 |
+
|
786 |
$submissions = $controller->execute($params);
|
787 |
|
788 |
echo $submissions;
|
795 |
*/
|
796 |
public function fm_email_verification_shortcode() {
|
797 |
require_once($this->plugin_dir . '/frontend/controllers/verify_email.php');
|
798 |
+
$controller_class = 'FMControllerVerify_email' . $this->plugin_postfix;
|
799 |
$controller = new $controller_class();
|
800 |
$controller->execute();
|
801 |
}
|
817 |
)
|
818 |
);
|
819 |
|
820 |
+
register_post_type(($this->is_free == 2 ? 'cfmemailverification' : 'fmemailverification'), $args);
|
821 |
}
|
822 |
+
|
823 |
/**
|
824 |
* Register form preview custom post type.
|
825 |
*/
|
838 |
);
|
839 |
|
840 |
register_post_type('form-maker' . $this->plugin_postfix, $args);
|
841 |
+
}
|
842 |
+
|
843 |
/**
|
844 |
* Frontend scripts/styles.
|
845 |
*/
|
846 |
public function register_frontend_scripts() {
|
847 |
+
$front_plugin_url = $this->front_urls['plugin_url'];
|
848 |
+
wp_register_style($this->handle_prefix . '-jquery-ui', $front_plugin_url . '/css/jquery-ui.custom.css', array(), $this->plugin_version);
|
849 |
|
850 |
+
$fm_settings = get_option($this->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
851 |
$google_map_key = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
852 |
wp_register_script('google-maps', 'https://maps.google.com/maps/api/js?v=3.exp' . $google_map_key);
|
853 |
|
854 |
+
wp_register_script($this->handle_prefix . '-phone_field', $front_plugin_url . '/js/intlTelInput.js', array(), $this->plugin_version);
|
855 |
|
856 |
+
wp_register_style($this->handle_prefix . '-phone_field_css', $front_plugin_url . '/css/intlTelInput.css', array(), $this->plugin_version);
|
857 |
+
wp_register_style($this->handle_prefix . '-frontend', $front_plugin_url . '/css/form_maker_frontend.css', array(), $this->plugin_version);
|
858 |
|
859 |
+
wp_register_script($this->handle_prefix . '-frontend', $front_plugin_url . '/js/main_div_front_end.js', array(), $this->plugin_version);
|
860 |
+
wp_register_script($this->handle_prefix . '-gmap_form', $front_plugin_url . '/js/if_gmap_front_end.js', array(), $this->plugin_version);
|
861 |
|
862 |
+
wp_localize_script($this->handle_prefix . '-frontend', 'fm_objectL10n', array(
|
863 |
+
'states' => WDW_FM_Library(self::PLUGIN)->get_states(),
|
864 |
+
'plugin_url' => $front_plugin_url,
|
865 |
'form_maker_admin_ajax' => admin_url('admin-ajax.php'),
|
866 |
'fm_file_type_error' => addslashes(__('Can not upload this type of file', $this->prefix)),
|
867 |
'fm_field_is_required' => addslashes(__('Field is required', $this->prefix)),
|
876 |
'year_validation' => addslashes(sprintf(__('The year must be between %s and %s', $this->prefix), '%%start%%', '%%end%%')),
|
877 |
));
|
878 |
|
879 |
+
$google_fonts = WDW_FM_Library(self::PLUGIN)->get_google_fonts();
|
880 |
$fonts = implode("|", str_replace(' ', '+', $google_fonts));
|
881 |
+
wp_register_style($this->handle_prefix . '-googlefonts', 'https://fonts.googleapis.com/css?family=' . $fonts . '&subset=greek,latin,greek-ext,vietnamese,cyrillic-ext,latin-ext,cyrillic', null, null);
|
882 |
|
883 |
+
wp_register_style($this->handle_prefix . '-animate', $front_plugin_url . '/css/fm-animate.css', array(), $this->plugin_version);
|
884 |
|
885 |
+
wp_register_script($this->handle_prefix . '-g-recaptcha', 'https://www.google.com/recaptcha/api.js?onload=fmRecaptchaInit&render=explicit');
|
886 |
|
887 |
// Register admin styles to use in frontend submissions.
|
888 |
+
wp_register_script('gmap_form_back', $front_plugin_url . '/js/if_gmap_back_end.js', array(), $this->plugin_version);
|
889 |
|
890 |
if (!$this->is_free) {
|
891 |
+
wp_register_script($this->handle_prefix . '-file-upload', $front_plugin_url . '/js/file-upload.js', array(), $this->plugin_version);
|
892 |
+
wp_register_style($this->handle_prefix . '-submissions_css', $front_plugin_url . '/css/style_submissions.css', array(), $this->plugin_version);
|
893 |
}
|
894 |
}
|
895 |
|
897 |
* Frontend ajax scripts.
|
898 |
*/
|
899 |
public function register_frontend_ajax_scripts() {
|
900 |
+
$front_plugin_url = $this->front_urls['plugin_url'];
|
901 |
+
$fm_settings = get_option($this->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
902 |
$google_map_key = !empty($fm_settings['map_key']) ? '&key=' . $fm_settings['map_key'] : '';
|
903 |
wp_register_script('google-maps', 'https://maps.google.com/maps/api/js?v=3.exp' . $google_map_key);
|
904 |
+
wp_register_script($this->handle_prefix . '-gmap_form_back', $front_plugin_url . '/js/if_gmap_back_end.js', array(), $this->plugin_version);
|
905 |
}
|
906 |
|
907 |
/**
|
909 |
*/
|
910 |
public function form_maker_on_activate() {
|
911 |
$this->form_maker_activate();
|
912 |
+
if ($this->is_free == 2) {
|
913 |
+
WDCFMInsert::install_demo_forms();
|
914 |
+
}
|
915 |
+
else {
|
916 |
+
WDFMInsert::install_demo_forms();
|
917 |
+
}
|
918 |
$this->init();
|
919 |
flush_rewrite_rules();
|
920 |
}
|
938 |
}
|
939 |
else {
|
940 |
add_option("wd_form_maker_version", $new_version, '', 'no');
|
941 |
+
if ($this->is_free == 2) {
|
942 |
+
WDCFMInsert::form_maker_insert();
|
943 |
+
}
|
944 |
+
else {
|
945 |
+
WDFMInsert::form_maker_insert();
|
946 |
+
}
|
947 |
$email_verification_post = array(
|
948 |
'post_title' => 'Email Verification',
|
949 |
'post_content' => '[email_verification]',
|
950 |
'post_status' => 'publish',
|
951 |
'post_author' => 1,
|
952 |
+
'post_type' => ($this->is_free == 2 ? 'cfmemailverification' : 'fmemailverification'),
|
953 |
);
|
954 |
$mail_verification_post_id = wp_insert_post($email_verification_post);
|
955 |
|
956 |
+
add_option(($this->is_free == 2 ? 'fmc_settings' : 'fm_settings'), array('public_key' => '', 'private_key' => '', 'csv_delimiter' => ',', 'map_key' => ''));
|
957 |
$wpdb->update($wpdb->prefix . "formmaker", array(
|
958 |
'mail_verification_post_id' => $mail_verification_post_id,
|
959 |
), array('id' => 1), array(
|
969 |
foreach ($mail_verification_post_ids as $mail_verification_post_id) {
|
970 |
$update_email_ver_post_type = array(
|
971 |
'ID' => (int)$mail_verification_post_id->mail_verification_post_id,
|
972 |
+
'post_type' => ($this->is_free == 2 ? 'cfmemailverification' : 'fmemailverification'),
|
973 |
);
|
974 |
wp_update_post($update_email_ver_post_type);
|
975 |
}
|
976 |
}
|
977 |
+
if ($this->is_free == 2) {
|
978 |
+
WDCFMUpdate::form_maker_update($version);
|
979 |
+
}
|
980 |
+
else {
|
981 |
+
WDFMUpdate::form_maker_update($version);
|
982 |
+
}
|
983 |
update_option("wd_form_maker_version", $new_version);
|
984 |
|
985 |
+
if (FALSE === $fm_settings = get_option($this->is_free == 2 ? 'fmc_settings' : 'fm_settings')) {
|
986 |
$recaptcha_keys = $wpdb->get_row('SELECT `public_key`, `private_key` FROM ' . $wpdb->prefix . 'formmaker WHERE public_key!="" and private_key!=""', ARRAY_A);
|
987 |
$public_key = isset($recaptcha_keys['public_key']) ? $recaptcha_keys['public_key'] : '';
|
988 |
$private_key = isset($recaptcha_keys['private_key']) ? $recaptcha_keys['private_key'] : '';
|
989 |
+
add_option(($this->is_free == 2 ? 'fmc_settings' : 'fm_settings'), array('public_key' => $public_key, 'private_key' => $private_key, 'csv_delimiter' => ',', 'map_key' => ''));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
990 |
}
|
991 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
992 |
}
|
993 |
|
994 |
/**
|
1001 |
}
|
1002 |
global $cfm_options;
|
1003 |
$cfm_options = array(
|
1004 |
+
"prefix" => ($this->is_free == 2 ? 'cfm' : 'fm'),
|
1005 |
+
"wd_plugin_id" => ($this->is_free == 2 ? 183 : 31),
|
1006 |
+
"plugin_title" => ($this->is_free == 2 ? 'Contact Form Maker' : 'Form Maker'),
|
1007 |
+
"plugin_wordpress_slug" => ($this->is_free == 2 ? 'contact-form-maker' : 'form-maker'),
|
1008 |
"plugin_dir" => $this->plugin_dir,
|
1009 |
"plugin_main_file" => __FILE__,
|
1010 |
+
"description" => ($this->is_free == 2 ? __('WordPress Contact Form Maker is a simple contact form builder, which allows the user with almost no knowledge of programming to create and edit different type of contact forms.', $this->prefix) : __('Form Maker plugin is a modern and advanced tool for easy and fast creating of a WordPress Form. The backend interface is intuitive and user friendly which allows users far from scripting and programming to create WordPress Forms.', $this->prefix)),
|
1011 |
// from web-dorado.com
|
1012 |
"plugin_features" => array(
|
1013 |
0 => array(
|
1029 |
4 => array(
|
1030 |
"title" => __("Themes", $this->prefix),
|
1031 |
"description" => __("The WordPress Form Maker plugin comes with a wide range of customizable themes. You can choose from a list of existing themes or simply create the one that better fits your brand and website.", $this->prefix),
|
1032 |
+
)
|
1033 |
),
|
1034 |
// user guide from web-dorado.com
|
1035 |
"user_guide" => array(
|
1036 |
0 => array(
|
1037 |
"main_title" => __("Installing", $this->prefix),
|
1038 |
"url" => "https://web-dorado.com/wordpress-form-maker/introduction.html",
|
1039 |
+
"titles" => array()
|
1040 |
),
|
1041 |
1 => array(
|
1042 |
"main_title" => __("Creating a new Form", $this->prefix),
|
1043 |
"url" => "https://web-dorado.com/wordpress-form-maker/creating-form.html",
|
1044 |
+
"titles" => array()
|
1045 |
),
|
1046 |
2 => array(
|
1047 |
"main_title" => __("Configuring Form Options", $this->prefix),
|
1048 |
"url" => "https://web-dorado.com/wordpress-form-maker/form-options/general-options.html",
|
1049 |
+
"titles" => array()
|
1050 |
),
|
1051 |
3 => array(
|
1052 |
"main_title" => __("Description of The Form Fields", $this->prefix),
|
1056 |
"title" => __("Selecting Options from Database", $this->prefix),
|
1057 |
"url" => "https://web-dorado.com/wordpress-form-maker/description-of-form-fields/selecting-options-from-database.html",
|
1058 |
),
|
1059 |
+
)
|
1060 |
),
|
1061 |
4 => array(
|
1062 |
"main_title" => __("Publishing the Created Form", $this->prefix),
|
1063 |
"url" => "https://web-dorado.com/wordpress-form-maker/creating-form.html",
|
1064 |
+
"titles" => array()
|
1065 |
),
|
1066 |
5 => array(
|
1067 |
"main_title" => __("Blocking IPs", $this->prefix),
|
1068 |
"url" => "https://web-dorado.com/wordpress-form-maker/submissions.html",
|
1069 |
+
"titles" => array()
|
1070 |
),
|
1071 |
6 => array(
|
1072 |
"main_title" => __("Managing Submissions", $this->prefix),
|
1073 |
"url" => "https://web-dorado.com/wordpress-form-maker/submissions.html",
|
1074 |
+
"titles" => array()
|
1075 |
),
|
1076 |
7 => array(
|
1077 |
"main_title" => __("Publishing Submissions", $this->prefix),
|
1078 |
"url" => "https://web-dorado.com/wordpress-form-maker/other-publishing-options.html",
|
1079 |
+
"titles" => array()
|
1080 |
),
|
1081 |
),
|
1082 |
"video_youtube_id" => "tN3_c6MhqFk", // e.g. https://www.youtube.com/watch?v=acaexefeP7o youtube id is the acaexefeP7o
|
1083 |
"plugin_wd_url" => "https://web-dorado.com/files/fromContactForm.php",
|
1084 |
"plugin_wd_demo_link" => "http://wpdemo.web-dorado.com",
|
1085 |
"plugin_wd_addons_link" => "https://web-dorado.com/products/wordpress-form/add-ons.html",
|
1086 |
+
"after_subscribe" => admin_url('admin.php?page=overview_' . ($this->is_free == 2 ? 'cfm' : 'fm')), // this can be plagin overview page or set up page
|
1087 |
"plugin_wizard_link" => '',
|
1088 |
"plugin_menu_title" => $this->nicename,
|
1089 |
"plugin_menu_icon" => $this->plugin_url . '/images/FormMakerLogo-16.png',
|
1108 |
ob_start();
|
1109 |
$url = add_query_arg(array('action' => 'FMShortocde' . $this->plugin_postfix, 'task' => 'form', 'TB_iframe' => '1'), admin_url('admin-ajax.php'));
|
1110 |
?>
|
1111 |
+
<a onclick="tb_click.call(this); fm_set_shortcode_popup_dimensions(400, 140); return false;" href="<?php echo $url; ?>" class="button" title="<?php _e('Insert Form', $this->prefix); ?>">
|
1112 |
<span class="wp-media-buttons-icon" style="background: url('<?php echo $this->plugin_url; ?>/images/fm-media-form-button.png') no-repeat scroll left top rgba(0, 0, 0, 0);"></span>
|
1113 |
+
<?php _e('Add Form', $this->prefix); ?>
|
1114 |
</a>
|
1115 |
<?php
|
1116 |
$url = add_query_arg(array('action' => 'FMShortocde' . $this->plugin_postfix, 'task' => 'submissions', 'TB_iframe' => '1'), admin_url('admin-ajax.php'));
|
1117 |
?>
|
1118 |
+
<a onclick="tb_click.call(this); fm_set_shortcode_popup_dimensions(520, 570); return false;" href="<?php echo $url; ?>" class="button" title="<?php _e('Insert submissions', $this->prefix); ?>">
|
1119 |
<span class="wp-media-buttons-icon" style="background: url('<?php echo $this->plugin_url; ?>/images/fm-media-submissions-button.png') no-repeat scroll left top rgba(0, 0, 0, 0);"></span>
|
1120 |
<?php _e('Add Submissions', $this->prefix); ?>
|
1121 |
</a>
|
1131 |
*
|
1132 |
*/
|
1133 |
function fm_check_addons_compatibility() {
|
1134 |
+
// Last version not supported.
|
1135 |
$add_ons = array(
|
1136 |
'form-maker-export-import' => array('version' => '2.0.7', 'file' => 'fm_exp_imp.php'),
|
1137 |
'form-maker-save-progress' => array('version' => '1.0.1', 'file' => 'fm_save.php'),
|
1142 |
'form-maker-post-generation' => array('version' => '1.0.2', 'file' => 'fm_post_generation.php'),
|
1143 |
'form-maker-dropbox-integration' => array('version' => '1.1.1', 'file' => 'fm_dropbox_integration.php'),
|
1144 |
'form-maker-gdrive-integration' => array('version' => '1.0.0', 'file' => 'fm_gdrive_integration.php'),
|
1145 |
+
'form-maker-pdf-integration' => array('version' => '1.1.3', 'file' => 'fm_pdf_integration.php'),
|
1146 |
'form-maker-stripe' => array('version' => '1.0.1', 'file' => 'fm_stripe.php'),
|
1147 |
'form-maker-calculator' => array('version' => '1.0.3', 'file' => 'fm_calculator.php'),
|
1148 |
);
|
1186 |
}
|
1187 |
|
1188 |
/**
|
1189 |
+
* Main instance of WDFM.
|
1190 |
*
|
1191 |
+
* @return WDFM The main instance to prevent the need to use globals.
|
1192 |
*/
|
1193 |
+
if (!function_exists('WDFMInstance')) {
|
1194 |
+
function WDFMInstance( $version ) {
|
1195 |
+
if ( $version == 2 ) {
|
1196 |
+
return WDCFM::instance();
|
1197 |
+
}
|
1198 |
+
return WDFM::instance();
|
1199 |
+
}
|
1200 |
}
|
1201 |
|
1202 |
+
WDFMInstance(2);
|
1203 |
+
|
1204 |
+
if (!function_exists('WDW_FM_Library')) {
|
1205 |
+
function WDW_FM_Library( $version = 1 ) {
|
1206 |
+
if ( $version == 2 ) {
|
1207 |
+
return WDW_FMC_Library::instance();
|
1208 |
+
}
|
1209 |
+
return WDW_FM_Library::instance();
|
1210 |
+
}
|
1211 |
}
|
1212 |
|
1213 |
/**
|
1217 |
* @param string $type
|
1218 |
*/
|
1219 |
function wd_contact_form_maker($id, $type = 'embedded') {
|
1220 |
+
require_once (WDFMInstance(2)->plugin_dir . '/frontend/controllers/form_maker.php');
|
1221 |
$controller = new FMControllerForm_maker_fmc();
|
1222 |
$form = $controller->execute($id, $type);
|
1223 |
echo $form;
|
1240 |
$meta_value = get_option('wd_bk_notice_status');
|
1241 |
if ( $meta_value === '' || $meta_value === FALSE ) {
|
1242 |
ob_start();
|
1243 |
+
$prefix = WDFMInstance(2)->prefix;
|
1244 |
+
$nicename = WDFMInstance(2)->nicename;
|
1245 |
+
$url = WDFMInstance(2)->plugin_url;
|
1246 |
$dismiss_url = add_query_arg(array( 'action' => 'wd_bp_dismiss' ), admin_url('admin-ajax.php'));
|
1247 |
$install_url = esc_url(wp_nonce_url(self_admin_url('update.php?action=install-plugin&plugin=backup-wd'), 'install-plugin_backup-wd'));
|
1248 |
?>
|
1313 |
function fmc_add_plugin_meta_links($meta_fields, $file) {
|
1314 |
if ( plugin_basename(__FILE__) == $file ) {
|
1315 |
$plugin_url = "https://wordpress.org/support/plugin/contact-form-maker";
|
1316 |
+
$prefix = WDFMInstance(2)->prefix;
|
1317 |
$meta_fields[] = "<a href='" . $plugin_url . "' target='_blank'>" . __('Support Forum', $prefix) . "</a>";
|
1318 |
$meta_fields[] = "<a href='" . $plugin_url . "/reviews#new-post' target='_blank' title='" . __('Rate', $prefix) . "'>
|
1319 |
<i class='wdi-rate-stars'>"
|
1337 |
return $meta_fields;
|
1338 |
}
|
1339 |
|
1340 |
+
if ( WDFMInstance(2)->is_free ) {
|
1341 |
add_filter("plugin_row_meta", 'fmc_add_plugin_meta_links', 10, 2);
|
1342 |
}
|
css/form_maker_frontend.css
CHANGED
@@ -147,6 +147,7 @@ div[type="type_captcha"] .wdform-element-section * {
|
|
147 |
color: #FF0000;
|
148 |
font-size: 13px;
|
149 |
width: 100%;
|
|
|
150 |
}
|
151 |
|
152 |
.fm-form-container .fm-form div[type="type_phone_new"] input[type="text"]{
|
@@ -434,7 +435,7 @@ div[type="type_file_upload"] .wdform-element-section {
|
|
434 |
}
|
435 |
|
436 |
.fm-form .paypal-property .wdform-quantity {
|
437 |
-
width:
|
438 |
}
|
439 |
|
440 |
.fm-form .paypal-property select {
|
147 |
color: #FF0000;
|
148 |
font-size: 13px;
|
149 |
width: 100%;
|
150 |
+
padding-left: 10px;
|
151 |
}
|
152 |
|
153 |
.fm-form-container .fm-form div[type="type_phone_new"] input[type="text"]{
|
435 |
}
|
436 |
|
437 |
.fm-form .paypal-property .wdform-quantity {
|
438 |
+
width: 55px;
|
439 |
}
|
440 |
|
441 |
.fm-form .paypal-property select {
|
css/form_maker_tables.css
CHANGED
@@ -1,3 +1,7 @@
|
|
|
|
|
|
|
|
|
|
1 |
.wd-button .field-type-button:before {
|
2 |
float: left;
|
3 |
font-family: "Dashicons";
|
@@ -168,6 +172,7 @@
|
|
168 |
}
|
169 |
|
170 |
.field_types_cont h2.hndle,
|
|
|
171 |
.field_options h2.hndle {
|
172 |
background-color: #F1F1F1;
|
173 |
}
|
@@ -176,7 +181,8 @@
|
|
176 |
border: 1px solid #eee;
|
177 |
}
|
178 |
|
179 |
-
.field-types-filter
|
|
|
180 |
webkit-box-shadow: 0 1px 4px rgba(0,0,0,.07)!important;
|
181 |
box-shadow: 0 1px 4px rgba(0,0,0,.07)!important;
|
182 |
}
|
@@ -341,7 +347,8 @@
|
|
341 |
text-shadow: 0 -1px 1px #cccccc, 1px 0 1px #cccccc, 0 1px 1px #cccccc, -1px 0 1px #cccccc;
|
342 |
}
|
343 |
|
344 |
-
.field_types .postbox h2.hndle
|
|
|
345 |
font-size: 14px;
|
346 |
padding: 8px 12px;
|
347 |
margin: 0;
|
@@ -360,11 +367,13 @@
|
|
360 |
cursor: pointer;
|
361 |
}
|
362 |
|
363 |
-
.field_types .postbox
|
|
|
364 |
margin-bottom: 0;
|
365 |
}
|
366 |
|
367 |
-
.field_types .postbox button.wd-button
|
|
|
368 |
margin: 5px 0px;
|
369 |
white-space: normal;
|
370 |
width: 48%;
|
@@ -375,7 +384,8 @@
|
|
375 |
height: auto;
|
376 |
}
|
377 |
|
378 |
-
.add-popup .field-types-filter
|
|
|
379 |
line-height: 25px;
|
380 |
margin: 15px;
|
381 |
width: calc(100% - 45px);
|
@@ -383,13 +393,15 @@
|
|
383 |
background-color: #f5f5f5;
|
384 |
}
|
385 |
|
386 |
-
.add-popup .field-types-filter-cont
|
|
|
387 |
position: relative;
|
388 |
height: 25px;
|
389 |
width: 100%;
|
390 |
}
|
391 |
|
392 |
-
.add-popup .field-types-filter-cont:before
|
|
|
393 |
font-family: "Dashicons";
|
394 |
content: "\f179";
|
395 |
font-size: 25px;
|
@@ -776,19 +788,22 @@ div.error_fm {
|
|
776 |
}
|
777 |
|
778 |
@media screen and (max-width: 360px) {
|
779 |
-
.field_types .postbox button.wd-button
|
|
|
780 |
width: 100%;
|
781 |
}
|
782 |
}
|
783 |
|
784 |
@media screen and (min-width: 360px) and (max-width: 600px) {
|
785 |
-
.field_types .postbox button.wd-button
|
|
|
786 |
width: 48%;
|
787 |
}
|
788 |
}
|
789 |
|
790 |
@media screen and (min-width: 600px) and (max-width: 1050px) {
|
791 |
-
.field_types .postbox button.wd-button
|
|
|
792 |
width: 32%;
|
793 |
}
|
794 |
}
|
@@ -1891,10 +1906,12 @@ button:focus {
|
|
1891 |
font-size: 15px;
|
1892 |
}
|
1893 |
|
1894 |
-
.form_maker_themes th.col_default
|
|
|
1895 |
width:80px;
|
1896 |
}
|
1897 |
-
.form_maker_themes td.col_default
|
|
|
1898 |
padding-left:20px;
|
1899 |
}
|
1900 |
|
@@ -2277,92 +2294,93 @@ button:focus {
|
|
2277 |
top: 36px;
|
2278 |
right: 20px;
|
2279 |
}
|
|
|
2280 |
.fm_form_options #form_javascript {
|
2281 |
-
|
2282 |
}
|
|
|
2283 |
.fm_form_options .CodeMirror {
|
2284 |
-
|
2285 |
-
|
2286 |
-
|
2287 |
-
|
2288 |
}
|
|
|
2289 |
.fm_form_options .fm_condition {
|
2290 |
padding: 20px 0;
|
2291 |
display: table;
|
2292 |
border-bottom: 1px solid #00A0D2;
|
2293 |
width: 100%;
|
2294 |
}
|
|
|
2295 |
.fm_form_options .fm_condition input,
|
2296 |
.fm_form_options .fm_condition select {
|
2297 |
-
|
2298 |
-
|
2299 |
-
|
2300 |
-
|
2301 |
}
|
2302 |
|
2303 |
.fm_form_options .fm_condition .fm_condition_show_hide {
|
2304 |
-
|
2305 |
-
|
2306 |
-
}
|
2307 |
-
.fm_form_options .fm_condition .fm_condition_fields {
|
2308 |
-
|
2309 |
}
|
2310 |
-
.fm_form_options .fm_condition .fm_condition_all_any {
|
2311 |
|
2312 |
-
|
2313 |
-
|
2314 |
-
.fm_form_options .fm_condition .fm_condition_is_select {
|
2315 |
-
max-width:94px;
|
2316 |
-
}
|
2317 |
-
.fm_form_options .fm_condition .fm_condition_field_labels {
|
2318 |
-
|
2319 |
-
}
|
2320 |
-
.fm_form_options .fm_condition .fm_condition_field_select_value {
|
2321 |
-
|
2322 |
}
|
2323 |
-
|
2324 |
-
|
|
|
2325 |
}
|
2326 |
|
2327 |
.fm_form_options .dashicons {
|
2328 |
-
|
2329 |
-
|
2330 |
cursor: pointer;
|
2331 |
}
|
2332 |
.fm_form_options .dashicons-trash, .fm_form_options .dashicons-no-alt { color: #aa0000; }
|
2333 |
.fm_form_options .dashicons-trash:hover, .fm_form_options .dashicons-no-alt:hover { color: #dc3232; }
|
2334 |
.fm_form_options .dashicons-plus-alt { color: #0073aa; }
|
2335 |
.fm_form_options .dashicons-plus-alt:hover { color: #00a0d2; }
|
2336 |
-
|
2337 |
-
.
|
2338 |
-
|
2339 |
-
|
2340 |
-
|
2341 |
-
|
2342 |
-
|
|
|
2343 |
}
|
2344 |
-
|
2345 |
-
|
2346 |
-
|
2347 |
}
|
2348 |
-
|
2349 |
-
|
|
|
|
|
|
|
2350 |
}
|
2351 |
-
|
2352 |
-
|
|
|
|
|
2353 |
}
|
|
|
2354 |
.fm_advanced_layout .autogen_layout_label {
|
2355 |
display: inline-block;
|
2356 |
font-weight: 500;
|
2357 |
padding-top: 5px;
|
2358 |
}
|
2359 |
|
2360 |
-
.fm_advanced_layout
|
2361 |
-
|
2362 |
-
|
2363 |
}
|
2364 |
|
2365 |
-
.form_maker_themes .dashicons
|
|
|
2366 |
font-size: 20px;
|
2367 |
}
|
2368 |
|
@@ -2406,6 +2424,7 @@ button:focus {
|
|
2406 |
background-position-y: 50% !important;
|
2407 |
background-size: 12px !important;
|
2408 |
}
|
|
|
2409 |
.fm-description {
|
2410 |
font-size: 12px;
|
2411 |
margin-left: 20px;
|
@@ -2462,21 +2481,116 @@ button:focus {
|
|
2462 |
}
|
2463 |
|
2464 |
.fm_tooltip {
|
2465 |
-
display:none;
|
2466 |
-
position:absolute;
|
2467 |
-
border:1px solid #333;
|
2468 |
-
background-color
|
2469 |
-
border-radius:5px;
|
2470 |
-
padding:10px;
|
2471 |
-
color
|
2472 |
-
font-size:12px;
|
2473 |
max-width: 250px;
|
2474 |
min-width: 100px;
|
2475 |
word-break: break-all;
|
2476 |
}
|
2477 |
|
2478 |
.form_maker_submissions td,
|
2479 |
-
.form_maker_submissions th{
|
2480 |
max-width: 200px;
|
2481 |
word-break: break-all;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2482 |
}
|
1 |
+
#fm_admin_container {
|
2 |
+
display: inline-block;
|
3 |
+
width: 100%;
|
4 |
+
}
|
5 |
.wd-button .field-type-button:before {
|
6 |
float: left;
|
7 |
font-family: "Dashicons";
|
172 |
}
|
173 |
|
174 |
.field_types_cont h2.hndle,
|
175 |
+
.placeholders_cont h2.hndle,
|
176 |
.field_options h2.hndle {
|
177 |
background-color: #F1F1F1;
|
178 |
}
|
181 |
border: 1px solid #eee;
|
182 |
}
|
183 |
|
184 |
+
.field-types-filter,
|
185 |
+
.placeholders-filter {
|
186 |
webkit-box-shadow: 0 1px 4px rgba(0,0,0,.07)!important;
|
187 |
box-shadow: 0 1px 4px rgba(0,0,0,.07)!important;
|
188 |
}
|
347 |
text-shadow: 0 -1px 1px #cccccc, 1px 0 1px #cccccc, 0 1px 1px #cccccc, -1px 0 1px #cccccc;
|
348 |
}
|
349 |
|
350 |
+
.field_types .postbox h2.hndle,
|
351 |
+
.placeholders .postbox h2.hndle {
|
352 |
font-size: 14px;
|
353 |
padding: 8px 12px;
|
354 |
margin: 0;
|
367 |
cursor: pointer;
|
368 |
}
|
369 |
|
370 |
+
.field_types .postbox,
|
371 |
+
.placeholders .postbox {
|
372 |
margin-bottom: 0;
|
373 |
}
|
374 |
|
375 |
+
.field_types .postbox button.wd-button,
|
376 |
+
.placeholders .postbox button.wd-button {
|
377 |
margin: 5px 0px;
|
378 |
white-space: normal;
|
379 |
width: 48%;
|
384 |
height: auto;
|
385 |
}
|
386 |
|
387 |
+
.add-popup .field-types-filter,
|
388 |
+
.placeholder-popup .placeholders-filter {
|
389 |
line-height: 25px;
|
390 |
margin: 15px;
|
391 |
width: calc(100% - 45px);
|
393 |
background-color: #f5f5f5;
|
394 |
}
|
395 |
|
396 |
+
.add-popup .field-types-filter-cont,
|
397 |
+
.placeholder-popup .placeholders-filter-cont {
|
398 |
position: relative;
|
399 |
height: 25px;
|
400 |
width: 100%;
|
401 |
}
|
402 |
|
403 |
+
.add-popup .field-types-filter-cont:before,
|
404 |
+
.placeholder-popup .placeholders-filter-cont:before {
|
405 |
font-family: "Dashicons";
|
406 |
content: "\f179";
|
407 |
font-size: 25px;
|
788 |
}
|
789 |
|
790 |
@media screen and (max-width: 360px) {
|
791 |
+
.field_types .postbox button.wd-button,
|
792 |
+
.placeholders .postbox button.wd-button {
|
793 |
width: 100%;
|
794 |
}
|
795 |
}
|
796 |
|
797 |
@media screen and (min-width: 360px) and (max-width: 600px) {
|
798 |
+
.field_types .postbox button.wd-button,
|
799 |
+
.placeholders .postbox button.wd-button {
|
800 |
width: 48%;
|
801 |
}
|
802 |
}
|
803 |
|
804 |
@media screen and (min-width: 600px) and (max-width: 1050px) {
|
805 |
+
.field_types .postbox button.wd-button,
|
806 |
+
.placeholders .postbox button.wd-button {
|
807 |
width: 32%;
|
808 |
}
|
809 |
}
|
1906 |
font-size: 15px;
|
1907 |
}
|
1908 |
|
1909 |
+
.form_maker_themes th.col_default,
|
1910 |
+
.form_maker_fmc_themes th.col_default {
|
1911 |
width:80px;
|
1912 |
}
|
1913 |
+
.form_maker_themes td.col_default,
|
1914 |
+
.form_maker_fmc_themes td.col_default {
|
1915 |
padding-left:20px;
|
1916 |
}
|
1917 |
|
2294 |
top: 36px;
|
2295 |
right: 20px;
|
2296 |
}
|
2297 |
+
|
2298 |
.fm_form_options #form_javascript {
|
2299 |
+
min-height: 400px;
|
2300 |
}
|
2301 |
+
|
2302 |
.fm_form_options .CodeMirror {
|
2303 |
+
border: 1px solid #CCC;
|
2304 |
+
font-size: 12px;
|
2305 |
+
margin-bottom: 6px;
|
2306 |
+
background: white;
|
2307 |
}
|
2308 |
+
|
2309 |
.fm_form_options .fm_condition {
|
2310 |
padding: 20px 0;
|
2311 |
display: table;
|
2312 |
border-bottom: 1px solid #00A0D2;
|
2313 |
width: 100%;
|
2314 |
}
|
2315 |
+
|
2316 |
.fm_form_options .fm_condition input,
|
2317 |
.fm_form_options .fm_condition select {
|
2318 |
+
display: inline-block;
|
2319 |
+
width: 100%;
|
2320 |
+
max-width: 300px;
|
2321 |
+
margin-bottom: 5px;
|
2322 |
}
|
2323 |
|
2324 |
.fm_form_options .fm_condition .fm_condition_show_hide {
|
2325 |
+
width: 100%;
|
2326 |
+
max-width: 65px;
|
|
|
|
|
|
|
2327 |
}
|
|
|
2328 |
|
2329 |
+
.fm_form_options .fm_condition .fm_condition_all_any {
|
2330 |
+
max-width: 55px;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2331 |
}
|
2332 |
+
|
2333 |
+
.fm_form_options .fm_condition .fm_condition_is_select {
|
2334 |
+
max-width: 94px;
|
2335 |
}
|
2336 |
|
2337 |
.fm_form_options .dashicons {
|
2338 |
+
vertical-align: middle;
|
2339 |
+
font-size: 20px;
|
2340 |
cursor: pointer;
|
2341 |
}
|
2342 |
.fm_form_options .dashicons-trash, .fm_form_options .dashicons-no-alt { color: #aa0000; }
|
2343 |
.fm_form_options .dashicons-trash:hover, .fm_form_options .dashicons-no-alt:hover { color: #dc3232; }
|
2344 |
.fm_form_options .dashicons-plus-alt { color: #0073aa; }
|
2345 |
.fm_form_options .dashicons-plus-alt:hover { color: #00a0d2; }
|
2346 |
+
|
2347 |
+
.wd-has-placeholder {
|
2348 |
+
position: relative;
|
2349 |
+
}
|
2350 |
+
|
2351 |
+
.wd-editor-placeholder {
|
2352 |
+
padding-right: 5px;
|
2353 |
+
text-align: right;
|
2354 |
}
|
2355 |
+
|
2356 |
+
.wd-has-placeholder input[type="text"] {
|
2357 |
+
padding-right: 35px;
|
2358 |
}
|
2359 |
+
|
2360 |
+
.wd-has-placeholder .dashicons.dashicons-list-view {
|
2361 |
+
top: 37px;
|
2362 |
+
right: 5px;
|
2363 |
+
position: absolute;
|
2364 |
}
|
2365 |
+
|
2366 |
+
.fm_form_options #emailTab_fieldset .mail_name {
|
2367 |
+
width: 92%;
|
2368 |
+
display: inline-block;
|
2369 |
}
|
2370 |
+
|
2371 |
.fm_advanced_layout .autogen_layout_label {
|
2372 |
display: inline-block;
|
2373 |
font-weight: 500;
|
2374 |
padding-top: 5px;
|
2375 |
}
|
2376 |
|
2377 |
+
.fm_advanced_layout .fm_auto_format_button {
|
2378 |
+
width: 100%;
|
2379 |
+
text-align: center;
|
2380 |
}
|
2381 |
|
2382 |
+
.form_maker_themes .dashicons,
|
2383 |
+
.form_maker_fmc_themes .dashicons {
|
2384 |
font-size: 20px;
|
2385 |
}
|
2386 |
|
2424 |
background-position-y: 50% !important;
|
2425 |
background-size: 12px !important;
|
2426 |
}
|
2427 |
+
|
2428 |
.fm-description {
|
2429 |
font-size: 12px;
|
2430 |
margin-left: 20px;
|
2481 |
}
|
2482 |
|
2483 |
.fm_tooltip {
|
2484 |
+
display: none;
|
2485 |
+
position: absolute;
|
2486 |
+
border: 1px solid #333;
|
2487 |
+
background-color: #161616;
|
2488 |
+
border-radius: 5px;
|
2489 |
+
padding: 10px;
|
2490 |
+
color: #FFF;
|
2491 |
+
font-size: 12px;
|
2492 |
max-width: 250px;
|
2493 |
min-width: 100px;
|
2494 |
word-break: break-all;
|
2495 |
}
|
2496 |
|
2497 |
.form_maker_submissions td,
|
2498 |
+
.form_maker_submissions th {
|
2499 |
max-width: 200px;
|
2500 |
word-break: break-all;
|
2501 |
+
}
|
2502 |
+
|
2503 |
+
.placeholder-popup {
|
2504 |
+
background: transparent;
|
2505 |
+
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.7);
|
2506 |
+
overflow: hidden;
|
2507 |
+
display: none;
|
2508 |
+
position: relative;
|
2509 |
+
margin-top: 10px;
|
2510 |
+
left: 0;
|
2511 |
+
top: 0;
|
2512 |
+
z-index: 100050;
|
2513 |
+
width: 100%;
|
2514 |
+
height: 435px;
|
2515 |
+
}
|
2516 |
+
.placeholder-body {
|
2517 |
+
background-color: #f5f5f5;
|
2518 |
+
box-sizing: border-box;
|
2519 |
+
-moz-box-sizing: border-box;
|
2520 |
+
-webkit-box-sizing: border-box;
|
2521 |
+
font-family: Segoe UI;
|
2522 |
+
padding: 10px;
|
2523 |
+
margin: 0;
|
2524 |
+
width: 100%;
|
2525 |
+
height: 100%;
|
2526 |
+
}
|
2527 |
+
.placeholder-body-col {
|
2528 |
+
height: 100%;
|
2529 |
+
width: 100%;
|
2530 |
+
display: inline-block;
|
2531 |
+
vertical-align: top;
|
2532 |
+
overflow: auto;
|
2533 |
+
margin-right: 10px;
|
2534 |
+
box-sizing: border-box;
|
2535 |
+
-moz-box-sizing: border-box;
|
2536 |
+
-webkit-box-sizing: border-box;
|
2537 |
+
}
|
2538 |
+
.placeholders_cont {
|
2539 |
+
background-color: #ffffff;
|
2540 |
+
}
|
2541 |
+
.placeholders_cont p.description {
|
2542 |
+
padding: 5px 10px 0px 20px;
|
2543 |
+
}
|
2544 |
+
#placeholders_overlay {
|
2545 |
+
display: none;
|
2546 |
+
position: fixed;
|
2547 |
+
top: 0;
|
2548 |
+
right: 0;
|
2549 |
+
bottom: 0;
|
2550 |
+
left: 0;
|
2551 |
+
background-color: rgba(0,0,0,.5);
|
2552 |
+
z-index: 100049;
|
2553 |
+
}
|
2554 |
+
.placeholders-active #placeholders_overlay {
|
2555 |
+
display: block;
|
2556 |
+
}
|
2557 |
+
.placeholders-active>input,
|
2558 |
+
.placeholders-active textarea,
|
2559 |
+
.placeholders-active .wp-editor-wrap,
|
2560 |
+
.placeholders-active>span.dashicons-list-view {
|
2561 |
+
position: relative;
|
2562 |
+
z-index: 100050;
|
2563 |
+
}
|
2564 |
+
|
2565 |
+
#field_container {
|
2566 |
+
display: inline-block;
|
2567 |
+
width: calc(60% + 16px);
|
2568 |
+
height: 100%;
|
2569 |
+
}
|
2570 |
+
#field_container.field_container_full {
|
2571 |
+
width: 100%;
|
2572 |
+
}
|
2573 |
+
#field_container .popup-body-col {
|
2574 |
+
width: calc(50% - 7px);
|
2575 |
+
}
|
2576 |
+
#field_container .popup-body-col:last-child {
|
2577 |
+
margin-right: 0;
|
2578 |
+
}
|
2579 |
+
#field_container .fm-free-message {
|
2580 |
+
margin-bottom: 7px;
|
2581 |
+
}
|
2582 |
+
#field_container.field_container_full .field_options {
|
2583 |
+
width: calc(70% - 7px);
|
2584 |
+
}
|
2585 |
+
#field_container.field_container_full .field_preview {
|
2586 |
+
width: calc(30% - 7px);
|
2587 |
+
}
|
2588 |
+
@media screen and (max-width: 1050px) {
|
2589 |
+
#field_container,
|
2590 |
+
#field_container .popup-body-col {
|
2591 |
+
width: 100%;
|
2592 |
+
}
|
2593 |
+
}
|
2594 |
+
.fm-opacity-40 {
|
2595 |
+
opacity: 0.4;
|
2596 |
}
|
css/license.css
DELETED
@@ -1,158 +0,0 @@
|
|
1 |
-
div#featurs_tables * {
|
2 |
-
box-sizing: content-box;
|
3 |
-
}
|
4 |
-
div#featurs_tables {
|
5 |
-
display: inline-block;
|
6 |
-
font-size: 13px;
|
7 |
-
padding-top: 95px;
|
8 |
-
text-align: left;
|
9 |
-
float: left;
|
10 |
-
}
|
11 |
-
|
12 |
-
div#featurs_tables div {
|
13 |
-
vertical-align: top;
|
14 |
-
}
|
15 |
-
|
16 |
-
div#featurs_table1 {
|
17 |
-
background-color: rgb(254, 254, 254);
|
18 |
-
display: inline-block;
|
19 |
-
position: relative;
|
20 |
-
vertical-align: top;
|
21 |
-
width: 330px;
|
22 |
-
height: 343px;
|
23 |
-
z-index: 10;
|
24 |
-
}
|
25 |
-
|
26 |
-
div#featurs_table1 span::after {
|
27 |
-
content: "";
|
28 |
-
display: inline-block;
|
29 |
-
float: right;
|
30 |
-
height: 37px;
|
31 |
-
position: relative;
|
32 |
-
right: -21px;
|
33 |
-
top: -8px;
|
34 |
-
width: 26px;
|
35 |
-
}
|
36 |
-
|
37 |
-
div#featurs_table1 span {
|
38 |
-
border-left: 1px solid #e5e5e5;
|
39 |
-
border-right: 1px solid #e5e5e5;
|
40 |
-
border-top: 1px solid #e5e5e5;
|
41 |
-
color: #545454;
|
42 |
-
display: block;
|
43 |
-
height: 21px;
|
44 |
-
padding: 8px;
|
45 |
-
text-align: left;
|
46 |
-
}
|
47 |
-
|
48 |
-
div#featurs_table1 span:last-child,
|
49 |
-
div#featurs_table2 span:last-child,
|
50 |
-
div#featurs_table3 span:last-child {
|
51 |
-
border-bottom: 1px solid #e5e5e5;
|
52 |
-
}
|
53 |
-
|
54 |
-
div#featurs_table2 {
|
55 |
-
background-color: rgba(255, 255, 255, 0.9);
|
56 |
-
display: inline-block;
|
57 |
-
position: relative;
|
58 |
-
top: -72px;
|
59 |
-
width: 180px;
|
60 |
-
}
|
61 |
-
|
62 |
-
div#featurs_table2 span:first-child,
|
63 |
-
div#featurs_table3 span:first-child {
|
64 |
-
color: #000;
|
65 |
-
font-size: 22px;
|
66 |
-
font-weight: bold;
|
67 |
-
padding-bottom: 14px;
|
68 |
-
padding-top: 2px;
|
69 |
-
border-top: 1px solid #e5e5e5;
|
70 |
-
border-left: 1px solid #e5e5e5;
|
71 |
-
border-right: 1px solid #e5e5e5;
|
72 |
-
height: 39px;
|
73 |
-
padding-top: 18px;
|
74 |
-
}
|
75 |
-
|
76 |
-
div#featurs_table2 span:first-child {
|
77 |
-
border-left: 1px solid #e5e5e5 !important;
|
78 |
-
}
|
79 |
-
|
80 |
-
div#featurs_table2 span {
|
81 |
-
border-left: none !important;
|
82 |
-
}
|
83 |
-
|
84 |
-
div#featurs_table2 span,
|
85 |
-
div#featurs_table3 span {
|
86 |
-
border-top: 1px solid #e5e5e5;
|
87 |
-
border-right: 1px solid #e5e5e5;
|
88 |
-
border-left: 1px solid #e5e5e5;
|
89 |
-
color: #545454;
|
90 |
-
display: block;
|
91 |
-
height: 21px;
|
92 |
-
padding: 8px;
|
93 |
-
text-align: center;
|
94 |
-
}
|
95 |
-
|
96 |
-
.download a {
|
97 |
-
background-color: #fff;
|
98 |
-
border: 6px solid #dddddd;
|
99 |
-
border-radius: 50%;
|
100 |
-
box-shadow: 0 0 0 7px #eeeeee;
|
101 |
-
color: #21439c;
|
102 |
-
cursor: pointer;
|
103 |
-
display: inline-block;
|
104 |
-
font-size: 14px;
|
105 |
-
font-style: italic;
|
106 |
-
font-weight: bold;
|
107 |
-
margin-top: -4px;
|
108 |
-
outline: 0 none;
|
109 |
-
padding: 32px 9px 32px 2px;
|
110 |
-
text-align: center;
|
111 |
-
text-decoration: none;
|
112 |
-
transition-duration: 0.6s;
|
113 |
-
transition-property: border-color;
|
114 |
-
transition-timing-function: linear;
|
115 |
-
width: 72px;
|
116 |
-
}
|
117 |
-
|
118 |
-
div#featurs_table3 {
|
119 |
-
background-color: rgba(255, 255, 255, 0.6);
|
120 |
-
display: inline-block;
|
121 |
-
position: relative;
|
122 |
-
top: -72px;
|
123 |
-
width: 180px;
|
124 |
-
}
|
125 |
-
|
126 |
-
div#featurs_table2 span.yes,
|
127 |
-
div#featurs_table3 span.yes {
|
128 |
-
background-image: url("../images/lic_plus.png");
|
129 |
-
background-position: center center;
|
130 |
-
background-repeat: no-repeat;
|
131 |
-
}
|
132 |
-
|
133 |
-
span.no {
|
134 |
-
background-image: url("../images/lic_minus.png");
|
135 |
-
background-position: center center;
|
136 |
-
background-repeat: no-repeat;
|
137 |
-
}
|
138 |
-
|
139 |
-
.download input[type="submit"]:hover,
|
140 |
-
.download a:hover {
|
141 |
-
border-color: #F4762A;
|
142 |
-
}
|
143 |
-
|
144 |
-
#featurs_tables span.download {
|
145 |
-
height: 40px !important;
|
146 |
-
border-bottom: 1px solid #e5e5e5 !important;
|
147 |
-
border-left: 1px solid #e5e5e5 !important;
|
148 |
-
}
|
149 |
-
|
150 |
-
.price_big {
|
151 |
-
color: #F47629;
|
152 |
-
font-size: 22px;
|
153 |
-
}
|
154 |
-
|
155 |
-
.price {
|
156 |
-
display: block;
|
157 |
-
color: #F47629;
|
158 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
css/pricing.css
ADDED
@@ -0,0 +1,860 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
.fm-head-notice { display:none; }
|
2 |
+
.fm-pricestable-container {
|
3 |
+
display: flex;
|
4 |
+
flex-direction: column;
|
5 |
+
max-width: 1150px;
|
6 |
+
width: 100%;
|
7 |
+
margin: 0 auto;
|
8 |
+
}
|
9 |
+
|
10 |
+
.fm-pricestable {
|
11 |
+
display: flex;
|
12 |
+
flex-wrap: wrap;
|
13 |
+
justify-content: center;
|
14 |
+
margin-top: 20px;
|
15 |
+
margin-bottom: 10px;
|
16 |
+
font-family: Roboto;
|
17 |
+
text-align: left;
|
18 |
+
overflow:hidden;
|
19 |
+
}
|
20 |
+
|
21 |
+
.fm-pricestable>div {
|
22 |
+
display: inline-block;
|
23 |
+
margin-right: 15px;
|
24 |
+
margin-top: 20px;
|
25 |
+
padding-bottom: 20px;
|
26 |
+
width: 23%;
|
27 |
+
background: #fff;
|
28 |
+
vertical-align: top;
|
29 |
+
border: 0.5px solid rgba(208, 208, 208, 0.5)
|
30 |
+
}
|
31 |
+
|
32 |
+
.fm-pricestable>div:hover {
|
33 |
+
box-shadow: -1px 1px 6px 0 rgba(52, 52, 52, 0.16);
|
34 |
+
border: 0.5px solid rgba(204, 201, 201, 0.1)
|
35 |
+
}
|
36 |
+
|
37 |
+
.fm-pricestable>div:last-child {
|
38 |
+
margin-right: 0px
|
39 |
+
}
|
40 |
+
|
41 |
+
.fm-pricestable>div>p {
|
42 |
+
text-transform: uppercase;
|
43 |
+
background-color: #192D3B;
|
44 |
+
text-align: center;
|
45 |
+
font-weight: bold;
|
46 |
+
font-size: 20px;
|
47 |
+
padding: 6px 0;
|
48 |
+
height: 46px;
|
49 |
+
color: #fff
|
50 |
+
}
|
51 |
+
|
52 |
+
.fm-pricestable>div>p::first-line {
|
53 |
+
font-size: 15px;
|
54 |
+
font-weight: normal
|
55 |
+
}
|
56 |
+
|
57 |
+
.fm-pricestable>div>span {
|
58 |
+
border: 1px solid #B7B7B7;
|
59 |
+
text-transform: uppercase;
|
60 |
+
text-align: center;
|
61 |
+
border-top: none;
|
62 |
+
font-size: 15px;
|
63 |
+
display: block;
|
64 |
+
color: #808081;
|
65 |
+
height: 20px;
|
66 |
+
padding: 6px
|
67 |
+
}
|
68 |
+
|
69 |
+
.fm-pricestable>div:first-child>span {
|
70 |
+
text-transform: none;
|
71 |
+
text-align: left
|
72 |
+
}
|
73 |
+
|
74 |
+
.fm-pricestable>div:first-child p {
|
75 |
+
font-size: 17px
|
76 |
+
}
|
77 |
+
|
78 |
+
.fm-pricestable>div.plantype span:last-child,
|
79 |
+
.fm-pricestable>div.ptFree span:last-child,
|
80 |
+
.fm-pricestable>div.ptPersonal span:last-child,
|
81 |
+
.fm-pricestable>div.ptBusiness span:last-child,
|
82 |
+
.fm-pricestable>div.ptDeveloper span:last-child {
|
83 |
+
border: none;
|
84 |
+
padding: 0;
|
85 |
+
height: auto;
|
86 |
+
text-transform: none
|
87 |
+
}
|
88 |
+
|
89 |
+
.fm-pricestable>div.plantype span:last-child>a,
|
90 |
+
.fm-pricestable>div.ptFree span:last-child>a,
|
91 |
+
.fm-pricestable>div.ptPersonal span:last-child>a,
|
92 |
+
.fm-pricestable>div.ptBusiness span:last-child>a,
|
93 |
+
.fm-pricestable>div.ptDeveloper span:last-child>a {
|
94 |
+
color: #FFF;
|
95 |
+
display: table;
|
96 |
+
padding: 4px 3%;
|
97 |
+
margin: 8px auto 5px auto;
|
98 |
+
font-size: 17px;
|
99 |
+
position: relative;
|
100 |
+
text-align: center;
|
101 |
+
line-height: normal;
|
102 |
+
border-radius: 40px;
|
103 |
+
text-decoration: none;
|
104 |
+
background-color: #F47629;
|
105 |
+
text-transform: uppercase;
|
106 |
+
width: 65%;
|
107 |
+
border-bottom: 3px solid #D2631E
|
108 |
+
}
|
109 |
+
|
110 |
+
.fm-pricestable>div.plantype span:last-child>a:hover,
|
111 |
+
.fm-pricestable>div.ptFree span:last-child>a:hover,
|
112 |
+
.fm-pricestable>div.ptPersonal span:last-child>a:hover,
|
113 |
+
.fm-pricestable>div.ptBusiness span:last-child>a:hover,
|
114 |
+
.fm-pricestable>div.ptDeveloper span:last-child>a:hover {
|
115 |
+
background-color: #F68946;
|
116 |
+
border-bottom: 1px solid #D2631E;
|
117 |
+
margin: 10px auto 3px auto
|
118 |
+
}
|
119 |
+
.fm-pricestable>div:not(:last-child) {
|
120 |
+
margin-right: 7px;
|
121 |
+
width: 225px;
|
122 |
+
box-sizing: border-box;
|
123 |
+
}
|
124 |
+
|
125 |
+
.fm-pricestable>div.ptDeveloper {
|
126 |
+
margin-right: 0px;
|
127 |
+
width: 446px;
|
128 |
+
box-sizing: border-box;
|
129 |
+
max-width: 40%
|
130 |
+
}
|
131 |
+
|
132 |
+
.fm-pricestable>div>p {
|
133 |
+
padding: 6px 0 6px 0
|
134 |
+
}
|
135 |
+
|
136 |
+
.fm-pricestable>div .price+p,
|
137 |
+
.fm-pricestable>div .save_money+p {
|
138 |
+
display: table;
|
139 |
+
width: 100%;
|
140 |
+
height: inherit;
|
141 |
+
background: transparent;
|
142 |
+
font-size: 22px;
|
143 |
+
font-weight: 300;
|
144 |
+
line-height: 1.14;
|
145 |
+
color: #000;
|
146 |
+
text-transform: inherit
|
147 |
+
}
|
148 |
+
.fm-pricestable>div .price+p,
|
149 |
+
.fm-pricestable>div .special_offer {
|
150 |
+
text-transform: uppercase;
|
151 |
+
}
|
152 |
+
.fm-pricestable>div>span.price {
|
153 |
+
font-size: 77px !important;
|
154 |
+
line-height: 90px !important;
|
155 |
+
height: 60px !important;
|
156 |
+
color: #134d68 !important;
|
157 |
+
font-weight: 600 !important;
|
158 |
+
padding: 17px 0 29px 0 !important
|
159 |
+
}
|
160 |
+
|
161 |
+
.fm-pricestable>div.ptDeveloper>span.price {
|
162 |
+
padding: 5px 0 0px 0 !important
|
163 |
+
}
|
164 |
+
|
165 |
+
.fm-pricestable>div .save_money {
|
166 |
+
font-style: normal;
|
167 |
+
font-stretch: normal;
|
168 |
+
text-align: center;
|
169 |
+
margin: 25px 0 20px 0
|
170 |
+
}
|
171 |
+
|
172 |
+
.fm-pricestable>div .save_money span {
|
173 |
+
font-size: 14px;
|
174 |
+
font-weight: 500;
|
175 |
+
border-radius: 100px;
|
176 |
+
color: #fff;
|
177 |
+
background-color: #22a044;
|
178 |
+
padding: 5.5px 20px !important
|
179 |
+
}
|
180 |
+
|
181 |
+
.fm-pricestable>div .price span {
|
182 |
+
font-size: 33px;
|
183 |
+
position: relative;
|
184 |
+
top: -41px !important;
|
185 |
+
left: 0px !important;
|
186 |
+
font-weight: 300
|
187 |
+
}
|
188 |
+
|
189 |
+
.fm-pricestable>div>span {
|
190 |
+
height: inherit;
|
191 |
+
border: none;
|
192 |
+
box-sizing: unset !important;
|
193 |
+
padding: 4px 0 5px 0 !important;
|
194 |
+
text-align: center !important;
|
195 |
+
font-size: 14px !important;
|
196 |
+
line-height: 16px !important;
|
197 |
+
text-transform: none;
|
198 |
+
font-weight: 300;
|
199 |
+
color: #000;
|
200 |
+
}
|
201 |
+
|
202 |
+
.fm-pricestable>div>span:not(.product_info) {
|
203 |
+
cursor: pointer
|
204 |
+
}
|
205 |
+
|
206 |
+
.fm-pricestable>div>span:not(.product_info):hover {
|
207 |
+
font-weight: 400
|
208 |
+
}
|
209 |
+
|
210 |
+
.fm-pricestable>div>span.special_offer {
|
211 |
+
font-size: 26px !important;
|
212 |
+
font-weight: normal;
|
213 |
+
font-style: normal;
|
214 |
+
font-stretch: normal;
|
215 |
+
line-height: 1.15 !important;
|
216 |
+
color: #134d68 !important;
|
217 |
+
padding: 33px 0 0px 0 !important
|
218 |
+
}
|
219 |
+
|
220 |
+
.fm-pricestable>div>span.supp strong {
|
221 |
+
color: #e0702b
|
222 |
+
}
|
223 |
+
|
224 |
+
.fm-pricestable>div.ptDeveloper>span.supp strong {
|
225 |
+
font-size: 20px
|
226 |
+
}
|
227 |
+
|
228 |
+
.fm-pricestable>div.ptDeveloper>span.supp {
|
229 |
+
padding: 7.5px 0 !important;
|
230 |
+
font-size: 16px !important
|
231 |
+
}
|
232 |
+
|
233 |
+
.fm-pricestable>div.ptFree span:last-child>a,
|
234 |
+
.fm-pricestable>div.ptPersonal span:last-child>a,
|
235 |
+
.fm-pricestable>div.ptBusiness span:last-child>a,
|
236 |
+
.fm-pricestable>div.ptDeveloper span:last-child>a {
|
237 |
+
max-width: 183px;
|
238 |
+
height: 13px;
|
239 |
+
border-radius: 80px;
|
240 |
+
background-color: #1a6588;
|
241 |
+
font-weight: 300;
|
242 |
+
cursor: pointer;
|
243 |
+
padding: 12px 0 !important;
|
244 |
+
line-height: 15px;
|
245 |
+
font-size: 15px !important;
|
246 |
+
border: 0;
|
247 |
+
margin: 20px auto 0px auto !important;
|
248 |
+
width: 100%
|
249 |
+
}
|
250 |
+
|
251 |
+
.fm-pricestable>div.ptDeveloper span:last-child>a {
|
252 |
+
margin: 20px auto 0 auto !important;
|
253 |
+
max-width: 273px;
|
254 |
+
width: 100%
|
255 |
+
}
|
256 |
+
|
257 |
+
.fm-pricestable>div.ptFree span:last-child>a:hover,
|
258 |
+
.fm-pricestable>div.ptPersonal span:last-child>a:hover,
|
259 |
+
.fm-pricestable>div.ptBusiness span:last-child>a:hover,
|
260 |
+
.fm-pricestable>div.ptDeveloper span:last-child>a:hover,
|
261 |
+
.joomla_free_downloads #open_links:hover,
|
262 |
+
.joomla_free_downloads #open_links.active {
|
263 |
+
background-color: rgba(19, 77, 104, 0.6);
|
264 |
+
border-bottom: 0px solid;
|
265 |
+
margin: 20px auto 34.2px auto
|
266 |
+
}
|
267 |
+
|
268 |
+
.fm-pricestable>div span.no:before {
|
269 |
+
font-size: 35px;
|
270 |
+
line-height: 21px
|
271 |
+
}
|
272 |
+
|
273 |
+
.fm-pricestable>div>span .desc_span {
|
274 |
+
opacity: 0;
|
275 |
+
transition: opacity 0.5s linear;
|
276 |
+
position: absolute;
|
277 |
+
width: 250px;
|
278 |
+
padding: 10px 10px !important;
|
279 |
+
background: rgba(19, 77, 104, 0.8901960784313725);
|
280 |
+
color: #fff;
|
281 |
+
z-index: 1;
|
282 |
+
left: 88%;
|
283 |
+
top: -50%;
|
284 |
+
line-height: 20px;
|
285 |
+
font-size: 14px;
|
286 |
+
visibility: hidden;
|
287 |
+
border-radius: 5px
|
288 |
+
}
|
289 |
+
|
290 |
+
.fm-pricestable>div>span {
|
291 |
+
position: relative
|
292 |
+
}
|
293 |
+
|
294 |
+
.fm-pricestable>div>span:hover .desc_span {
|
295 |
+
opacity: 1;
|
296 |
+
visibility: visible
|
297 |
+
}
|
298 |
+
|
299 |
+
.fm-pricestable>div.ptDeveloper>span .desc_span {
|
300 |
+
left: -29%
|
301 |
+
}
|
302 |
+
|
303 |
+
.fm-pricestable>div .circles {
|
304 |
+
text-align: center;
|
305 |
+
padding: 11px 0 4px 0
|
306 |
+
}
|
307 |
+
|
308 |
+
.fm-pricestable>div .circles li {
|
309 |
+
display: inline-block;
|
310 |
+
list-style: none
|
311 |
+
}
|
312 |
+
|
313 |
+
.fm-pricestable>div .circles li div {
|
314 |
+
width: 4px;
|
315 |
+
height: 4px;
|
316 |
+
background: rgba(19, 77, 104, 0.52);
|
317 |
+
-moz-border-radius: 50%;
|
318 |
+
-webkit-border-radius: 50%;
|
319 |
+
border-radius: 50%
|
320 |
+
}
|
321 |
+
|
322 |
+
.fm-pricestable>div.ptDeveloper>span.supp_dev {
|
323 |
+
padding: 3px 0 4px 0!important
|
324 |
+
}
|
325 |
+
@media (max-width:1024px) {
|
326 |
+
.fm-pricestable>div>span.price {
|
327 |
+
font-size: 77px !important;
|
328 |
+
line-height: 90px !important;
|
329 |
+
height: 60px !important;
|
330 |
+
color: #134d68 !important;
|
331 |
+
font-weight: 600 !important;
|
332 |
+
padding: 20px 0 31px 0 !important
|
333 |
+
}
|
334 |
+
.fm-pricestable>div.ptDeveloper span:last-child>a {
|
335 |
+
margin: 35px auto 34.2px auto !important
|
336 |
+
}
|
337 |
+
.fm-pricestable>div .ptDeveloper .price {
|
338 |
+
padding: 5px 0 0px 0 !important
|
339 |
+
}
|
340 |
+
}
|
341 |
+
|
342 |
+
@media (max-width:1355px) {
|
343 |
+
.fm-pricestable .ptFree,
|
344 |
+
.fm-pricestable .ptPersonal,
|
345 |
+
.fm-pricestable .ptBusiness {
|
346 |
+
width: 100% !important;
|
347 |
+
max-width: 32.8% !important;
|
348 |
+
}
|
349 |
+
.fm-pricestable .ptBusiness {
|
350 |
+
margin-right:0px !important;
|
351 |
+
}
|
352 |
+
.fm-pricestable>div.ptDeveloper {
|
353 |
+
width: 500px;
|
354 |
+
max-width: 60%;
|
355 |
+
}
|
356 |
+
}
|
357 |
+
|
358 |
+
@media (max-width:1094px) {
|
359 |
+
.fm-pricestable .ptFree,
|
360 |
+
.fm-pricestable .ptPersonal,
|
361 |
+
.fm-pricestable .ptBusiness {
|
362 |
+
width: 100% !important;
|
363 |
+
max-width: 32.5% !important;
|
364 |
+
}
|
365 |
+
.fm-pricestable .ptBusiness {
|
366 |
+
margin-right:0px !important;
|
367 |
+
}
|
368 |
+
.fm-pricestable>div.ptDeveloper {
|
369 |
+
width: 500px;
|
370 |
+
max-width: 60%;
|
371 |
+
}
|
372 |
+
}
|
373 |
+
|
374 |
+
@media (max-width:768px) {
|
375 |
+
.fm-pricestable {
|
376 |
+
text-align: center;
|
377 |
+
margin-top: 20px
|
378 |
+
}
|
379 |
+
.fm-pricestable .ptFree,
|
380 |
+
.fm-pricestable .ptPersonal,
|
381 |
+
.fm-pricestable .ptBusiness,
|
382 |
+
.fm-pricestable .ptDeveloper {
|
383 |
+
max-width: 100% !important;
|
384 |
+
min-width: 321px !important;
|
385 |
+
width: 100% !important;
|
386 |
+
margin-right: 0 !important;
|
387 |
+
font-size: inherit !important;
|
388 |
+
}
|
389 |
+
.fm-pricestable>div.ptBusiness span:last-child>a {
|
390 |
+
max-width: 183px !important
|
391 |
+
}
|
392 |
+
.fm-pricestable>div .ptBusiness,
|
393 |
+
.fm-pricestable>div .ptDeveloper,
|
394 |
+
.fm-pricestable>div .hidePrice {
|
395 |
+
display: inline-block !important
|
396 |
+
}
|
397 |
+
|
398 |
+
.fm-pricestable>div.ptFree span:last-child>a,
|
399 |
+
.fm-pricestable>div.ptPersonal span:last-child>a,
|
400 |
+
.fm-pricestable>div.ptBusiness span:last-child>a,
|
401 |
+
.fm-pricestable>div.ptDeveloper span:last-child>a {
|
402 |
+
/*padding: 4% 11% !important;*/
|
403 |
+
font-size: inherit !important
|
404 |
+
}
|
405 |
+
.fm-pricestable>div.ptDeveloper span:last-child>a {
|
406 |
+
margin: 45px auto 34.2px auto !important;
|
407 |
+
padding: 12px 0 !important
|
408 |
+
}
|
409 |
+
}
|
410 |
+
|
411 |
+
@media (max-width:400px) {
|
412 |
+
.fm-pricestable>div.ptDeveloper>span.supp strong {
|
413 |
+
line-height: 21px
|
414 |
+
}
|
415 |
+
.fm-pricestable>div.ptDeveloper>span.supp {
|
416 |
+
font-size: 15px !important
|
417 |
+
}
|
418 |
+
}
|
419 |
+
.fm-prices-more {
|
420 |
+
display: flex;
|
421 |
+
flex-wrap: wrap;
|
422 |
+
justify-content: center;
|
423 |
+
}
|
424 |
+
.fm-prices-more div {
|
425 |
+
width: 100%;
|
426 |
+
background: #fff;
|
427 |
+
padding: 15px;
|
428 |
+
text-align:center;
|
429 |
+
border: 0.5px solid rgba(208, 208, 208, 0.4);
|
430 |
+
border-radius: 7px;
|
431 |
+
}
|
432 |
+
.fm-prices-more a {
|
433 |
+
text-decoration:none;
|
434 |
+
}
|
435 |
+
|
436 |
+
/* Top bar start */
|
437 |
+
.fm-topbar-container {
|
438 |
+
display: flex;
|
439 |
+
flex-direction: row;
|
440 |
+
justify-content: flex-end;
|
441 |
+
margin: 20px 0 20px 0;
|
442 |
+
font-family: Roboto;
|
443 |
+
}
|
444 |
+
.fm-topbar-container * {
|
445 |
+
box-sizing: border-box;
|
446 |
+
}
|
447 |
+
.fm-topbar {
|
448 |
+
background-color: #FFFFFF;
|
449 |
+
border: 1px solid #D0D0D080;
|
450 |
+
border-radius: 7px;
|
451 |
+
color: #000000;
|
452 |
+
padding: 5px;
|
453 |
+
}
|
454 |
+
.fm-topbar-content {
|
455 |
+
display: flex;
|
456 |
+
justify-content: space-between;
|
457 |
+
flex: auto;
|
458 |
+
margin: 0 2px 0 0;
|
459 |
+
padding: 10px 15px;
|
460 |
+
height: 60px;
|
461 |
+
}
|
462 |
+
.fm-topbar-links {
|
463 |
+
color: #000000;
|
464 |
+
display: flex;
|
465 |
+
flex-direction: column;
|
466 |
+
justify-content: space-around;
|
467 |
+
font-size: 18px;
|
468 |
+
font-weight: 300;
|
469 |
+
margin: 0 0 0 2px;
|
470 |
+
height: 60px;
|
471 |
+
}
|
472 |
+
.fm-topbar-links-container {
|
473 |
+
display: flex;
|
474 |
+
justify-content: space-around;
|
475 |
+
height: 80%;
|
476 |
+
}
|
477 |
+
.fm-topbar-links-item {
|
478 |
+
display: flex;
|
479 |
+
flex: 1;
|
480 |
+
align-self: center;
|
481 |
+
justify-content: center;
|
482 |
+
width: 170px;
|
483 |
+
line-height: 50px;
|
484 |
+
}
|
485 |
+
.fm-topbar-links * {
|
486 |
+
font-size: 18px;
|
487 |
+
}
|
488 |
+
.fm-topbar-links a,
|
489 |
+
.fm-topbar-links a:focus {
|
490 |
+
align-self: center;
|
491 |
+
box-shadow: none;
|
492 |
+
color: #000000;
|
493 |
+
text-decoration: none;
|
494 |
+
}
|
495 |
+
.fm-topbar-links a:hover {
|
496 |
+
opacity: 0.5;
|
497 |
+
text-decoration: none;
|
498 |
+
}
|
499 |
+
.fm-topbar-separator {
|
500 |
+
background-color: #C2C2C280;
|
501 |
+
width: 1px;
|
502 |
+
height: 100%;
|
503 |
+
}
|
504 |
+
.fm-topbar-content-title {
|
505 |
+
color: #0C4D68;
|
506 |
+
font-size: 16px;
|
507 |
+
font-weight: 700;
|
508 |
+
line-height: 22px;
|
509 |
+
text-transform: uppercase;
|
510 |
+
}
|
511 |
+
.fm-topbar-content-body {
|
512 |
+
font-size: 15px;
|
513 |
+
font-weight: 300;
|
514 |
+
line-height: 20px;
|
515 |
+
}
|
516 |
+
.fm-topbar-content-container {
|
517 |
+
display: flex;
|
518 |
+
flex-direction: column;
|
519 |
+
}
|
520 |
+
.fm-topbar-content-button-container,
|
521 |
+
.fm-free-message-button-container {
|
522 |
+
align-self: center;
|
523 |
+
}
|
524 |
+
.fm-topbar-upgrade-button,
|
525 |
+
.fm-topbar-upgrade-button:focus {
|
526 |
+
background-color: #29B311;
|
527 |
+
border-radius: 20px;
|
528 |
+
box-shadow: none;
|
529 |
+
color: #FFFFFF;
|
530 |
+
font-size: 14px;
|
531 |
+
padding: 5px 44px;
|
532 |
+
text-decoration: none;
|
533 |
+
text-transform: uppercase;
|
534 |
+
}
|
535 |
+
.fm-topbar-upgrade-button:hover {
|
536 |
+
text-decoration: none;
|
537 |
+
color: #FFFFFFCC;
|
538 |
+
}
|
539 |
+
@media screen and (max-width: 1366px) {
|
540 |
+
.fm-topbar-links {
|
541 |
+
font-size: 15px;
|
542 |
+
}
|
543 |
+
.fm-topbar-content-title {
|
544 |
+
font-size: 15px;
|
545 |
+
}
|
546 |
+
.fm-topbar-content-body {
|
547 |
+
font-size: 13px;
|
548 |
+
}
|
549 |
+
}
|
550 |
+
@media screen and (max-width: 1285px) {
|
551 |
+
.fm-topbar-container {
|
552 |
+
flex-direction: column;
|
553 |
+
}
|
554 |
+
.fm-topbar-links,
|
555 |
+
.fm-topbar-content {
|
556 |
+
margin: 0 0 10px 0;
|
557 |
+
width: 100%;
|
558 |
+
}
|
559 |
+
.fm-topbar-content {
|
560 |
+
flex-direction: column;
|
561 |
+
height: auto;
|
562 |
+
}
|
563 |
+
.fm-topbar-content-container,
|
564 |
+
.fm-topbar-content-container * {
|
565 |
+
align-self: center;
|
566 |
+
padding-bottom: 4px;
|
567 |
+
}
|
568 |
+
}
|
569 |
+
/* Top bar end */
|
570 |
+
|
571 |
+
/* Free message start */
|
572 |
+
.fm-free-option {
|
573 |
+
opacity: 0.7;
|
574 |
+
}
|
575 |
+
.fm-free-message {
|
576 |
+
background-color: #FFFFFF;
|
577 |
+
border: 1px solid #D0D0D080;
|
578 |
+
display: flex;
|
579 |
+
color: #000000;
|
580 |
+
font-family: Roboto;
|
581 |
+
justify-content: space-between;
|
582 |
+
padding: 8px 20px;
|
583 |
+
}
|
584 |
+
.fm-free-message-body {
|
585 |
+
color: #444444;
|
586 |
+
font-size: 14px;
|
587 |
+
font-weight: 500;
|
588 |
+
line-height: 30px;
|
589 |
+
}
|
590 |
+
.fm-free-message-upgrade-button,
|
591 |
+
.fm-free-message-upgrade-button:focus {
|
592 |
+
background-color: #29B311;
|
593 |
+
border-radius: 20px;
|
594 |
+
box-shadow: none;
|
595 |
+
color: #FFFFFF;
|
596 |
+
font-size: 12px;
|
597 |
+
padding: 3px 25px;
|
598 |
+
text-decoration: none;
|
599 |
+
text-transform: uppercase;
|
600 |
+
}
|
601 |
+
.fm-free-message-upgrade-button:hover {
|
602 |
+
text-decoration: none;
|
603 |
+
color: #FFFFFFCC;
|
604 |
+
}
|
605 |
+
.fm-free-message-promo-button,
|
606 |
+
.fm-free-message-promo-button:focus {
|
607 |
+
background-color: #0C4D68;
|
608 |
+
padding: 3px 40px;
|
609 |
+
}
|
610 |
+
.fm-promo-message {
|
611 |
+
align-items: center;
|
612 |
+
display: flex;
|
613 |
+
flex-direction: column;
|
614 |
+
padding: 8px 20px;
|
615 |
+
}
|
616 |
+
.fm-free-message-huge {
|
617 |
+
font-size: 30px;
|
618 |
+
line-height: 39px;
|
619 |
+
margin: 10px 0 0 0;
|
620 |
+
}
|
621 |
+
/* Free message end */
|
622 |
+
|
623 |
+
/* Head start */
|
624 |
+
.fm-head {
|
625 |
+
margin-top: 15px;
|
626 |
+
text-align: center;
|
627 |
+
}
|
628 |
+
.fm-head .fm-breadcrumbs { }
|
629 |
+
.fm-head .fm-breadcrumbs li {
|
630 |
+
display: inline-block;
|
631 |
+
margin: 0 10px 0 0;
|
632 |
+
padding-top: 10px;
|
633 |
+
vertical-align: baseline;
|
634 |
+
}
|
635 |
+
.fm-head .fm-breadcrumbs li:last-child {
|
636 |
+
margin-right:0px;
|
637 |
+
}
|
638 |
+
.fm-head .fm-breadcrumbs .fm-breadcrumb-item .fm-breadcrumb-item-link {
|
639 |
+
text-decoration:none;
|
640 |
+
font-family: Roboto;
|
641 |
+
font-weight:500;
|
642 |
+
font-size:18px;
|
643 |
+
color:#32373c;
|
644 |
+
}
|
645 |
+
.fm-head .fm-breadcrumbs .fm-breadcrumb-item .fm-breadcrumb-item-link-active {
|
646 |
+
color: #0073aa;
|
647 |
+
}
|
648 |
+
|
649 |
+
.fm-head .fm-breadcrumbs .fm-breadcrumb-item .fm-upgrade {
|
650 |
+
position:relative;
|
651 |
+
top: 0.5px;
|
652 |
+
display: inline-block;
|
653 |
+
margin-left: 10px;
|
654 |
+
padding: 1px 22px;
|
655 |
+
background-color: #29B311;
|
656 |
+
text-transform: uppercase;
|
657 |
+
border-radius: 10px;
|
658 |
+
font-weight: 700;
|
659 |
+
font-size: 12px;
|
660 |
+
color: #fff;
|
661 |
+
}
|
662 |
+
/* Head end */
|
663 |
+
|
664 |
+
/* Limitations alert start */
|
665 |
+
.fm-limitation-alert-container {
|
666 |
+
display: flex;
|
667 |
+
align-items: center;
|
668 |
+
position: fixed;
|
669 |
+
top: 0;
|
670 |
+
bottom: 0;
|
671 |
+
left: 0;
|
672 |
+
right: 0;
|
673 |
+
width: 100%;
|
674 |
+
height: 100%;
|
675 |
+
z-index: 100050;
|
676 |
+
}
|
677 |
+
.fm-limitation-alert-overlay {
|
678 |
+
background-color: #ffffffcc;
|
679 |
+
position: absolute;
|
680 |
+
top: 0;
|
681 |
+
bottom: 0;
|
682 |
+
left: 0;
|
683 |
+
right: 0;
|
684 |
+
width: 100%;
|
685 |
+
height: 100%;
|
686 |
+
}
|
687 |
+
.fm-limitation-alert {
|
688 |
+
background-color: #FFFFFF;
|
689 |
+
box-shadow: #0000001a 0 0 10px;
|
690 |
+
display: flex;
|
691 |
+
flex-direction: column;
|
692 |
+
color: #000000;
|
693 |
+
font-family: Roboto;
|
694 |
+
justify-content: space-between;
|
695 |
+
margin: 0 auto;
|
696 |
+
padding: 30px 20px;
|
697 |
+
position: relative;
|
698 |
+
max-width: 430px;
|
699 |
+
max-height: 311px;
|
700 |
+
width: 100%;
|
701 |
+
height: 100%;
|
702 |
+
text-align: center;
|
703 |
+
}
|
704 |
+
.fm-limitation-alert span.dashicons-no-alt {
|
705 |
+
cursor: pointer;
|
706 |
+
position: absolute;
|
707 |
+
top: 10px;
|
708 |
+
right: 10px;
|
709 |
+
color: #000000;
|
710 |
+
font-size: 20px;
|
711 |
+
opacity: 0.3;
|
712 |
+
}
|
713 |
+
.fm-hidden {
|
714 |
+
display: none;
|
715 |
+
}
|
716 |
+
.fm-limitation-alert-header {
|
717 |
+
color: #32373C;
|
718 |
+
font-size: 16px;
|
719 |
+
font-weight: 500;
|
720 |
+
line-height: 21px;
|
721 |
+
}
|
722 |
+
.fm-limitation-alert-body {
|
723 |
+
margin-top: 20px;
|
724 |
+
}
|
725 |
+
.fm-limitation-alert-body ul {
|
726 |
+
display: inline-block;
|
727 |
+
list-style: disc;
|
728 |
+
text-align: left;
|
729 |
+
}
|
730 |
+
.fm-limitation-alert-body ul li {
|
731 |
+
font-size: 16px;
|
732 |
+
font-weight: 700;
|
733 |
+
line-height: 26px;
|
734 |
+
}
|
735 |
+
/* Limitations alert end */
|
736 |
+
/* Add-ons start */
|
737 |
+
.fm-add-ons {
|
738 |
+
display: flex;
|
739 |
+
flex-wrap: wrap;
|
740 |
+
justify-content: center;
|
741 |
+
margin-top: 20px;
|
742 |
+
margin-bottom: 10px;
|
743 |
+
font-family: Roboto;
|
744 |
+
}
|
745 |
+
.fm-add-ons .fm-add-on {
|
746 |
+
max-width:300px;
|
747 |
+
max-height: 300px;
|
748 |
+
width:100%;
|
749 |
+
height:100%;
|
750 |
+
margin-right:10px;
|
751 |
+
margin-bottom:10px;
|
752 |
+
padding: 20px 20px 15px;
|
753 |
+
transition-delay: 0s;
|
754 |
+
transition-duration: 0s;
|
755 |
+
transition-property: all;
|
756 |
+
transition-timing-function: ease;
|
757 |
+
background-color: #fff;
|
758 |
+
border-radius:1px;
|
759 |
+
text-align: center;
|
760 |
+
font-family:Roboto;
|
761 |
+
font-weight: 300;
|
762 |
+
font-size:16px;
|
763 |
+
color: rgb(50, 58, 69);
|
764 |
+
}
|
765 |
+
.fm-add-ons .fm-add-on:hover {
|
766 |
+
box-shadow: 1px 1px 6px rgba(52, 52, 52, 0.16);
|
767 |
+
}
|
768 |
+
.fm-add-ons .fm-add-on .fm-add-on-img {
|
769 |
+
width:72px;
|
770 |
+
height:72px;
|
771 |
+
margin:0 auto;
|
772 |
+
}
|
773 |
+
.fm-add-ons .fm-add-on a {
|
774 |
+
text-decoration:none;
|
775 |
+
}
|
776 |
+
.fm-add-ons .fm-add-on .fm-add-on-name {
|
777 |
+
margin:15px 0px;
|
778 |
+
}
|
779 |
+
.fm-add-ons .fm-add-on .fm-add-on-name,
|
780 |
+
.fm-add-ons .fm-add-on .fm-add-on-name a {
|
781 |
+
font-family:Roboto;
|
782 |
+
font-weight: 400;
|
783 |
+
font-size:20px;
|
784 |
+
color: #0C4D68;
|
785 |
+
}
|
786 |
+
.fm-add-ons .fm-add-on .fm-add-on-premium-version {
|
787 |
+
margin: 4px 0;
|
788 |
+
height: 16px;
|
789 |
+
line-height:16px;
|
790 |
+
font-weight:400;
|
791 |
+
font-size:14px;
|
792 |
+
color:rgb(41, 179, 17);
|
793 |
+
}
|
794 |
+
.fm-add-ons .fm-add-on .fm-add-on-desc {
|
795 |
+
max-height: 65px;
|
796 |
+
height:100%;
|
797 |
+
line-height:20px;
|
798 |
+
font-size:16px;
|
799 |
+
}
|
800 |
+
|
801 |
+
.fm-add-ons .fm-add-on .fm-add-on-desc-more-wrap {
|
802 |
+
position: relative;
|
803 |
+
}
|
804 |
+
.fm-add-ons .fm-add-on .fm-add-on-desc-more {
|
805 |
+
position: absolute;
|
806 |
+
z-index: 1;
|
807 |
+
left: 0;
|
808 |
+
bottom: 65px;
|
809 |
+
opacity: 0;
|
810 |
+
visibility: hidden;
|
811 |
+
transition: opacity 0.4s linear;
|
812 |
+
padding: 10px 10px;
|
813 |
+
background-color: rgb(50, 55, 60);
|
814 |
+
border-radius: 6px;
|
815 |
+
line-height: 20px;
|
816 |
+
font-weight:400;
|
817 |
+
font-size: 14px;
|
818 |
+
color: #fff;
|
819 |
+
}
|
820 |
+
.fm-add-ons .fm-add-on .fm-add-on-desc:hover + .fm-add-on-desc-more {
|
821 |
+
opacity: 1;
|
822 |
+
visibility: visible;
|
823 |
+
}
|
824 |
+
.fm-add-ons .fm-add-on .fm-add-on-buy {
|
825 |
+
width: 155px;
|
826 |
+
height: 30px;
|
827 |
+
display:block;
|
828 |
+
margin: 10px auto;
|
829 |
+
padding-top: 7px;
|
830 |
+
background-color: rgb(12, 77, 104);
|
831 |
+
border: 0.7px solid rgb(12, 77, 104);
|
832 |
+
border-radius: 15px;
|
833 |
+
line-height:16px;
|
834 |
+
font-family: Roboto;
|
835 |
+
font-weight: 400;
|
836 |
+
font-size: 13px;
|
837 |
+
color: #fff;
|
838 |
+
}
|
839 |
+
|
840 |
+
.fm-add-ons .fm-add-on .fm-add-on-buy:hover {
|
841 |
+
background-color: rgba(12, 77, 104, 0.8);
|
842 |
+
}
|
843 |
+
|
844 |
+
.fm-add-ons .fm-add-on.fm-add-on-activated .fm-add-on-buy {
|
845 |
+
text-transform:uppercase;
|
846 |
+
background-color: #fff;
|
847 |
+
font-size:13px;
|
848 |
+
color:rgb(12, 77, 104);
|
849 |
+
}
|
850 |
+
.fm-add-ons .fm-add-on .fm-add-on-learn-more {
|
851 |
+
line-height:16px;
|
852 |
+
font-family: Roboto;
|
853 |
+
font-weight: 300;
|
854 |
+
font-size: 14px;
|
855 |
+
color: rgb(0,115,170);
|
856 |
+
}
|
857 |
+
.fm-add-ons .fm-add-on .fm-add-on-learn-more:hover {
|
858 |
+
color: rgba(0, 115, 170, 0.8);
|
859 |
+
}
|
860 |
+
/* Add-ons end */
|
css/style.css
CHANGED
@@ -1037,7 +1037,7 @@ li.pp_selected > span {
|
|
1037 |
#show_table .mini_label_area_code:empty {
|
1038 |
margin-right: 15px;
|
1039 |
}
|
1040 |
-
.mini_label_to:empty{
|
1041 |
margin-left: 3px;
|
1042 |
margin-right: 0px;
|
1043 |
}
|
@@ -1053,7 +1053,7 @@ li.pp_selected > span {
|
|
1053 |
}
|
1054 |
}
|
1055 |
|
1056 |
-
|
1057 |
height: 52px;
|
1058 |
}
|
1059 |
.show_hide,
|
1037 |
#show_table .mini_label_area_code:empty {
|
1038 |
margin-right: 15px;
|
1039 |
}
|
1040 |
+
#show_table .mini_label_to:empty{
|
1041 |
margin-left: 3px;
|
1042 |
margin-right: 0px;
|
1043 |
}
|
1053 |
}
|
1054 |
}
|
1055 |
|
1056 |
+
.wdform_address span {
|
1057 |
height: 52px;
|
1058 |
}
|
1059 |
.show_hide,
|
css/tw-gb/block.css
ADDED
@@ -0,0 +1,50 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
/**
|
2 |
+
* 10Web plugins Gutenberg integration
|
3 |
+
* version 2.0.0
|
4 |
+
*/
|
5 |
+
.tw-container {
|
6 |
+
position: fixed;
|
7 |
+
top: 0;
|
8 |
+
left: 0;
|
9 |
+
right: 0;
|
10 |
+
bottom: 0;
|
11 |
+
z-index: 9999999;
|
12 |
+
background: rgba(0,0,0,0.7);
|
13 |
+
}
|
14 |
+
|
15 |
+
.tw-container .tw-container-wrap {
|
16 |
+
background: #fff;
|
17 |
+
height: 100%;
|
18 |
+
width: 100%;
|
19 |
+
position: absolute;
|
20 |
+
top: 0;
|
21 |
+
bottom: 0;
|
22 |
+
margin: auto;
|
23 |
+
right: 0;
|
24 |
+
left: 0;
|
25 |
+
}
|
26 |
+
|
27 |
+
.tw-container .tw-container-wrap-520-400 {
|
28 |
+
max-width: 520px;
|
29 |
+
max-height: 400px;
|
30 |
+
}
|
31 |
+
|
32 |
+
.tw-container .tw-container-wrap-420-450 {
|
33 |
+
max-width: 420px;
|
34 |
+
max-height: 450px;
|
35 |
+
}
|
36 |
+
|
37 |
+
.tw-container .tw-container-wrap .media-modal-close{
|
38 |
+
line-height: 34px;
|
39 |
+
text-align: center;
|
40 |
+
height: 40px;
|
41 |
+
}
|
42 |
+
|
43 |
+
.tw-container .tw-container-wrap iframe {
|
44 |
+
height: 100%;
|
45 |
+
width: 100%;
|
46 |
+
}
|
47 |
+
.tw-gb-select {
|
48 |
+
width: 100%;
|
49 |
+
height: auto !important;
|
50 |
+
}
|
featured/admin.css
DELETED
@@ -1,741 +0,0 @@
|
|
1 |
-
/**
|
2 |
-
* Admin CSS file
|
3 |
-
*/
|
4 |
-
#fm-tabs > div{
|
5 |
-
display:none;
|
6 |
-
}
|
7 |
-
#fm-settings{
|
8 |
-
background: #ffffff;
|
9 |
-
padding: 15px;
|
10 |
-
}
|
11 |
-
.fm-meta-control {
|
12 |
-
margin-bottom: 15px;
|
13 |
-
}
|
14 |
-
|
15 |
-
.fm-meta-control label {
|
16 |
-
display: block;
|
17 |
-
font-weight: bold;
|
18 |
-
}
|
19 |
-
|
20 |
-
#fm-admin-promo {
|
21 |
-
background-color: #fcf8e3;
|
22 |
-
border: 1px solid #faebbe;
|
23 |
-
color: #8a6d3b;
|
24 |
-
padding: 15px;
|
25 |
-
}
|
26 |
-
|
27 |
-
#fm_event_meta .inside code {
|
28 |
-
word-break: break-all;
|
29 |
-
}
|
30 |
-
|
31 |
-
.border{
|
32 |
-
border: 1px solid red;
|
33 |
-
}
|
34 |
-
|
35 |
-
/*Spider events*/
|
36 |
-
.fm_repeat_type_list{
|
37 |
-
float: left;
|
38 |
-
width: 30%;
|
39 |
-
}
|
40 |
-
.fm_repeat_advanced{
|
41 |
-
float: left;
|
42 |
-
width: 68%;
|
43 |
-
}
|
44 |
-
#fm_choose_day_container div label{
|
45 |
-
width: 120px;
|
46 |
-
display: inline-block;
|
47 |
-
}
|
48 |
-
#fm_choose_day_container div label:after{
|
49 |
-
clear: both;
|
50 |
-
}
|
51 |
-
#fm_choose_day_container div label input{
|
52 |
-
float: right;
|
53 |
-
margin: 1px;
|
54 |
-
}
|
55 |
-
.fm_icon{
|
56 |
-
max-width: 64px;
|
57 |
-
max-height: 64px;
|
58 |
-
}
|
59 |
-
|
60 |
-
.fm-modal .fm-calendar-event,
|
61 |
-
.fm-events .fm-calendar-event{
|
62 |
-
width:47%;
|
63 |
-
display: inline-block;
|
64 |
-
margin:0 20px 10px 0;
|
65 |
-
}
|
66 |
-
|
67 |
-
.fm-events .fm-calendar-event{
|
68 |
-
width:42%;
|
69 |
-
}
|
70 |
-
.fm-modal .fm-calendar-event span:first-child,
|
71 |
-
.fm-events .fm-calendar-event span:first-child{
|
72 |
-
border: 1px solid #C8C8C8;
|
73 |
-
display: inline-block;
|
74 |
-
width: 89%;
|
75 |
-
box-sizing: border-box;
|
76 |
-
padding: 2px 2px 2px 7px;
|
77 |
-
color: #7C7C7C;
|
78 |
-
white-space: nowrap;
|
79 |
-
text-overflow: ellipsis;
|
80 |
-
overflow: hidden;
|
81 |
-
float: left;
|
82 |
-
}
|
83 |
-
|
84 |
-
.fm-events .fm-calendar-event span:first-child{
|
85 |
-
width: 81%;
|
86 |
-
}
|
87 |
-
.fm-modal .fm-calendar-event:nth-child(even){
|
88 |
-
margin-right:0;
|
89 |
-
}
|
90 |
-
|
91 |
-
.fm-events .fm-calendar-event:after{
|
92 |
-
clear: both;
|
93 |
-
}
|
94 |
-
|
95 |
-
.fm-modal .fm-calendar-event .fm-calendar-event-add,
|
96 |
-
.fm-events .fm-calendar-event-delete{
|
97 |
-
display: inline-block;
|
98 |
-
text-align: center;
|
99 |
-
float: left;
|
100 |
-
vertical-align: middle;
|
101 |
-
border-radius: 2px;
|
102 |
-
height: 24px;
|
103 |
-
width: 24px;
|
104 |
-
color: #FFFFff;
|
105 |
-
background-color: #0074A2;
|
106 |
-
cursor: pointer;
|
107 |
-
font-size: 19px;
|
108 |
-
}
|
109 |
-
|
110 |
-
|
111 |
-
.fm-events .fm-calendar-event-edit{
|
112 |
-
|
113 |
-
}
|
114 |
-
.fm-events .fm-calendar-event-edit a{
|
115 |
-
font-size: 0;
|
116 |
-
display: inline-block;
|
117 |
-
float: left;
|
118 |
-
margin: 0 1px;
|
119 |
-
border-radius: 2px;
|
120 |
-
height: 24px;
|
121 |
-
width: 24px;
|
122 |
-
background: url("../images/edit_icon.png") no-repeat center center;
|
123 |
-
}
|
124 |
-
.fm-events .fm-calendar-event-delete{
|
125 |
-
line-height: 20px;
|
126 |
-
}
|
127 |
-
|
128 |
-
.fm-calendar-event-add {
|
129 |
-
cursor: pointer;
|
130 |
-
}
|
131 |
-
|
132 |
-
.fm-modal {
|
133 |
-
position: fixed;
|
134 |
-
font-family: Arial, Helvetica, sans-serif;
|
135 |
-
overflow-y: scroll;
|
136 |
-
top: 0;
|
137 |
-
right: 0;
|
138 |
-
bottom: 0;
|
139 |
-
left: 0;
|
140 |
-
background: rgba(0, 0, 0, 0.8);
|
141 |
-
z-index: 99999;
|
142 |
-
opacity:0;
|
143 |
-
-webkit-transition: opacity 400ms ease-in;
|
144 |
-
-moz-transition: opacity 400ms ease-in;
|
145 |
-
transition: opacity 400ms ease-in;
|
146 |
-
pointer-events: none;
|
147 |
-
}
|
148 |
-
.fm-modal:target {
|
149 |
-
opacity:1;
|
150 |
-
pointer-events: auto;
|
151 |
-
}
|
152 |
-
.fm-modal > div.fm-excluded-events {
|
153 |
-
width: 500px !important;
|
154 |
-
position: relative;
|
155 |
-
margin: 10% auto;
|
156 |
-
padding: 0px 20px 16px 20px !important;
|
157 |
-
border-radius: 1px;
|
158 |
-
background: #fff;
|
159 |
-
}
|
160 |
-
.fm-modal > div.fm-preview {
|
161 |
-
position: relative;
|
162 |
-
margin: 5%;
|
163 |
-
padding: 5px 20px 13px 20px;
|
164 |
-
border-radius: 1px;
|
165 |
-
background: #fff;
|
166 |
-
min-width:600px;
|
167 |
-
}
|
168 |
-
|
169 |
-
.fm-close {
|
170 |
-
background: url(../images/close.png);
|
171 |
-
display: inline-block;
|
172 |
-
position: absolute;
|
173 |
-
right: 0px;
|
174 |
-
height: 29px;
|
175 |
-
top: 0px;
|
176 |
-
width: 29px;
|
177 |
-
text-decoration: none;
|
178 |
-
z-index: 4;
|
179 |
-
}
|
180 |
-
|
181 |
-
.fm-excluded-events h2{
|
182 |
-
margin: 15px 0;
|
183 |
-
padding-bottom: 15px !important;
|
184 |
-
border-bottom: 1px solid #B2B2B2;
|
185 |
-
}
|
186 |
-
|
187 |
-
.wd_stay_active {
|
188 |
-
background: none repeat scroll 0% 0% green !important;
|
189 |
-
box-shadow: 0px 1px 3px 0px #178FE5 inset !important;
|
190 |
-
color: #FFF !important;
|
191 |
-
font-weight: 700 !important;
|
192 |
-
}
|
193 |
-
#fm_event_pickup_date, #fm_event_pickup_time {
|
194 |
-
height: 27px;
|
195 |
-
border: 1px solid #A1A1A1;
|
196 |
-
border-radius: 0;
|
197 |
-
font-size: 13px;
|
198 |
-
color: #444444;
|
199 |
-
padding: 0 5px 0 27px;
|
200 |
-
margin-top: 1px;
|
201 |
-
}
|
202 |
-
|
203 |
-
#fm_event_pickup_date {
|
204 |
-
background:url(../images/admin_day.jpg) no-repeat left;
|
205 |
-
margin: 1px 8px;
|
206 |
-
}
|
207 |
-
#fm_event_pickup_time {
|
208 |
-
background:url(../images/admin_time.jpg) no-repeat left;
|
209 |
-
}
|
210 |
-
|
211 |
-
/*TABS*/
|
212 |
-
#fm-tabs, #fm-tabs div{
|
213 |
-
background: none #ffffff;
|
214 |
-
border: 0;
|
215 |
-
}
|
216 |
-
.fm-tabs{
|
217 |
-
list-style-type: none;
|
218 |
-
}
|
219 |
-
.fm-tabs li,
|
220 |
-
#fm-settings-content .nav-tab-wrapper a{
|
221 |
-
display: inline-block;
|
222 |
-
border: 1px solid #A5A5A5;
|
223 |
-
}
|
224 |
-
.fm-tabs li a,
|
225 |
-
#fm-settings-content .nav-tab-wrapper a{
|
226 |
-
display: table-cell;
|
227 |
-
text-align: center;
|
228 |
-
width: 100px;
|
229 |
-
height: 30px;
|
230 |
-
vertical-align: middle;
|
231 |
-
text-decoration:none;
|
232 |
-
color:#5E5E5E;
|
233 |
-
font-size: 16px;
|
234 |
-
}
|
235 |
-
|
236 |
-
#fm-settings-content .nav-tab-wrapper a{
|
237 |
-
background: #ffffff;
|
238 |
-
height: 21px;
|
239 |
-
margin-right: 4px;
|
240 |
-
display: inline-block;
|
241 |
-
font-weight: normal;
|
242 |
-
padding-top: 2px;
|
243 |
-
}
|
244 |
-
|
245 |
-
.fm-tabs li a:focus{
|
246 |
-
box-shadow:none;
|
247 |
-
}
|
248 |
-
.fm-tabs li:hover a,.fm-tabs li.ui-state-active a,
|
249 |
-
#fm-settings-content .nav-tab-wrapper a:hover,#fm-settings-content .nav-tab-wrapper a.nav-tab-active{
|
250 |
-
color:#ffffff;
|
251 |
-
background: #0074A2;
|
252 |
-
}
|
253 |
-
|
254 |
-
#fm-settings-content .nav-tab-wrapper {
|
255 |
-
border-bottom:0;
|
256 |
-
padding-left: 0;
|
257 |
-
}
|
258 |
-
|
259 |
-
.fm-tabs li:hover,.fm-tabs li.ui-state-active,
|
260 |
-
#fm-settings-content .nav-tab-wrapper a.nav-tab-active{
|
261 |
-
border: 1px solid transparent;
|
262 |
-
}
|
263 |
-
|
264 |
-
.fm-tab-inner{
|
265 |
-
padding: 15px;
|
266 |
-
}
|
267 |
-
|
268 |
-
/*Preview */
|
269 |
-
.ui-selecting { background: #FECA40 !important; }
|
270 |
-
.ui-selected { background: #F39814 !important;}
|
271 |
-
|
272 |
-
.event_cal_add {
|
273 |
-
width: 350px;
|
274 |
-
height: 130px;
|
275 |
-
padding: 40px 20px 0;
|
276 |
-
border: 1px solid #cccccc;
|
277 |
-
position: absolute;
|
278 |
-
z-index: 9999;
|
279 |
-
background: #ffffff;
|
280 |
-
}
|
281 |
-
.event_cal_add .close{
|
282 |
-
display: block;
|
283 |
-
line-height: 18px;
|
284 |
-
width: 20px;
|
285 |
-
font-size: 8pt;
|
286 |
-
margin-top: 1px;
|
287 |
-
margin-right: 1px;
|
288 |
-
position: absolute;
|
289 |
-
font-family: tahoma;
|
290 |
-
text-align: center;
|
291 |
-
top: 0;
|
292 |
-
right: 0;
|
293 |
-
cursor: pointer;
|
294 |
-
background-size: contain;
|
295 |
-
height: 20px;
|
296 |
-
}
|
297 |
-
|
298 |
-
.event_cal_add .add_event_to_cal{
|
299 |
-
display: block;
|
300 |
-
cursor: pointer;
|
301 |
-
padding-bottom: 10px;
|
302 |
-
margin: 25px 0 0 0;
|
303 |
-
width: 78px;
|
304 |
-
text-align: center;
|
305 |
-
line-height: 30px;
|
306 |
-
height: 20px;
|
307 |
-
background: #e3e3e3;
|
308 |
-
border: 1px solid #eeeeee;
|
309 |
-
}
|
310 |
-
.event_cal_add .fm_notification{
|
311 |
-
display: block;
|
312 |
-
height: 20px;
|
313 |
-
margin: 25px 0 0 0;
|
314 |
-
}
|
315 |
-
span.fm_error{
|
316 |
-
color: #bc0b0b;
|
317 |
-
display: block;
|
318 |
-
padding-left: 36px;
|
319 |
-
height: 20px;
|
320 |
-
|
321 |
-
}
|
322 |
-
#fm_calendar_meta h3.hndle{
|
323 |
-
color:#0074A2;
|
324 |
-
text-transform:uppercase;
|
325 |
-
font-size: 17px;
|
326 |
-
}
|
327 |
-
#fm-settings a.button{
|
328 |
-
border: 1px solid #A1A1A1;
|
329 |
-
padding: 0px 15px;
|
330 |
-
box-shadow: none;
|
331 |
-
border-radius: 0;
|
332 |
-
color: #000;
|
333 |
-
font-weight: bold;
|
334 |
-
}
|
335 |
-
#fm-settings a.button:hover{
|
336 |
-
border: 1px solid transparent;
|
337 |
-
color: #fff;
|
338 |
-
background: #0074A2;
|
339 |
-
}
|
340 |
-
#fm-settings input[type="text"],
|
341 |
-
#fm-settings select,
|
342 |
-
#fm_theme_meta input[type="text"]:not(#fm_event_location),
|
343 |
-
#fm_calendar_meta input[type="text"]:not(.fm-search),
|
344 |
-
#fm_calendar_meta select,
|
345 |
-
#fm_event_meta input[type="text"]:not(#fm_event_date_from):not(#fm_event_date_to):not(#fm_event_location),
|
346 |
-
#fm_event_meta select,
|
347 |
-
#fm_event_meta #fm_event_year_month,
|
348 |
-
#fm-settings .form-field input, #fm-settings input.regular-text{
|
349 |
-
width:250px;
|
350 |
-
border: 1px solid #A1A1A1;
|
351 |
-
}
|
352 |
-
#fm_event_date_from,#fm_event_date_to{
|
353 |
-
border: 1px solid #A1A1A1;
|
354 |
-
}
|
355 |
-
|
356 |
-
#fm-settings input[type="checkbox"],
|
357 |
-
#fm_event_meta input[type="checkbox"],
|
358 |
-
#fm-settings input[type="radio"]{
|
359 |
-
position: absolute;
|
360 |
-
z-index: -1;
|
361 |
-
margin: 0 !important;
|
362 |
-
width: 5px !important;
|
363 |
-
height: 5px !important;
|
364 |
-
min-width: 5px !important;
|
365 |
-
}
|
366 |
-
|
367 |
-
|
368 |
-
#fm-settings .checkbox-div,
|
369 |
-
#fm_event_meta .checkbox-div{
|
370 |
-
width: 13px;
|
371 |
-
height: 12px;
|
372 |
-
background: #FDFDFD;
|
373 |
-
border: 1px solid #CBCBCB;
|
374 |
-
border-radius: 0px;
|
375 |
-
position: relative;
|
376 |
-
display: inline-block;
|
377 |
-
top: 2px;
|
378 |
-
margin-right: 7px;
|
379 |
-
margin-left: 15px;
|
380 |
-
box-sizing: content-box;
|
381 |
-
-webkit-box-sizing: content-box;
|
382 |
-
-moz-box-sizing: content-box;
|
383 |
-
}
|
384 |
-
#fm-settings .checkbox-div:first-child{
|
385 |
-
margin-left: 0px;
|
386 |
-
}
|
387 |
-
|
388 |
-
#fm-settings .checkbox-div input[type="checkbox"]:checked + label ,
|
389 |
-
#fm_event_meta .checkbox-div input[type="checkbox"]:checked + label ,
|
390 |
-
#fm-settings .checkbox-div input[type="radio"]:checked + label {
|
391 |
-
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)";
|
392 |
-
filter: alpha(opacity=100);
|
393 |
-
opacity: 1;
|
394 |
-
background: #CBCBCB;
|
395 |
-
position: absolute;
|
396 |
-
top: 2px;
|
397 |
-
}
|
398 |
-
|
399 |
-
#fm-settings input[type="submit"] {
|
400 |
-
background: #0074A2;
|
401 |
-
color: #ffffff;
|
402 |
-
font-weight: bold;
|
403 |
-
font-size: 15px;
|
404 |
-
border: 0;
|
405 |
-
border-radius: 0;
|
406 |
-
padding: 5px 25px;
|
407 |
-
height: auto;
|
408 |
-
}
|
409 |
-
|
410 |
-
|
411 |
-
#fm_event_meta .checkbox-div label,
|
412 |
-
#fm-settings .checkbox-div label {
|
413 |
-
cursor: pointer;
|
414 |
-
-ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
|
415 |
-
filter: alpha(opacity=0);
|
416 |
-
opacity: 0;
|
417 |
-
content: "";
|
418 |
-
position: absolute;
|
419 |
-
width: 9px;
|
420 |
-
height: 8px;
|
421 |
-
background: #CBCBCB;
|
422 |
-
border-radius: 0px;
|
423 |
-
top: 2px;
|
424 |
-
left: 2px;
|
425 |
-
}
|
426 |
-
|
427 |
-
#fm_calendar_meta .add_event_plus{
|
428 |
-
display:inline-block;
|
429 |
-
width:18px;
|
430 |
-
height:18px;
|
431 |
-
border-radius:100%;
|
432 |
-
background:#0074A2;
|
433 |
-
color:#ffffff;
|
434 |
-
text-shadow:1px -1px 2px #005C82;
|
435 |
-
margin-left:8px;
|
436 |
-
text-align:center;
|
437 |
-
font-weight: bold;
|
438 |
-
font-size: 15px;
|
439 |
-
line-height: 17px;
|
440 |
-
}
|
441 |
-
#fm_calendar_meta .fm-calendar-event-add a:focus{
|
442 |
-
box-shadow:none;
|
443 |
-
}
|
444 |
-
#fm_event_meta .repeat_format{
|
445 |
-
width: 90px;
|
446 |
-
display: inline-block;
|
447 |
-
}
|
448 |
-
#fm_event_meta .repeat_format_monthly{
|
449 |
-
width: 66px;
|
450 |
-
display: inline-block;
|
451 |
-
}
|
452 |
-
#fm_event_meta #fm_event_year_month{
|
453 |
-
margin: 10px 0 0 95px;
|
454 |
-
}
|
455 |
-
#fm_event_meta #fm_choose_day_container{
|
456 |
-
margin-top: 10px;
|
457 |
-
}
|
458 |
-
#fm_event_meta #fm_choose_day_container .checkbox-div{
|
459 |
-
margin-left: 0px;
|
460 |
-
}
|
461 |
-
#fm_event_meta .fm_repeat_advanced input[type="text"],
|
462 |
-
#fm_event_meta .fm_repeat_advanced select{
|
463 |
-
width: auto;
|
464 |
-
}
|
465 |
-
|
466 |
-
#fm_event_meta #fm_monthly,
|
467 |
-
#fm_event_meta .fm_event_repeat_event_div{
|
468 |
-
margin:10px 0;
|
469 |
-
}
|
470 |
-
|
471 |
-
#fm_event_meta .select_to_enable_disable{
|
472 |
-
width:122px !important;
|
473 |
-
}
|
474 |
-
|
475 |
-
#fm_theme_meta label{
|
476 |
-
display:inline-block;
|
477 |
-
width:290px;
|
478 |
-
font-weight: normal;
|
479 |
-
font-size: 15px;
|
480 |
-
}
|
481 |
-
|
482 |
-
#fm_theme_meta .fm-tab-inner > div{
|
483 |
-
margin:20px 0;
|
484 |
-
}
|
485 |
-
#fm_theme_meta .fm-tab-inner > div:first-child{
|
486 |
-
margin-top:0;
|
487 |
-
}
|
488 |
-
#fm_theme_meta .with_fm_color:after,
|
489 |
-
#fm-settings-content .fm-addons_updates:after,
|
490 |
-
#fm-settings-content .main-plugin:after,
|
491 |
-
#fm-settings-content:after{
|
492 |
-
content:'';
|
493 |
-
display:table;
|
494 |
-
clear:both;
|
495 |
-
}
|
496 |
-
#fm_theme_meta .with_fm_color label{
|
497 |
-
float: left;
|
498 |
-
margin-top: 5px;
|
499 |
-
width: 293px;
|
500 |
-
}
|
501 |
-
#fm_theme_meta .with_fm_color > div{
|
502 |
-
float: left;
|
503 |
-
}
|
504 |
-
.fm-import-settings form{
|
505 |
-
float:left;
|
506 |
-
width:45%;
|
507 |
-
}
|
508 |
-
.fm-import-settings input[type=file]{
|
509 |
-
margin: 10px 0;
|
510 |
-
}
|
511 |
-
.fm-import-settings .fm-calendar-event-import{
|
512 |
-
font-size: 15px;
|
513 |
-
}
|
514 |
-
|
515 |
-
#fm-settings-content #add_on_title{
|
516 |
-
margin-bottom:20px;
|
517 |
-
}
|
518 |
-
|
519 |
-
#fm-settings-content .fm_coming_soon {
|
520 |
-
position: absolute;
|
521 |
-
top: 44px;
|
522 |
-
left: 0;
|
523 |
-
}
|
524 |
-
#fm-settings-content .fm-add-on a{
|
525 |
-
text-decoration: none;
|
526 |
-
}
|
527 |
-
#fm-settings-content .fm-add-on h2{
|
528 |
-
color: #229DBF;
|
529 |
-
font-size: 16px;
|
530 |
-
margin-bottom: 9px;
|
531 |
-
padding: 0 0 7px;
|
532 |
-
line-height: 1.2;
|
533 |
-
}
|
534 |
-
#fm-settings-content .fm-addon-descr{
|
535 |
-
font-size: 13px;
|
536 |
-
line-height: 18px;
|
537 |
-
height: 100%;
|
538 |
-
width: 53%;
|
539 |
-
opacity: 0;
|
540 |
-
position: absolute;
|
541 |
-
top: 0;
|
542 |
-
left: 0;
|
543 |
-
padding: 8px 10px 10px;
|
544 |
-
background: #23282D;
|
545 |
-
color: #D1DDE0;
|
546 |
-
-webkit-backface-visibility: hidden;
|
547 |
-
-moz-backface-visibility: hidden;
|
548 |
-
backface-visibility: hidden;
|
549 |
-
-webkit-transform-origin: 0 0;
|
550 |
-
-moz-transform-origin: 0 0;
|
551 |
-
transform-origin: 0 0;
|
552 |
-
-webkit-transform: rotateY(-90deg);
|
553 |
-
-moz-transform: rotateY(-90deg);
|
554 |
-
transform: rotateY(-90deg);
|
555 |
-
-webkit-transition: -webkit-transform 0.4s, opacity 0.1s 0.3s;
|
556 |
-
-moz-transition: -moz-transform 0.4s, opacity 0.1s 0.3s;
|
557 |
-
transition: transform 0.4s, opacity 0.1s 0.3s;
|
558 |
-
box-sizing: border-box;
|
559 |
-
-webkit-box-sizing: border-box;
|
560 |
-
-moz-box-sizing: border-box;
|
561 |
-
}
|
562 |
-
.grid figcaption {
|
563 |
-
position: absolute;
|
564 |
-
top: 0;
|
565 |
-
left: 0;
|
566 |
-
padding: 20px;
|
567 |
-
background: #2c3f52;
|
568 |
-
color: #ed4e6e;
|
569 |
-
}
|
570 |
-
#fm-settings-content .fm-addon,
|
571 |
-
#fm-settings-content .fm-addon-price{
|
572 |
-
display: inline-block;
|
573 |
-
margin-top: 15px;
|
574 |
-
font-size: 15px;
|
575 |
-
border: 1px solid #DCDCDC;
|
576 |
-
font-weight: bold;
|
577 |
-
}
|
578 |
-
#fm-settings-content .fm-addon{
|
579 |
-
background: #FFFFFF url(../images/Add_Ons.jpg) no-repeat 6px center;
|
580 |
-
color: #66686B;
|
581 |
-
padding: 9px 12px 9px 45px;
|
582 |
-
width: 100%;
|
583 |
-
box-sizing: border-box;
|
584 |
-
-webkit-box-sizing: border-box;
|
585 |
-
-moz-box-sizing: border-box;
|
586 |
-
text-transform: uppercase;
|
587 |
-
}
|
588 |
-
#fm-settings-content .fm-addon-price{
|
589 |
-
background: #FFFFFF;
|
590 |
-
color: #229CBF;
|
591 |
-
padding: 9px 12px;
|
592 |
-
}
|
593 |
-
#fm-settings-content .fm-add-on:hover .fm-addon-price,
|
594 |
-
#fm-settings-content .fm-addon-price:hover{
|
595 |
-
background: #229CBF;
|
596 |
-
color: #DDECF1;
|
597 |
-
}
|
598 |
-
#fm-settings-content .fm-add-on:hover .fm-addon,
|
599 |
-
#fm-settings-content .fm-addon.activated,
|
600 |
-
#fm-settings-content .fm-addon:hover{
|
601 |
-
background: #23282D url(../images/Add_Ons_hover.jpg) no-repeat 6px center;
|
602 |
-
color: #DDDEDE;
|
603 |
-
}
|
604 |
-
#fm-settings-content .fm-addon span{
|
605 |
-
border-left: 1px solid #A7A9AB;
|
606 |
-
padding: 4px 10px 4px 10px;
|
607 |
-
}
|
608 |
-
#fm-settings-content .fm-addon-descr span{
|
609 |
-
padding: 5px 0 5px 10px;
|
610 |
-
border-left: 1px solid #93CEE0;
|
611 |
-
}
|
612 |
-
#fm-settings-content a:focus{
|
613 |
-
outline:none;
|
614 |
-
box-shadow:none;
|
615 |
-
}
|
616 |
-
#fm-settings-content .fm-add-on{
|
617 |
-
width:310px;
|
618 |
-
float:left;
|
619 |
-
margin-right:40px;
|
620 |
-
margin-bottom:57px;
|
621 |
-
-webkit-perspective: 1700px;
|
622 |
-
-moz-perspective: 1700px;
|
623 |
-
perspective: 1700px;
|
624 |
-
-webkit-perspective-origin: 0 50%;
|
625 |
-
-moz-perspective-origin: 0 50%;
|
626 |
-
perspective-origin: 0 50%;
|
627 |
-
position: relative;
|
628 |
-
}
|
629 |
-
#fm-settings-content .main-plugin .fm-add-on{
|
630 |
-
float: left;
|
631 |
-
margin-right: 25px;
|
632 |
-
height: auto;
|
633 |
-
}
|
634 |
-
#fm-settings-content .fm-figure{
|
635 |
-
-webkit-transform-style: preserve-3d;
|
636 |
-
-moz-transform-style: preserve-3d;
|
637 |
-
transform-style: preserve-3d;
|
638 |
-
position: relative;
|
639 |
-
width:100%;
|
640 |
-
height: 232px;
|
641 |
-
margin: 0;
|
642 |
-
}
|
643 |
-
#fm-settings-content .fm-figure-img{
|
644 |
-
overflow: hidden;
|
645 |
-
}
|
646 |
-
#fm-settings-content .fm-figure-img img{
|
647 |
-
-webkit-transition: -webkit-transform 0.4s;
|
648 |
-
-moz-transition: -moz-transform 0.4s;
|
649 |
-
transition: transform 0.4s;
|
650 |
-
}
|
651 |
-
#fm-settings-content .fm-figure:hover img,
|
652 |
-
#fm-settings-content .fm-figure.activated img {
|
653 |
-
-webkit-transform: translateX(25%);
|
654 |
-
-moz-transform: translateX(25%);
|
655 |
-
-ms-transform: translateX(25%);
|
656 |
-
transform: translateX(25%);
|
657 |
-
}
|
658 |
-
#fm-settings-content .fm-figure:hover figcaption,
|
659 |
-
#fm-settings-content .fm-figure.activated figcaption {
|
660 |
-
opacity: 1;
|
661 |
-
-webkit-transform: rotateY(0deg);
|
662 |
-
-moz-transform: rotateY(0deg);
|
663 |
-
transform: rotateY(0deg);
|
664 |
-
-webkit-transition: -webkit-transform 0.4s, opacity 0.1s;
|
665 |
-
-moz-transition: -moz-transform 0.4s, opacity 0.1s;
|
666 |
-
transition: transform 0.4s, opacity 0.1s;
|
667 |
-
}
|
668 |
-
#fm-settings-content .fm-addon-subtitle {
|
669 |
-
font-size: 25px;
|
670 |
-
border-bottom: 1px solid #C1C4C7;
|
671 |
-
padding-bottom: 23px;
|
672 |
-
}
|
673 |
-
#fm-settings-content .main-plugin .main-plugin-img {
|
674 |
-
float: left;
|
675 |
-
margin-right: 2%;
|
676 |
-
width: 26%;
|
677 |
-
}
|
678 |
-
#fm-settings-content .main-plugin .main-plugin-img img{
|
679 |
-
max-width:100%;
|
680 |
-
}
|
681 |
-
#fm-settings-content .main-plugin .main-plugin-info {
|
682 |
-
float: left;
|
683 |
-
}
|
684 |
-
#fm-settings-content .main-plugin {
|
685 |
-
margin-bottom: 25px;
|
686 |
-
}
|
687 |
-
#fm-settings-content .main-plugin_desc-cont p,
|
688 |
-
#fm-settings-content .main-plugin_desc-cont {
|
689 |
-
font-size: 14px;
|
690 |
-
}
|
691 |
-
#fm-settings-content .main-plugin-desc-info p{
|
692 |
-
margin: 2px 0 13px;
|
693 |
-
}
|
694 |
-
#fm-settings-content .fm-addons_updates .main-plugin-desc-info p{
|
695 |
-
margin: 2px 0 4px;
|
696 |
-
}
|
697 |
-
#fm-settings-content .main-plugin-desc {
|
698 |
-
margin-bottom: 12px;
|
699 |
-
}
|
700 |
-
#fm-settings-content .main-plugin-info h2 {
|
701 |
-
padding: 0;
|
702 |
-
line-height: 1;
|
703 |
-
margin-bottom: 14px;
|
704 |
-
}
|
705 |
-
#fm-settings-content .main-plugin-info h2 a {
|
706 |
-
color: #323A45;
|
707 |
-
text-decoration: none;
|
708 |
-
font-weight: bold;
|
709 |
-
}
|
710 |
-
#fm-settings-content .main-plugin-desc-info {
|
711 |
-
border-bottom: 1px solid #C0C4C7;
|
712 |
-
width: 71%;
|
713 |
-
}
|
714 |
-
#fm-settings-content .fm-addons_updates .main-plugin-desc-info {
|
715 |
-
border-bottom: 0;
|
716 |
-
width: 100%;
|
717 |
-
}
|
718 |
-
#fm-settings-content .update-info {
|
719 |
-
background:url(../assets/updates_icon.jpg) no-repeat;
|
720 |
-
padding-left:25px;
|
721 |
-
color: #bc0b0b;
|
722 |
-
}
|
723 |
-
#fm-settings-content .fm-addons_updates .fm-figure {
|
724 |
-
margin-bottom: 10px;
|
725 |
-
}
|
726 |
-
#fm-settings-content .fm-addons_updates .fm-addon-descr-update {
|
727 |
-
border-top: 1px solid #898989;
|
728 |
-
padding-top: 6px;
|
729 |
-
}
|
730 |
-
#fm-settings-content .fm-addons_updates h2{
|
731 |
-
color: #323A45;
|
732 |
-
text-decoration: none;
|
733 |
-
font-weight: bold;
|
734 |
-
border-bottom: 0;
|
735 |
-
padding-bottom: 0;
|
736 |
-
margin-bottom: 0;
|
737 |
-
}
|
738 |
-
|
739 |
-
.fm_more_updates {
|
740 |
-
display: none;
|
741 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
featured/featured.php
DELETED
@@ -1,163 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
function fm_extensions_page($current_plugin = '') {
|
3 |
-
wp_enqueue_style('fm-featured');
|
4 |
-
wp_enqueue_style('fm-featured-admin');
|
5 |
-
$addons = array(
|
6 |
-
'Form Maker Add-ons' => array(
|
7 |
-
'imp_exp' => array(
|
8 |
-
'name' => 'Import/Export',
|
9 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/export-import.html',
|
10 |
-
'description' => 'Form Maker Export/Import WordPress plugin allows exporting and importing forms with/without submissions.',
|
11 |
-
'icon' => '',
|
12 |
-
'image' => plugins_url( '../assets/import_export.png', __FILE__ ),
|
13 |
-
'file_dir' => 'form-maker-export-import/fm_exp_imp.php'
|
14 |
-
),
|
15 |
-
'mailchimp' => array(
|
16 |
-
'name' => 'MailChimp',
|
17 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/mailchimp.html',
|
18 |
-
'description' => 'This add-on is an integration of the Form Maker with MailChimp which allows to add contacts to your subscription lists just from submitted forms.',
|
19 |
-
'icon' => '',
|
20 |
-
'image' => plugins_url( '../assets/mailchimp.png', __FILE__ ),
|
21 |
-
'file_dir' => 'form-maker-mailchimp/fm_mailchimp.php'
|
22 |
-
),
|
23 |
-
'reg' => array(
|
24 |
-
'name' => 'Registration',
|
25 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/registration.html',
|
26 |
-
'description' => 'User Registration add-on integrates with Form maker forms allowing users to create accounts at your website.',
|
27 |
-
'icon' => '',
|
28 |
-
'image' => plugins_url( '../assets/reg.png', __FILE__ ),
|
29 |
-
'file_dir' => 'form-maker-reg/fm_reg.php'
|
30 |
-
),
|
31 |
-
'post_generation' => array(
|
32 |
-
'name' => 'Post Generation',
|
33 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/post-generation.html',
|
34 |
-
'description' => 'Post Generation add-on allows creating a post, page or custom post based on the submitted data.',
|
35 |
-
'icon' => '',
|
36 |
-
'image' => plugins_url( '../assets/post-generation-update.png', __FILE__ ),
|
37 |
-
'file_dir' => 'form-maker-post-generation/fm_post_generation.php'
|
38 |
-
),
|
39 |
-
'conditional_emails' => array(
|
40 |
-
'name' => 'Conditional Emails',
|
41 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/conditional-emails.html',
|
42 |
-
'description' => 'Conditional Emails add-on allows to send emails to different recipients depending on the submitted data .',
|
43 |
-
'icon' => '',
|
44 |
-
'image' => plugins_url( '../assets/conditional-emails-update.png', __FILE__ ),
|
45 |
-
'file_dir' => 'form-maker-conditional-emails/fm_conditional_emails.php'
|
46 |
-
),
|
47 |
-
'dropbox_integration' => array(
|
48 |
-
'name' => 'Dropbox Integration',
|
49 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/dropbox.html',
|
50 |
-
'description' => 'The Form Maker Dropbox Integration addon is extending the Form Maker capabilities allowing to store the form attachments straight to your Dropbox account.',
|
51 |
-
'icon' => '',
|
52 |
-
'image' => plugins_url( '../assets/dropbox-integration-update.png', __FILE__ ),
|
53 |
-
'file_dir' => 'form-maker-dropbox-integration/fm_dropbox_integration.php'
|
54 |
-
),
|
55 |
-
'gdrive_integration' => array(
|
56 |
-
'name' => 'Google Drive Integration',
|
57 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/google-drive.html',
|
58 |
-
'description' => 'The Google Drive Integration add-on integrates Form Maker with Google Drive and allows you to send the file uploads to the Google Drive',
|
59 |
-
'icon' => '',
|
60 |
-
'image' => plugins_url( '../assets/google_drive_integration.png', __FILE__ ),
|
61 |
-
'file_dir' => 'form-maker-gdrive-integration/fm_gdrive_integration.php'
|
62 |
-
),
|
63 |
-
'pdf_integration' => array(
|
64 |
-
'name' => 'PDF Integration',
|
65 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/pdf.html',
|
66 |
-
'description' => 'The Form Maker PDF Integration add-on allows sending submitted forms in PDF format.',
|
67 |
-
'icon' => '',
|
68 |
-
'image' => plugins_url( '../assets/pdf-integration.png', __FILE__ ),
|
69 |
-
'file_dir' => 'form-maker-pdf-integration/fm_pdf_integration.php'
|
70 |
-
),
|
71 |
-
'pushover' => array(
|
72 |
-
'name' => 'Pushover',
|
73 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/pushover.html',
|
74 |
-
'description' => 'Form Maker Pushover integration allows to receive real-time notifications when a user submits a new form. This means messages can be pushed to Android and Apple devices, as well as desktop notification board.',
|
75 |
-
'icon' => '',
|
76 |
-
'image' => plugins_url( '../assets/pushover.png', __FILE__ ),
|
77 |
-
'file_dir' => 'form-maker-pushover/fm_pushover.php'
|
78 |
-
),
|
79 |
-
'form-maker-save-progress' => array(
|
80 |
-
'name' => 'Save Progress',
|
81 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/save-progress.html',
|
82 |
-
'description' => 'The add-on allows to save filled in forms as draft and continue editing them subsequently.',
|
83 |
-
'icon' => '',
|
84 |
-
'image' => plugins_url( '../assets/save-progress.png', __FILE__ ),
|
85 |
-
'file_dir' => 'form-maker-save-progress/fm_save.php'
|
86 |
-
),
|
87 |
-
'stripe' => array(
|
88 |
-
'name' => 'Stripe',
|
89 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/stripe.html',
|
90 |
-
'description' => 'Form Maker Stripe Integration Add-on allows to accept direct payments made by Credit Cards. Users will remain on your website during the entire process.',
|
91 |
-
'icon' => '',
|
92 |
-
'image' => plugins_url( '../assets/stripe-integration-update.png', __FILE__ ),
|
93 |
-
'file_dir' => 'form-maker-stripe/fm_stripe.php'
|
94 |
-
),
|
95 |
-
'calculator' => array(
|
96 |
-
'name' => 'Calculator',
|
97 |
-
'url' => 'https://web-dorado.com/products/wordpress-form/add-ons/calculator.html',
|
98 |
-
'description' => 'The Form Maker Calculator add-on allows creating forms with dynamically calculated fields.',
|
99 |
-
'icon' => '',
|
100 |
-
'image' => plugins_url( '../assets/calculator.png', __FILE__ ),
|
101 |
-
'file_dir' => 'form-maker-calculator/fm_calculator.php'
|
102 |
-
)
|
103 |
-
)
|
104 |
-
);
|
105 |
-
?>
|
106 |
-
<div class="wrap">
|
107 |
-
<?php settings_errors(); ?>
|
108 |
-
<div id="fm-settings">
|
109 |
-
<div id="fm-settings-content" >
|
110 |
-
<h2 id="add_on_title"><?php echo esc_html(get_admin_page_title()); ?></h2>
|
111 |
-
<?php
|
112 |
-
if($addons){
|
113 |
-
foreach ($addons as $name => $cat) {
|
114 |
-
foreach ( $cat as $addon ) {
|
115 |
-
$activated = '';
|
116 |
-
if ( is_plugin_active( $addon['file_dir'] ) ) {
|
117 |
-
$activated = 'activated';
|
118 |
-
}
|
119 |
-
?>
|
120 |
-
<div class="fm-add-on">
|
121 |
-
<h2><?php echo $addon['name'] ?></h2>
|
122 |
-
<figure class="fm-figure <?php echo $activated; ?>">
|
123 |
-
<div class="fm-figure-img">
|
124 |
-
<a href="<?php echo $addon['url'] ?>" target="_blank">
|
125 |
-
<?php if ( $addon['image'] ) { ?>
|
126 |
-
<img src="<?php echo $addon['image'] ?>"/>
|
127 |
-
<?php } ?>
|
128 |
-
</a>
|
129 |
-
</div>
|
130 |
-
<figcaption class="fm-addon-descr fm-figcaption">
|
131 |
-
<?php if ( $addon['icon'] ) { ?>
|
132 |
-
<img src="<?php echo $addon['icon'] ?>"/>
|
133 |
-
<?php } ?>
|
134 |
-
<?php echo $addon['description'] ?>
|
135 |
-
</figcaption>
|
136 |
-
</figure>
|
137 |
-
<?php
|
138 |
-
if ( $addon['url'] !== '#' ) {
|
139 |
-
if ( !empty($activated) ) {
|
140 |
-
?>
|
141 |
-
<span class="fm-addon activated"><span><?php _e('Add on activated', WDCFM()->prefix); ?></span></span>
|
142 |
-
<?php }
|
143 |
-
else { ?>
|
144 |
-
<a href="<?php echo $addon['url'] ?>" target="_blank" class="fm-addon"><span><?php _e('Get this add on', WDCFM()->prefix); ?></span></a>
|
145 |
-
<?php }
|
146 |
-
} else { ?>
|
147 |
-
<div class="fm_coming_soon">
|
148 |
-
<img src="<?php echo plugins_url( '../../assets/coming_soon.png', __FILE__ ); ?>"/>
|
149 |
-
</div>
|
150 |
-
<?php } ?>
|
151 |
-
</div>
|
152 |
-
<?php
|
153 |
-
}
|
154 |
-
}
|
155 |
-
}
|
156 |
-
?>
|
157 |
-
</div>
|
158 |
-
<!-- #fm-settings-content -->
|
159 |
-
</div>
|
160 |
-
<!-- #fm-settings -->
|
161 |
-
</div><!-- .wrap -->
|
162 |
-
<?php
|
163 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
featured/images/Add_Ons.jpg
DELETED
Binary file
|
featured/images/calendar.png
DELETED
Binary file
|
featured/images/calendar1.png
DELETED
Binary file
|
featured/images/calendar_hover.png
DELETED
Binary file
|
featured/images/calendar_menu.png
DELETED
Binary file
|
featured/images/delete_el.png
DELETED
Binary file
|
featured/images/down.png
DELETED
Binary file
|
featured/images/downarrow.png
DELETED
Binary file
|
featured/images/download.jpg
DELETED
Binary file
|
featured/images/download_plugins.png
DELETED
Binary file
|
featured/images/form.png
DELETED
Binary file
|
featured/images/form_import.png
DELETED
Binary file
|
featured/images/index.html
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<!DOCTYPE html>
|
2 |
-
<html>
|
3 |
-
<head>
|
4 |
-
<title>403 Forbidden</title>
|
5 |
-
</head>
|
6 |
-
<body>
|
7 |
-
|
8 |
-
<p>Directory access is forbidden.</p>
|
9 |
-
|
10 |
-
</body>
|
11 |
-
</html>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
featured/images/loadingAnimation.gif
DELETED
Binary file
|
featured/images/tb-close.png
DELETED
Binary file
|
featured/images/up.png
DELETED
Binary file
|
featured/index.html
DELETED
@@ -1,11 +0,0 @@
|
|
1 |
-
<!DOCTYPE html>
|
2 |
-
<html>
|
3 |
-
<head>
|
4 |
-
<title>403 Forbidden</title>
|
5 |
-
</head>
|
6 |
-
<body>
|
7 |
-
|
8 |
-
<p>Directory access is forbidden.</p>
|
9 |
-
|
10 |
-
</body>
|
11 |
-
</html>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
featured/style.css
DELETED
@@ -1,208 +0,0 @@
|
|
1 |
-
@import url(http://fonts.googleapis.com/css?family=Oswald);
|
2 |
-
|
3 |
-
#main_featured_plugins_page {
|
4 |
-
font-family: Oswald;
|
5 |
-
width: 90%;
|
6 |
-
margin: 15px auto 0px auto;
|
7 |
-
}
|
8 |
-
|
9 |
-
#main_featured_plugins_page h3 {
|
10 |
-
border-bottom: 2px solid #CECECE;
|
11 |
-
color: rgb(111, 111, 111);
|
12 |
-
font-family: Segoe UI;
|
13 |
-
font-size: 18pt;
|
14 |
-
margin: 0px auto 15px auto;
|
15 |
-
padding: 20px 0;
|
16 |
-
}
|
17 |
-
|
18 |
-
#main_featured_plugins_page #featured-plugins-list {
|
19 |
-
position:relative;
|
20 |
-
margin:0px auto;
|
21 |
-
height:auto;
|
22 |
-
display:table;
|
23 |
-
list-style:none;
|
24 |
-
text-align: center;
|
25 |
-
width: 100%;
|
26 |
-
}
|
27 |
-
|
28 |
-
#main_featured_plugins_page #featured-plugins-list li {
|
29 |
-
display: inline-table;
|
30 |
-
width: 200px;
|
31 |
-
margin: 20px 10px 0px 10px;
|
32 |
-
background: #FFFFFF;
|
33 |
-
border-right: 3px solid #E5E5E5;
|
34 |
-
height: 335px;
|
35 |
-
border-bottom: 3px solid #E5E5E5;
|
36 |
-
position: relative;
|
37 |
-
}
|
38 |
-
|
39 |
-
#main_featured_plugins_page #featured-plugins-list li .product {
|
40 |
-
position:relative;
|
41 |
-
height:113px;
|
42 |
-
background-color: transparent !important;
|
43 |
-
background-position-x: 50% !important;
|
44 |
-
margin: 7px;
|
45 |
-
border-radius: 3px;
|
46 |
-
background-size: 115px !important;
|
47 |
-
}
|
48 |
-
|
49 |
-
#main_featured_plugins_page #featured-plugins-list li .title {
|
50 |
-
width: 90%;
|
51 |
-
text-align: center;
|
52 |
-
margin: 0 auto;
|
53 |
-
}
|
54 |
-
#main_featured_plugins_page #featured-plugins-list li.ecommerce-wd .product {background:url("images/ecommerce.png") center center no-repeat;}
|
55 |
-
#main_featured_plugins_page #featured-plugins-list li.form-maker .product {background:url("images/form.png") center center no-repeat;}
|
56 |
-
#main_featured_plugins_page #featured-plugins-list li.catalog .product {background:url("images/catalog.png") center center no-repeat;}
|
57 |
-
#main_featured_plugins_page #featured-plugins-list li.contact-maker .product {background:url("images/contact.maker.png") center center no-repeat;}
|
58 |
-
#main_featured_plugins_page #featured-plugins-list li.contacts .product {background:url("images/contacts.png") center center no-repeat;}
|
59 |
-
#main_featured_plugins_page #featured-plugins-list li.facebook .product {background:url("images/facebook.png") center center no-repeat;}
|
60 |
-
#main_featured_plugins_page #featured-plugins-list li.facebook-feed .product {background:url("images/facebook-feed.png") center center no-repeat;}
|
61 |
-
#main_featured_plugins_page #featured-plugins-list li.faq .product {background:url("images/faq.png") center center no-repeat;}
|
62 |
-
#main_featured_plugins_page #featured-plugins-list li.flash-calendar .product {background:url("images/flash.calendar.png") center center no-repeat;}
|
63 |
-
#main_featured_plugins_page #featured-plugins-list li.player .product {background:url("images/player.png") center center no-repeat; }
|
64 |
-
#main_featured_plugins_page #featured-plugins-list li.spider-calendar .product {background:url("images/spider.calendar.png") center center no-repeat;}
|
65 |
-
#main_featured_plugins_page #featured-plugins-list li.contact_form_bulder .product {background:url("images/contact.builder.png") center center no-repeat;}
|
66 |
-
#main_featured_plugins_page #featured-plugins-list li.random_post .product {background:url("images/random.post.png") center center no-repeat;}
|
67 |
-
#main_featured_plugins_page #featured-plugins-list li.slider_wd .product {background:url("images/slider.png") center center no-repeat;}
|
68 |
-
#main_featured_plugins_page #featured-plugins-list li.folder_menu .product {background:url("images/folder.menu.png") center center no-repeat;}
|
69 |
-
#main_featured_plugins_page #featured-plugins-list li.zoom .product {background:url("images/zoom.png") center center no-repeat;}
|
70 |
-
#main_featured_plugins_page #featured-plugins-list li.fm-import .product {background:url("images/fm-import.png") center center no-repeat;}
|
71 |
-
#main_featured_plugins_page #featured-plugins-list li.photo-gallery .product {background:url("images/photo-gallery.png") center center no-repeat;}
|
72 |
-
#main_featured_plugins_page #featured-plugins-list li.twitter-widget .product {background:url("images/twittertools.png") center center no-repeat;}
|
73 |
-
#main_featured_plugins_page #featured-plugins-list li.events-wd .product {background:url("images/events-wd.png") center center no-repeat;}
|
74 |
-
#main_featured_plugins_page #featured-plugins-list li.faq_wd .product {background:url("images/faq_wd.png") center center no-repeat;}
|
75 |
-
#main_featured_plugins_page #featured-plugins-list li.instagram_feed .product {background:url("images/instagram_feed.png") center center no-repeat;}
|
76 |
-
#main_featured_plugins_page #featured-plugins-list li.post-slider .product {background:url("images/post-slider.png") center center no-repeat;}
|
77 |
-
#main_featured_plugins_page #featured-plugins-list li.google-maps .product {background:url("images/google-maps.png") center center no-repeat;}
|
78 |
-
|
79 |
-
#main_featured_plugins_page #featured-plugins-list li .title .heading {
|
80 |
-
display: block;
|
81 |
-
position: relative;
|
82 |
-
font-size: 17px;
|
83 |
-
color: #767676;
|
84 |
-
margin: 13px 0px 13px 0px;
|
85 |
-
text-transform: uppercase;
|
86 |
-
}
|
87 |
-
|
88 |
-
#main_featured_plugins_page #featured-plugins-list li .title p {
|
89 |
-
font-size:14px;
|
90 |
-
color:#444;
|
91 |
-
margin-left:20px;
|
92 |
-
}
|
93 |
-
|
94 |
-
#main_featured_plugins_page #featured-plugins-list li .description {
|
95 |
-
height: 127px;
|
96 |
-
width: 90%;
|
97 |
-
margin: 0 auto;
|
98 |
-
}
|
99 |
-
|
100 |
-
#main_featured_plugins_page #featured-plugins-list li .description p {
|
101 |
-
text-align: center;
|
102 |
-
width: 100%;
|
103 |
-
color: #9A9A9A;
|
104 |
-
font-family: Segoe UI Light;
|
105 |
-
}
|
106 |
-
|
107 |
-
#featured-plugins-list li a.download {
|
108 |
-
display: block;
|
109 |
-
border-top: 1px solid #CACACA;
|
110 |
-
outline: none;
|
111 |
-
width: 90%;
|
112 |
-
margin: 0 auto;
|
113 |
-
font-size: 14px;
|
114 |
-
line-height: 40px;
|
115 |
-
text-decoration: none;
|
116 |
-
font-weight: bolder;
|
117 |
-
text-align: center;
|
118 |
-
color: #134D68;
|
119 |
-
position: absolute;
|
120 |
-
text-transform: uppercase;
|
121 |
-
bottom: 0;
|
122 |
-
left: 10px;
|
123 |
-
font-family: Segoe UI Black;
|
124 |
-
text-shadow: 1px 0;
|
125 |
-
}
|
126 |
-
|
127 |
-
#featured-plugins-list li a.download:hover {
|
128 |
-
color: #F47629;
|
129 |
-
}
|
130 |
-
|
131 |
-
.featured_header{
|
132 |
-
background: #11465F;
|
133 |
-
border-right: 3px solid #E5E5E5;
|
134 |
-
border-bottom: 3px solid #E5E5E5;
|
135 |
-
position: relative;
|
136 |
-
padding: 20px 0;
|
137 |
-
}
|
138 |
-
|
139 |
-
.featured_header .old_price {
|
140 |
-
color: rgba(180, 180, 180, 0.3);
|
141 |
-
text-decoration: line-through;
|
142 |
-
font-family: Oswald;
|
143 |
-
}
|
144 |
-
|
145 |
-
.featured_header h1.get_plugins {
|
146 |
-
color: #FFFFFF;
|
147 |
-
height: 85px;
|
148 |
-
margin: 0;
|
149 |
-
background-size: 85% 100%;
|
150 |
-
background-position: center;
|
151 |
-
line-height: 60px;
|
152 |
-
}
|
153 |
-
|
154 |
-
.featured_header .try-now{
|
155 |
-
text-align: center;
|
156 |
-
}
|
157 |
-
|
158 |
-
.featured_header .try-now span {
|
159 |
-
display: inline-block;
|
160 |
-
padding: 7px 16px;
|
161 |
-
background: #F47629;
|
162 |
-
border-radius: 10px;
|
163 |
-
color: #ffffff;
|
164 |
-
font-size: 23px;
|
165 |
-
}
|
166 |
-
|
167 |
-
.featured_header h1 {
|
168 |
-
font-size: 50px;
|
169 |
-
text-align: center;
|
170 |
-
color: #FFFFFF;
|
171 |
-
letter-spacing: 3px;
|
172 |
-
text-transform: uppercase;
|
173 |
-
}
|
174 |
-
|
175 |
-
.featured_header a {
|
176 |
-
text-decoration: none;
|
177 |
-
}
|
178 |
-
|
179 |
-
.featured_header .old-price {
|
180 |
-
color: #889CA8;
|
181 |
-
text-decoration: line-through;
|
182 |
-
}
|
183 |
-
|
184 |
-
@media screen and (max-width: 1105px) {
|
185 |
-
.featured_header h1 {
|
186 |
-
font-size: 37px;
|
187 |
-
line-height: 0;
|
188 |
-
}
|
189 |
-
}
|
190 |
-
|
191 |
-
@media screen and (max-width: 835px) {
|
192 |
-
.get_plugins span {
|
193 |
-
display: none;
|
194 |
-
}
|
195 |
-
}
|
196 |
-
|
197 |
-
@media screen and (max-width: 700px) {
|
198 |
-
.featured_header h1 {
|
199 |
-
line-height: 40px;
|
200 |
-
}
|
201 |
-
}
|
202 |
-
|
203 |
-
@media screen and (max-width: 435px) {
|
204 |
-
.featured_header h1 {
|
205 |
-
font-size: 20px;
|
206 |
-
line-height: 25px;
|
207 |
-
}
|
208 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
featured/updates.php
DELETED
@@ -1,158 +0,0 @@
|
|
1 |
-
<?php
|
2 |
-
|
3 |
-
/**
|
4 |
-
* Admin page
|
5 |
-
*/
|
6 |
-
|
7 |
-
// Exit if accessed directly.
|
8 |
-
if ( ! defined( 'ABSPATH' ) ) {
|
9 |
-
exit;
|
10 |
-
}
|
11 |
-
|
12 |
-
$upd = FM_Admin::get_instance();
|
13 |
-
$upd->check_for_update();
|
14 |
-
$fm_plugins=$upd->fm_plugins;
|
15 |
-
$updates=$upd->updates;
|
16 |
-
wp_enqueue_style('fm-featured-admin');
|
17 |
-
?>
|
18 |
-
|
19 |
-
<div class="wrap">
|
20 |
-
<?php settings_errors(); ?>
|
21 |
-
<div id="fm-settings">
|
22 |
-
<div id="fm-settings-content">
|
23 |
-
<h2 id="add_on_title"><?php echo esc_html( get_admin_page_title() ); ?></h2>
|
24 |
-
|
25 |
-
|
26 |
-
<div class="main-plugin_desc-cont">
|
27 |
-
You can download the latest version of your plugins from your <a href="https://web-dorado.com/subscriptions.html" target="_blank"> Web-Dorado.com</a> account.
|
28 |
-
After deactivate and
|
29 |
-
delete the current version.
|
30 |
-
Install the downloaded latest version of the plugin.
|
31 |
-
</div>
|
32 |
-
|
33 |
-
<br/>
|
34 |
-
<br/>
|
35 |
-
|
36 |
-
<?php
|
37 |
-
if ( $fm_plugins ) {
|
38 |
-
$update = 0;
|
39 |
-
if ( isset( $fm_plugins[31] ) ) {
|
40 |
-
|
41 |
-
$project = $fm_plugins[31];
|
42 |
-
unset( $fm_plugins[31] );
|
43 |
-
if ( isset( $updates[31] ) ) {
|
44 |
-
$update = 1;
|
45 |
-
}
|
46 |
-
?>
|
47 |
-
<div class="main-plugin">
|
48 |
-
<div class="fm-add-on">
|
49 |
-
<?php if ( $project['fm_data']['image'] ) { ?>
|
50 |
-
<div class="fm-figure-img">
|
51 |
-
<a href="https://web-dorado.com/subscriptions.html" target="_blank">
|
52 |
-
<img src="<?php echo $project['fm_data']['image'] ?>"/>
|
53 |
-
</a>
|
54 |
-
</div>
|
55 |
-
<?php } ?>
|
56 |
-
|
57 |
-
</div>
|
58 |
-
<div class="main-plugin-info">
|
59 |
-
<h2>
|
60 |
-
<a href="https://web-dorado.com/subscriptions.html" target="_blank"><?php echo $project['Title'] ?></a>
|
61 |
-
</h2>
|
62 |
-
<div class="main-plugin_desc-cont">
|
63 |
-
<div class="main-plugin-desc"><?php echo $project['fm_data']['description'] ?></div>
|
64 |
-
<div class="main-plugin-desc main-plugin-desc-info">
|
65 |
-
<p><a href="https://web-dorado.com/subscriptions.html" target="_blank">Version <?php echo $project['Version']?></a></p>
|
66 |
-
</div>
|
67 |
-
|
68 |
-
<?php if ( isset( $updates[31][0] ) ) { ?>
|
69 |
-
<span class="update-info">There is a new <?php echo $updates[31][0]['version']; ?> version available.</span>
|
70 |
-
<p><span>What's new:</span></p>
|
71 |
-
<div class="fm_last_update"><?php echo $updates[31][0]['version'] ?>
|
72 |
-
- <?php echo str_replace('important', '', $updates[31][0]['note']); ?></div>
|
73 |
-
<?php unset( $updates[31][0] ); ?>
|
74 |
-
<?php if ( count( $updates[31] ) > 0 ) { ?>
|
75 |
-
|
76 |
-
<div class="fm_more_updates">
|
77 |
-
<?php foreach ( $updates[31] as $update ) {
|
78 |
-
?>
|
79 |
-
<div class="fm_update"><?php echo $update['version'] ?>
|
80 |
-
- <?php echo str_replace('important', '', $update['note']) ?></div>
|
81 |
-
<?php
|
82 |
-
}
|
83 |
-
?>
|
84 |
-
</div>
|
85 |
-
<a href="#" class="fm_show_more_updates">More updates</a>
|
86 |
-
<?php
|
87 |
-
}
|
88 |
-
} ?>
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
</div>
|
95 |
-
</div>
|
96 |
-
</div>
|
97 |
-
<?php
|
98 |
-
}?>
|
99 |
-
<div class="fm-addons_updates">
|
100 |
-
<?php
|
101 |
-
foreach ( $fm_plugins as $id => $project ) {
|
102 |
-
?>
|
103 |
-
<div class="fm-add-on">
|
104 |
-
<figure class="fm-figure">
|
105 |
-
<div class="fm-figure-img">
|
106 |
-
<a href="https://web-dorado.com/subscriptions.html" target="_blank">
|
107 |
-
<?php if ( $project['fm_data']['image'] ) { ?>
|
108 |
-
<img src="<?php echo $project['fm_data']['image'] ?>"/>
|
109 |
-
<?php } ?>
|
110 |
-
</a>
|
111 |
-
</div>
|
112 |
-
<figcaption class="fm-addon-descr fm-figcaption">
|
113 |
-
<?php if ( isset( $updates[ $id ][0] ) ) { ?>
|
114 |
-
<p>What's new:</p>
|
115 |
-
<?php echo $updates[ $id ][0]['note']; ?>
|
116 |
-
<?php } else { ?><?php echo $project['Title'] ?> is up to date
|
117 |
-
<?php } ?>
|
118 |
-
</figcaption>
|
119 |
-
</figure>
|
120 |
-
<h2><?php echo $project['Title'] ?></h2>
|
121 |
-
<div class="main-plugin-desc-info">
|
122 |
-
<p><a href="https://web-dorado.com/subscriptions.html"
|
123 |
-
target="_blank"><?php echo $project['Version'] ?></a> | Web-Dorado</p>
|
124 |
-
</div>
|
125 |
-
<?php if ( isset( $updates[ $id ] ) && $updates[ $id ][0]['version'] != $project['Version']){ ?>
|
126 |
-
<div class="fm-addon-descr-update">
|
127 |
-
<span
|
128 |
-
class="update-info">There is a new <?php echo $updates[ $id ][0]['version'] ?>
|
129 |
-
version available.</span><br/>
|
130 |
-
</div>
|
131 |
-
<?php } ?>
|
132 |
-
</div>
|
133 |
-
|
134 |
-
<?php
|
135 |
-
}?>
|
136 |
-
</div>
|
137 |
-
<?php
|
138 |
-
}
|
139 |
-
?>
|
140 |
-
|
141 |
-
</div>
|
142 |
-
<!-- #fm-settings-content -->
|
143 |
-
</div>
|
144 |
-
<!-- #fm-settings -->
|
145 |
-
</div><!-- .wrap -->
|
146 |
-
|
147 |
-
<script>
|
148 |
-
jQuery('.fm_show_more_updates').on("click", function(){
|
149 |
-
if( jQuery('.fm_more_updates').is(':visible') == false) {
|
150 |
-
jQuery(this).text('Show less');
|
151 |
-
}else{
|
152 |
-
jQuery(this).text('More updates');
|
153 |
-
}
|
154 |
-
jQuery('.fm_more_updates').slideToggle();
|
155 |
-
return false;
|
156 |
-
});
|
157 |
-
|
158 |
-
</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
form_maker_insert.php
CHANGED
@@ -4,6 +4,11 @@
|
|
4 |
* Class WDFMInsert
|
5 |
*/
|
6 |
class WDCFMInsert {
|
|
|
|
|
|
|
|
|
|
|
7 |
public static function form_maker_insert() {
|
8 |
global $wpdb;
|
9 |
$charset_collate = $wpdb->get_charset_collate();
|
@@ -22,8 +27,8 @@ class WDCFMInsert {
|
|
22 |
`script_mail_user` text NOT NULL,
|
23 |
`counter` int(11) NOT NULL,
|
24 |
`published` int(11) NOT NULL DEFAULT '1',
|
25 |
-
`label_order`
|
26 |
-
`label_order_current`
|
27 |
`article_id` varchar(500) NOT NULL,
|
28 |
`pagination` varchar(128) NOT NULL,
|
29 |
`show_title` varchar(128) NOT NULL,
|
@@ -109,6 +114,12 @@ class WDCFMInsert {
|
|
109 |
) " . $charset_collate . ";";
|
110 |
$wpdb->query($formmaker_display_options);
|
111 |
|
|
|
|
|
|
|
|
|
|
|
|
|
112 |
$formmaker_submits = "CREATE TABLE IF NOT EXISTS `" . $wpdb->prefix . "formmaker_submits` (
|
113 |
`id` int(11) NOT NULL AUTO_INCREMENT,
|
114 |
`form_id` int(11) NOT NULL,
|
@@ -220,8 +231,8 @@ class WDCFMInsert {
|
|
220 |
`script_mail_user` text NOT NULL,
|
221 |
`counter` int(11) NOT NULL,
|
222 |
`published` int(11) NOT NULL DEFAULT '1',
|
223 |
-
`label_order`
|
224 |
-
`label_order_current`
|
225 |
`article_id` varchar(500) NOT NULL,
|
226 |
`pagination` varchar(128) NOT NULL,
|
227 |
`show_title` varchar(128) NOT NULL,
|
@@ -280,20 +291,21 @@ class WDCFMInsert {
|
|
280 |
|
281 |
public static function install_demo_forms() {
|
282 |
global $wpdb;
|
283 |
-
$form_maker_row = $wpdb->get_var('SELECT * FROM ' . $wpdb->prefix . 'formmaker' . (!
|
284 |
if ( !$form_maker_row ) {
|
285 |
$insert_form_id = array();
|
286 |
-
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Contact Us', 'embedded', '', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
287 |
$insert_form_id[] = $wpdb->insert_id;
|
288 |
-
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, '
|
289 |
$insert_form_id[] = $wpdb->insert_id;
|
290 |
-
if ( WDCFM()->is_free != 2 ) {
|
291 |
-
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Feedback Form', 'embedded', '', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"false\" previous_title=\"Previous\" previous_type=\"text\" previous_class=\"wdform-page-button\" previous_checkable=\"false\"><div class=\"wdform_section\"><div class=\"wdform_column\"><div wdid=\"3\" class=\"wdform_row\">%3 - Name%</div><div wdid=\"4\" class=\"wdform_row\">%4 - Email%</div><div wdid=\"5\" class=\"wdform_row\" style=\"position: relative; left: 0px; top: 0px;\">%5 - CMS%</div><div wdid=\"6\" class=\"wdform_row\">%6 - Extension%</div><div wdid=\"7\" class=\"wdform_row\">%7 - Plugin%</div><div wdid=\"2\" class=\"wdform_row\" style=\"position: relative; left: 0px; top: 0px;\">%2 - Subject%</div><div wdid=\"8\" class=\"wdform_row\">%8 - Message%</div><div wdid=\"1\" class=\"wdform_row\">%1 - type_submit_reset_1%</div></div></div><div valign=\"top\" class=\"wdform_footer wd-width-100\"><div class=\"wd-width-100\"><div class=\"wd-width-100 wd-table\" style=\"padding-top:10px;\"><div class=\"wd-table-group\"><div id=\"form_id_temppage_nav1\" class=\"wd-table-row\"></div></div></div></div></div></div></div>', '3', '// Occurs before the form is loaded\r\nfunction before_load() { \r\n} \r\n// Occurs just before submitting the form\r\nfunction before_submit() {\r\n // IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don\'t need to return any value if you don\'t want to stop the submission.\r\n} \r\n// Occurs just before resetting the form\r\nfunction before_reset() { \r\n}', '', '', '1', '%all%', '%all%', '9', '1', '3#**id**#Name#**label**#type_name#****#4#**id**#Email#**label**#type_submitter_mail#****#5#**id**#CMS#**label**#type_radio#****#6#**id**#Extension#**label**#type_own_select#****#7#**id**#Plugin#**label**#type_own_select#****#2#**id**#Subject#**label**#type_text#****#8#**id**#Message#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#2_elementform_id_temp#**id**#Text#**label**#type_text#****#', '3#**id**#Name#**label**#type_name#****#4#**id**#Email#**label**#type_submitter_mail#****#5#**id**#CMS#**label**#type_radio#****#6#**id**#Extension#**label**#type_own_select#****#7#**id**#Plugin#**label**#type_own_select#****#2#**id**#Subject#**label**#type_text#****#8#**id**#Message#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '0', 'none', '', '1', '', '', '', '0', '0', '', 'USD', '0', '3*:*id*:*type_name*:*type*:*Name*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:***********:*w_first_val*:*First***Last*******:*w_title*:*Title*********Middle*:*w_mini_labels*:**:*w_size*:*normal*:*w_name_format*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no***no*:*w_name_fields*:*no*:*w_autofill*:**:*new_field*:*4*:*id*:*type_submitter_mail*:*type*:*Email*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no*:*w_verification*:*Email confirmation*:*w_verification_label*:**:*w_verification_placeholder*:*no*:*w_autofill*:**:*new_field*:*5*:*id*:*type_radio*:*type*:*CMS*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*hor*:*w_flow*:*Joomla!***Wordpress*:*w_choices*:*false***false*:*w_choices_checked*:*1*:*w_rowcol*:*yes*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Joomla!***Wordpress*:*w_choices_value*:*****:*w_choices_params*:**:*w_class*:**:*new_field*:*6*:*id*:*type_own_select*:*type*:*Extension*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:*Select extension***Form Maker***Gallery WD***Spider Calendar*:*w_choices*:*true***false***false***false*:*w_choices_checked*:*true***false***false***false*:*w_choices_disabled*:*yes*:*w_required*:*no*:*w_value_disabled*:****Form Maker***Gallery WD***Spider Calendar*:*w_choices_value*:***********:*w_choices_params*:*wdform_select*:*w_class*:**:*new_field*:*7*:*id*:*type_own_select*:*type*:*Plugin*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:*Select plugin***Form Maker***Photo Gallery***Ecommerce WD*:*w_choices*:*true***false***false***false*:*w_choices_checked*:*true***false***false***false*:*w_choices_disabled*:*yes*:*w_required*:*no*:*w_value_disabled*:****Form Maker***Photo Gallery***Ecommerce WD*:*w_choices_value*:***********:*w_choices_params*:*wdform_select*:*w_class*:**:*new_field*:*2*:*id*:*type_text*:*type*:*Subject*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_regExp_status*:**:*w_regExp_value*:**:*w_regExp_common*:**:*w_regExp_arg*:*Incorrect Value*:*w_regExp_alert*:*no*:*w_unique*:*no*:*w_readonly*:**:*new_field*:*8*:*id*:*type_textarea*:*type*:*Message*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size_w*:*100*:*w_size_h*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:**:*new_field*:*1*:*id*:*type_submit_reset*:*type*:*type_submit_reset_1*:*w_field_label*:*Submit*:*w_submit_title*:*Reset*:*w_reset_title*:**:*w_class*:*true*:*w_act*:**:*new_field*:*', '1', '1', '*', '', '', '', '', '1', '', '', '', '', '1*:*show_hide*:*6*:*field_label*:*and*:*all_any*:*5***==***Joomla!*:*next_condition*:**:*new_condition*:*1*:*show_hide*:*7*:*field_label*:*and*:*all_any*:*5***==***Wordpress*:*next_condition*:**:*new_condition*:*', '', '', '', '', '', '', '1', '1', '1', '1', 'administrator,', '1', '', '', '0', '0', '0', '110', '1', 'Feedback Form', 'You may contact us by filling in this form any time you need professional support or have any questions. You can also fill in the form to leave your comments or feedback.', '" . WDCFM()->plugin_url . "/images/demo/2.png', 'flash', '0', '0');");
|
292 |
-
$insert_form_id[] = $wpdb->insert_id;
|
293 |
-
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Business Demographic Survey', 'embedded', '', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"false\" previous_title=\"Previous\" previous_type=\"text\" previous_class=\"wdform-page-button\" previous_checkable=\"false\"><div class=\"wdform_section\"><div class=\"wdform_column\"><div wdid=\"2\" class=\"wdform_row\">%2 - What is your employment status?%</div><div wdid=\"3\" class=\"wdform_row\">%3 - What is your level of education?%</div><div wdid=\"4\" class=\"wdform_row\">%4 - In which industry do you work?%</div><div wdid=\"6\" class=\"wdform_row\">%6 - What is the annual revenue of your company?%</div><div wdid=\"5\" class=\"wdform_row\">%5 - Enter characters for verification.%</div><div wdid=\"1\" class=\"wdform_row\">%1 - type_submit_reset_1%</div></div></div><div valign=\"top\" class=\"wdform_footer wd-width-100\"><div class=\"wd-width-100\"><div class=\"wd-width-100 wd-table\" style=\"padding-top:10px;\"><div class=\"wd-table-group\"><div id=\"form_id_temppage_nav1\" class=\"wd-table-row\"></div></div></div></div></div></div></div>', '4', '// Occurs before the form is loaded\r\nfunction before_load() { \r\n} \r\n// Occurs just before submitting the form\r\nfunction before_submit() {\r\n // IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don\'t need to return any value if you don\'t want to stop the submission.\r\n} \r\n// Occurs just before resetting the form\r\nfunction before_reset() { \r\n}', '', '', '1', '%all%', '%all%', '7', '1', '2#**id**#What is your employment status?#**label**#type_radio#****#3#**id**#What is your level of education?#**label**#type_radio#****#4#**id**#In which industry do you work?#**label**#type_own_select#****#6#**id**#What is the annual revenue of your company?#**label**#type_radio#****#5#**id**#Enter characters for verification.#**label**#type_captcha#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#6_elementform_id_temp0#**id**#What is your employment status?#**label**#type_radio#****#6_elementform_id_temp1#**id**#What is your level of education?#**label**#type_radio#****#6_elementform_id_temp2#**id**#In which industry do you work?#**label**#type_own_select#****#6_elementform_id_temp3#**id**#Enter characters for verification.#**label**#type_captcha#****#6_elementform_id_temp4#**id**#type_submit_reset_1#**label**#type_submit_reset#****#6_elementform_id_temp5#**id**#type_submit_reset_1#**label**#type_submit_reset#****#6_elementform_id_temp6#**id**##**label**##****#6_elementform_id_temp7#**id**#undefined#**label**#undefined#****#6_elementform_id_temp8#**id**#undefined#**label**#undefined#****#6_elementform_id_temp9#**id**#undefined#**label**#undefined#****#6_elementform_id_temp10#**id**#undefined#**label**#undefined#****#6_elementform_id_temp11#**id**#undefined#**label**#undefined#****#6_elementform_id_temp12#**id**#undefined#**label**#undefined#****#6_elementform_id_temp13#**id**#undefined#**label**#undefined#****#6_elementform_id_temp14#**id**#undefined#**label**#undefined#****#6_elementform_id_temp15#**id**#undefined#**label**#undefined#****#6_elementform_id_temp16#**id**#undefined#**label**#undefined#****#6_elementform_id_temp17#**id**#undefined#**label**#undefined#****#6_elementform_id_temp18#**id**#undefined#**label**#undefined#****#6_elementform_id_temp19#**id**#undefined#**label**#undefined#****#6_elementform_id_temp20#**id**#undefined#**label**#undefined#****#6_elementform_id_temp21#**id**#undefined#**label**#undefined#****#6_elementform_id_temp22#**id**#undefined#**label**#undefined#****#6_elementform_id_temp23#**id**#undefined#**label**#undefined#****#6_elementform_id_temp24#**id**#undefined#**label**#undefined#****#6_elementform_id_temp25#**id**#undefined#**label**#undefined#****#6_elementform_id_temp26#**id**#undefined#**label**#undefined#****#6_elementform_id_temp27#**id**#undefined#**label**#undefined#****#6_elementform_id_temp28#**id**#undefined#**label**#undefined#****#6_elementform_id_temp29#**id**#undefined#**label**#undefined#****#6_elementform_id_temp30#**id**#undefined#**label**#undefined#****#6_elementform_id_temp31#**id**#undefined#**label**#undefined#****#6_elementform_id_temp32#**id**#undefined#**label**#undefined#****#6_elementform_id_temp33#**id**#undefined#**label**#undefined#****#6_elementform_id_temp34#**id**#undefined#**label**#undefined#****#6_elementform_id_temp35#**id**#undefined#**label**#undefined#****#6_elementform_id_temp36#**id**#undefined#**label**#undefined#****#6_elementform_id_temp37#**id**#undefined#**label**#undefined#****#6_elementform_id_temp38#**id**#undefined#**label**#undefined#****#6_elementform_id_temp39#**id**#undefined#**label**#undefined#****#6_elementform_id_temp40#**id**#undefined#**label**#undefined#****#6_elementform_id_temp41#**id**#undefined#**label**#undefined#****#6_elementform_id_temp42#**id**#undefined#**label**#undefined#****#6_elementform_id_temp43#**id**#undefined#**label**#undefined#****#6_elementform_id_temp44#**id**#undefined#**label**#undefined#****#6_elementform_id_temp45#**id**#undefined#**label**#undefined#****#6_elementform_id_temp46#**id**#undefined#**label**#undefined#****#6_elementform_id_temp47#**id**#undefined#**label**#undefined#****#6_elementform_id_temp48#**id**#undefined#**label**#undefined#****#6_elementform_id_temp49#**id**#undefined#**label**#undefined#****#', '2#**id**#What is your employment status?#**label**#type_radio#****#3#**id**#What is your level of education?#**label**#type_radio#****#4#**id**#In which industry do you work?#**label**#type_own_select#****#6#**id**#What is the annual revenue of your company?#**label**#type_radio#****#5#**id**#Enter characters for verification.#**label**#type_captcha#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '0', 'none', '', '1', '', '', '', '0', 'testmode', '', '', '0', '2*:*id*:*type_radio*:*type*:*What is your employment status?*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*ver*:*w_flow*:*Employed full time***Trade or Vocational degree***Not employed, but looking for work***Not employed and not looking for work***Retired***Student***Homemaker***Prefer not to answer*:*w_choices*:*false***false***false***false***false***false***false***false*:*w_choices_checked*:*1*:*w_rowcol*:*no*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Employed full time***Trade or Vocational degree***Not employed, but looking for work***Not employed and not looking for work***Retired***Student***Homemaker***Prefer not to answer*:*w_choices_value*:***********************:*w_choices_params*:**:*w_class*:**:*new_field*:*3*:*id*:*type_radio*:*type*:*What is your level of education?*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*ver*:*w_flow*:*Some high school***High school graduate or equivalent***Trade or Vocational Degree***Some college***Associate degree***Bachelor\'s degree***Graduate or Professional degree***Prefer not to answer*:*w_choices*:*false***false***false***false***false***false***false***false*:*w_choices_checked*:*1*:*w_rowcol*:*no*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Some high school***High school graduate or equivalent***Trade or Vocational Degree***Some college***Associate degree***Bachelor\'s degree***Graduate or Professional degree***Prefer not to answer*:*w_choices_value*:***********************:*w_choices_params*:**:*w_class*:**:*new_field*:*4*:*id*:*type_own_select*:*type*:*In which industry do you work?*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:*Select industry***Agriculture***Engineering***Information Technologies***Media***Local Business*:*w_choices*:*true***false***false***false***false***false*:*w_choices_checked*:*true***false***false***false***false***false*:*w_choices_disabled*:*no*:*w_required*:*no*:*w_value_disabled*:****Agriculture***Engineering***Information Technologies***Media***Local Business*:*w_choices_value*:*****************:*w_choices_params*:*wdform_select*:*w_class*:**:*new_field*:*6*:*id*:*type_radio*:*type*:*What is the annual revenue of your company?*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*ver*:*w_flow*:*Under $10,000***$10,001 to $50,000***$50,001 to $100,000***$100,001 to $500,000***$500,001 to $1 Million***$1 Million to $10 Million***$10 Million to $50 Million***$50 Million to $100 Million***Over $100 Million*:*w_choices*:*false***false***false***false***false***false***false***false***false*:*w_choices_checked*:*1*:*w_rowcol*:*no*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Under $10,000***$10,001 to $50,000***$50,001 to $100,000***$100,001 to $500,000***$500,001 to $1 Million***$1 Million to $10 Million***$10 Million to $50 Million***$50 Million to $100 Million***Over $100 Million*:*w_choices_value*:**************************:*w_choices_params*:**:*w_class*:**:*new_field*:*5*:*id*:*type_captcha*:*type*:*Enter characters for verification.*:*w_field_label*:**:*w_field_label_size*:*left*:*w_field_label_pos*:*yes*:*w_hide_label*:*6*:*w_digit*:**:*w_class*:**:*new_field*:*1*:*id*:*type_submit_reset*:*type*:*type_submit_reset_1*:*w_field_label*:*Submit*:*w_submit_title*:*Reset*:*w_reset_title*:**:*w_class*:*false*:*w_act*:**:*new_field*:*', '1', '1', '*', '', '', '', '', '1', '', '', '', '', '', '', '', '', '', '', '', '1', '1', '1', '1', 'administrator,', '1', '', '', '0', '0', '0', '0', '1', 'Business Demographic Survey', 'Thank you for joining our business demographic survey. Please give us your feedback by filling in the information bellow.', '', 'none', '1', '0');");
|
294 |
-
$insert_form_id[] = $wpdb->insert_id;
|
295 |
-
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Cupcake Order Form', 'embedded', '', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"false\" previous_title=\"Previous\" previous_type=\"text\" previous_class=\"wdform-page-button\" previous_checkable=\"false\"><div class=\"wdform_section\"><div class=\"wdform_column\"><div wdid=\"2\" class=\"wdform_row\">%2 - Name%</div><div wdid=\"3\" class=\"wdform_row\">%3 - Email%</div><div wdid=\"4\" class=\"wdform_row\">%4 - Date%</div><div wdid=\"5\" class=\"wdform_row\">%5 - Cupcakes Flavors (1 doz. minimum)%</div><div wdid=\"6\" class=\"wdform_row\">%6 - Quantity%</div><div wdid=\"7\" class=\"wdform_row\">%7 - Details (if any)%</div><div wdid=\"1\" class=\"wdform_row\">%1 - type_submit_reset_1%</div></div></div><div valign=\"top\" class=\"wdform_footer wd-width-100\"><div class=\"wd-width-100\"><div class=\"wd-width-100 wd-table\" style=\"padding-top:10px;\"><div class=\"wd-table-group\"><div id=\"form_id_temppage_nav1\" class=\"wd-table-row\"></div></div></div></div></div></div></div>', '6', '// Occurs before the form is loaded\r\nfunction before_load() { \r\n} \r\n// Occurs just before submitting the form\r\nfunction before_submit() {\r\n // IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don\'t need to return any value if you don\'t want to stop the submission.\r\n} \r\n// Occurs just before resetting the form\r\nfunction before_reset() { \r\n}', '', '', '1', '%all%', '%all%', '8', '1', '2#**id**#Name#**label**#type_name#****#3#**id**#Email#**label**#type_submitter_mail#****#4#**id**#Date#**label**#type_date_new#****#5#**id**#Cupcakes Flavors (1 doz. minimum)#**label**#type_radio#****#6#**id**#Quantity#**label**#type_spinner#****#7#**id**#Details (if any)#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#5_elementform_id_temp0#**id**#Name#**label**#type_name#****#5_elementform_id_temp1#**id**#Email#**label**#type_submitter_mail#****#5_elementform_id_temp2#**id**#Date#**label**#type_date_new#****#5_elementform_id_temp3#**id**#Name:* Email:* Date* Cupcakes Flavors (1 doz. minimum)#**label**#type_radio#****#5_elementform_id_temp4#**id**#Quantity#**label**#type_spinner#****#5_elementform_id_temp5#**id**#Details (if any)#**label**#type_textarea#****#5_elementform_id_temp6#**id**#type_submit_reset_1#**label**#type_submit_reset#****#5_elementform_id_temp7#**id**#Name#**label**#type_name#****#5_elementform_id_temp8#**id**#Email#**label**#type_submitter_mail#****#5_elementform_id_temp9#**id**#Date#**label**#type_date_new#****#5_elementform_id_temp10#**id**#type_submit_reset_1#**label**#type_submit_reset#****#5_elementform_id_temp11#**id**#type_submit_reset_1#**label**#type_submit_reset#****#5_elementform_id_temp12#**id**#undefined#**label**#undefined#****#5_elementform_id_temp13#**id**#undefined#**label**#undefined#****#5_elementform_id_temp14#**id**#undefined#**label**#undefined#****#5_elementform_id_temp15#**id**#undefined#**label**#undefined#****#5_elementform_id_temp16#**id**#undefined#**label**#undefined#****#5_elementform_id_temp17#**id**#undefined#**label**#undefined#****#5_elementform_id_temp18#**id**#undefined#**label**#undefined#****#5_elementform_id_temp19#**id**#undefined#**label**#undefined#****#5_elementform_id_temp20#**id**#undefined#**label**#undefined#****#5_elementform_id_temp21#**id**#undefined#**label**#undefined#****#5_elementform_id_temp22#**id**#undefined#**label**#undefined#****#5_elementform_id_temp23#**id**#undefined#**label**#undefined#****#5_elementform_id_temp24#**id**#undefined#**label**#undefined#****#5_elementform_id_temp25#**id**#undefined#**label**#undefined#****#5_elementform_id_temp26#**id**#undefined#**label**#undefined#****#5_elementform_id_temp27#**id**#undefined#**label**#undefined#****#5_elementform_id_temp28#**id**#undefined#**label**#undefined#****#5_elementform_id_temp29#**id**#undefined#**label**#undefined#****#5_elementform_id_temp30#**id**#undefined#**label**#undefined#****#5_elementform_id_temp31#**id**#undefined#**label**#undefined#****#5_elementform_id_temp32#**id**#undefined#**label**#undefined#****#5_elementform_id_temp33#**id**#undefined#**label**#undefined#****#5_elementform_id_temp34#**id**#undefined#**label**#undefined#****#5_elementform_id_temp35#**id**#undefined#**label**#undefined#****#5_elementform_id_temp36#**id**#undefined#**label**#undefined#****#5_elementform_id_temp37#**id**#undefined#**label**#undefined#****#5_elementform_id_temp38#**id**#undefined#**label**#undefined#****#5_elementform_id_temp39#**id**#undefined#**label**#undefined#****#5_elementform_id_temp40#**id**#undefined#**label**#undefined#****#5_elementform_id_temp41#**id**#undefined#**label**#undefined#****#5_elementform_id_temp42#**id**#undefined#**label**#undefined#****#5_elementform_id_temp43#**id**#undefined#**label**#undefined#****#5_elementform_id_temp44#**id**#undefined#**label**#undefined#****#5_elementform_id_temp45#**id**#undefined#**label**#undefined#****#5_elementform_id_temp46#**id**#undefined#**label**#undefined#****#5_elementform_id_temp47#**id**#undefined#**label**#undefined#****#5_elementform_id_temp48#**id**#undefined#**label**#undefined#****#5_elementform_id_temp49#**id**#undefined#**label**#undefined#****#', '2#**id**#Name#**label**#type_name#****#3#**id**#Email#**label**#type_submitter_mail#****#4#**id**#Date#**label**#type_date_new#****#5#**id**#Cupcakes Flavors (1 doz. minimum)#**label**#type_radio#****#6#**id**#Quantity#**label**#type_spinner#****#7#**id**#Details (if any)#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '0', 'none', '', '1', '', '', '', '0', 'testmode', '', '', '0', '2*:*id*:*type_name*:*type*:*Name*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:***********:*w_first_val*:***********:*w_title*:*Title*********Middle*:*w_mini_labels*:**:*w_size*:*normal*:*w_name_format*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no***no*:*w_name_fields*:*no*:*w_autofill*:**:*new_field*:*3*:*id*:*type_submitter_mail*:*type*:*Email*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no*:*w_verification*:*Email confirmation*:*w_verification_label*:**:*w_verification_placeholder*:*no*:*w_autofill*:**:*new_field*:*4*:*id*:*type_date_new*:*type*:*Date*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_date*:*yes*:*w_required*:*yes*:*w_show_image*:**:*w_class*:*mm/dd/yy*:*w_format*:*0*:*w_start_day*:**:*w_default_date*:**:*w_min_date*:**:*w_max_date*:**:*w_invalid_dates*:*yes***yes***yes***yes***yes***yes***yes*:*w_show_days*:*yes*:*w_hide_time*:*...*:*w_but_val*:*no*:*w_disable_past_days*:**:*new_field*:*5*:*id*:*type_radio*:*type*:*Cupcakes Flavors (1 doz. minimum)*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*ver*:*w_flow*:*Red Velvet***Vanilla***Chocolate***Guinness***Coconut***Lemon***Chocolate Mint*:*w_choices*:*false***false***false***false***false***false***false*:*w_choices_checked*:*1*:*w_rowcol*:*no*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Red Velvet***Vanilla***Chocolate***Guinness***Coconut***Lemon***Chocolate Mint*:*w_choices_value*:********************:*w_choices_params*:**:*w_class*:**:*new_field*:*6*:*id*:*type_spinner*:*type*:*Quantity*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:*60*:*w_field_width*:**:*w_field_min_value*:**:*w_field_max_value*:*1*:*w_field_step*:*null*:*w_field_value*:*no*:*w_required*:**:*w_class*:**:*new_field*:*7*:*id*:*type_textarea*:*type*:*Details (if any)*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size_w*:*100*:*w_size_h*:**:*w_first_val*:**:*w_title*:*no*:*w_required*:*no*:*w_unique*:**:*w_class*:**:*new_field*:*1*:*id*:*type_submit_reset*:*type*:*type_submit_reset_1*:*w_field_label*:*Submit*:*w_submit_title*:*Reset*:*w_reset_title*:**:*w_class*:*false*:*w_act*:**:*new_field*:*', '1', '1', '*', '', '', '', '', '1', '', '', '', '', '', '', '', '', '', '', '', '1', '1', '1', '1', 'administrator,', '1', '', '', '0', '0', '0', '0', '1', 'Cupcake Order Form', '', '', 'none', '1', '0');");
|
296 |
-
$insert_form_id[] = $wpdb->insert_id;
|
297 |
}
|
298 |
else {
|
299 |
update_option('contact_form_forms', implode(',', $insert_form_id));
|
4 |
* Class WDFMInsert
|
5 |
*/
|
6 |
class WDCFMInsert {
|
7 |
+
/**
|
8 |
+
* PLUGIN = 2 points to Contact Form Maker
|
9 |
+
*/
|
10 |
+
const PLUGIN = 2;
|
11 |
+
|
12 |
public static function form_maker_insert() {
|
13 |
global $wpdb;
|
14 |
$charset_collate = $wpdb->get_charset_collate();
|
27 |
`script_mail_user` text NOT NULL,
|
28 |
`counter` int(11) NOT NULL,
|
29 |
`published` int(11) NOT NULL DEFAULT '1',
|
30 |
+
`label_order` longtext NOT NULL,
|
31 |
+
`label_order_current` longtext NOT NULL,
|
32 |
`article_id` varchar(500) NOT NULL,
|
33 |
`pagination` varchar(128) NOT NULL,
|
34 |
`show_title` varchar(128) NOT NULL,
|
114 |
) " . $charset_collate . ";";
|
115 |
$wpdb->query($formmaker_display_options);
|
116 |
|
117 |
+
$formmaker_groups = "CREATE TABLE IF NOT EXISTS `" . $wpdb->prefix . "formmaker_groups` (
|
118 |
+
`id` int(11) NOT NULL AUTO_INCREMENT,
|
119 |
+
PRIMARY KEY (`id`)
|
120 |
+
) " . $charset_collate . ";";
|
121 |
+
$wpdb->query($formmaker_groups);
|
122 |
+
|
123 |
$formmaker_submits = "CREATE TABLE IF NOT EXISTS `" . $wpdb->prefix . "formmaker_submits` (
|
124 |
`id` int(11) NOT NULL AUTO_INCREMENT,
|
125 |
`form_id` int(11) NOT NULL,
|
231 |
`script_mail_user` text NOT NULL,
|
232 |
`counter` int(11) NOT NULL,
|
233 |
`published` int(11) NOT NULL DEFAULT '1',
|
234 |
+
`label_order` longtext NOT NULL,
|
235 |
+
`label_order_current` longtext NOT NULL,
|
236 |
`article_id` varchar(500) NOT NULL,
|
237 |
`pagination` varchar(128) NOT NULL,
|
238 |
`show_title` varchar(128) NOT NULL,
|
291 |
|
292 |
public static function install_demo_forms() {
|
293 |
global $wpdb;
|
294 |
+
$form_maker_row = $wpdb->get_var('SELECT * FROM ' . $wpdb->prefix . 'formmaker' . (!WDFMInstance(self::PLUGIN)->is_free ? '' : ' WHERE id' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ')'));
|
295 |
if ( !$form_maker_row ) {
|
296 |
$insert_form_id = array();
|
297 |
+
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Contact Us', 'embedded', '{adminemail}', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"true\" previous_title=\"Previous\" previous_type=\"text\" previous_class=\"wdform-page-button\" previous_checkable=\"false\"><div class=\"wdform_section\"><div class=\"wdform_column\"><div wdid=\"2\" class=\"wdform_row\">%2 - Name%</div><div wdid=\"3\" class=\"wdform_row\">%3 - Email%</div><div wdid=\"4\" class=\"wdform_row\">%4 - Subject%</div><div wdid=\"5\" class=\"wdform_row\">%5 - Message%</div><div wdid=\"1\" class=\"wdform_row\">%1 - type_submit_reset_1%</div></div></div><div valign=\"top\" class=\"wdform_footer wd-width-100\"><div class=\"wd-width-100\"><div class=\"wd-width-100 wd-table\" style=\"padding-top:10px;\"><div class=\"wd-table-group\"><div id=\"form_id_temppage_nav1\" class=\"wd-table-row\"></div></div></div></div></div></div></div>', '1', '// Occurs before the form is loaded\r\nfunction before_load() { \r\n} \r\n// Occurs just before submitting the form\r\nfunction before_submit() {\r\n // IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don\'t need to return any value if you don\'t want to stop the submission.\r\n} \r\n// Occurs just before resetting the form\r\nfunction before_reset() { \r\n}\r\n// Occurs after form is submitted and reloaded\r\nfunction after_submit() {\r\n \r\n}', '', '', '1', '{all}', '{all}', '6', '1', '2#**id**#Name#**label**#type_text#****#3#**id**#Email#**label**#type_submitter_mail#****#4#**id**#Subject#**label**#type_text#****#5#**id**#Message#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#2_elementform_id_temp#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '2#**id**#Name#**label**#type_text#****#3#**id**#Email#**label**#type_submitter_mail#****#4#**id**#Subject#**label**#type_text#****#5#**id**#Message#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '0', 'none', '', '1', '', '', '', '0', 'testmode', '', '', '0', '2*:*id*:*type_text*:*type*:*Name*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_regExp_status*:**:*w_regExp_value*:**:*w_regExp_common*:**:*w_regExp_arg*:*Incorrect Value*:*w_regExp_alert*:*no*:*w_unique*:*no*:*w_readonly*:**:*new_field*:*3*:*id*:*type_submitter_mail*:*type*:*Email*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no*:*w_verification*:*Email confirmation*:*w_verification_label*:**:*w_verification_placeholder*:*no*:*w_autofill*:**:*new_field*:*4*:*id*:*type_text*:*type*:*Subject*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_regExp_status*:**:*w_regExp_value*:**:*w_regExp_common*:**:*w_regExp_arg*:*Incorrect Value*:*w_regExp_alert*:*no*:*w_unique*:*no*:*w_readonly*:**:*new_field*:*5*:*id*:*type_textarea*:*type*:*Message*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size_w*:*100*:*w_size_h*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:**:*new_field*:*1*:*id*:*type_submit_reset*:*type*:*type_submit_reset_1*:*w_field_label*:*Submit*:*w_submit_title*:*Reset*:*w_reset_title*:**:*w_class*:*false*:*w_act*:**:*new_field*:*', '1', '1', '*', '', '', '', '', '1', '', '', '', '', '', '', '', '', '', '', '', '1', '1', '1', '1', 'administrator,', '1', '', '', '0', '0', '0', '0', '1', 'Contact Us', 'You may contact us by filling in this form any time you need professional support or have any questions. You can also fill in the form to leave your comments or feedback.', '', 'none', '0', '0');");
|
298 |
+
$insert_form_id[] = $wpdb->insert_id;
|
299 |
+
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Client List Form', 'embedded', '{adminemail}', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"true\" previous_title=\"Previous\" previous_type=\"text\" previous_class=\"wdform-page-button\" previous_checkable=\"false\"><div class=\"wdform_section\"><div class=\"wdform_column\"><div wdid=\"2\" class=\"wdform_row\">%2 - First Name%</div><div wdid=\"3\" class=\"wdform_row\">%3 - Last Name%</div><div wdid=\"4\" class=\"wdform_row\">%4 - Email%</div><div wdid=\"5\" class=\"wdform_row\">%5 - Phone%</div><div wdid=\"6\" class=\"wdform_row\">%6 - Website%</div><div wdid=\"7\" class=\"wdform_row\">%7 - Address%</div><div wdid=\"1\" class=\"wdform_row\">%1 - type_submit_reset_1%</div></div></div><div valign=\"top\" class=\"wdform_footer wd-width-100\"><div class=\"wd-width-100\"><div class=\"wd-width-100 wd-table\" style=\"padding-top:10px;\"><div class=\"wd-table-group\"><div id=\"form_id_temppage_nav1\" class=\"wd-table-row\"></div></div></div></div></div></div></div>', '1', '// Occurs before the form is loaded\r\nfunction before_load() { \r\n} \r\n// Occurs just before submitting the form\r\nfunction before_submit() {\r\n // IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don\'t need to return any value if you don\'t want to stop the submission.\r\n} \r\n// Occurs just before resetting the form\r\nfunction before_reset() { \r\n}// Occurs after form is submitted and reloaded\r\nfunction after_submit() {\r\n \r\n}', '', '', '1', '{all}', '{all}', '13', '1', '2#**id**#First Name#**label**#type_text#****#3#**id**#Last Name#**label**#type_text#****#4#**id**#Email#**label**#type_submitter_mail#****#5#**id**#Phone#**label**#type_text#****#6#**id**#Website#**label**#type_text#****#7#**id**#Street Address#**label**#type_address#****#8#**id**#Street Address Line 2#**label**#type_address#****#9#**id**#City#**label**#type_address#****#10#**id**#State / Province / Region#**label**#type_address#****#11#**id**#Postal / Zip Code#**label**#type_address#****#12#**id**#Country#**label**#type_address#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#7_street1form_id_temp#**id**#type_submit_reset_1#**label**#type_submit_reset#****#7_street2form_id_temp#**id**##**label**##****#7_cityform_id_temp#**id**#undefined#**label**#undefined#****#7_stateform_id_temp#**id**#undefined#**label**#undefined#****#7_postalform_id_temp#**id**#undefined#**label**#undefined#****#7_countryform_id_temp#**id**#undefined#**label**#undefined#****#', '2#**id**#First Name#**label**#type_text#****#3#**id**#Last Name#**label**#type_text#****#4#**id**#Email#**label**#type_submitter_mail#****#5#**id**#Phone#**label**#type_text#****#6#**id**#Website#**label**#type_text#****#7#**id**#Street Address#**label**#type_address#****#8#**id**#Street Address Line 2#**label**#type_address#****#9#**id**#City#**label**#type_address#****#10#**id**#State / Province / Region#**label**#type_address#****#11#**id**#Postal / Zip Code#**label**#type_address#****#12#**id**#Country#**label**#type_address#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '0', 'none', '', '1', '', '', '', '0', 'testmode', '', '', '0', '2*:*id*:*type_text*:*type*:*First Name*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*no*:*w_required*:*no*:*w_regExp_status*:**:*w_regExp_value*:**:*w_regExp_common*:**:*w_regExp_arg*:*Incorrect Value*:*w_regExp_alert*:*no*:*w_unique*:*no*:*w_readonly*:**:*new_field*:*3*:*id*:*type_text*:*type*:*Last Name*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*no*:*w_required*:*no*:*w_regExp_status*:**:*w_regExp_value*:**:*w_regExp_common*:**:*w_regExp_arg*:*Incorrect Value*:*w_regExp_alert*:*no*:*w_unique*:*no*:*w_readonly*:**:*new_field*:*4*:*id*:*type_submitter_mail*:*type*:*Email*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no*:*w_verification*:*Email confirmation*:*w_verification_label*:**:*w_verification_placeholder*:*no*:*w_autofill*:**:*new_field*:*5*:*id*:*type_text*:*type*:*Phone*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*no*:*w_required*:*no*:*w_regExp_status*:**:*w_regExp_value*:**:*w_regExp_common*:**:*w_regExp_arg*:*Incorrect Value*:*w_regExp_alert*:*no*:*w_unique*:*no*:*w_readonly*:**:*new_field*:*6*:*id*:*type_text*:*type*:*Website*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:*http://example.com*:*w_title*:*no*:*w_required*:*no*:*w_regExp_status*:**:*w_regExp_value*:**:*w_regExp_common*:**:*w_regExp_arg*:*Incorrect Value*:*w_regExp_alert*:*no*:*w_unique*:*no*:*w_readonly*:**:*new_field*:*7*:*id*:*type_address*:*type*:*Address*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:*Street Address***Street Address Line 2***City***State / Province / Region***Postal / Zip Code***Country*:*w_mini_labels*:*no***no***no***no***no***no***no*:*w_disabled_fields*:*no*:*w_required*:*wdform_address*:*w_class*:**:*new_field*:*1*:*id*:*type_submit_reset*:*type*:*type_submit_reset_1*:*w_field_label*:*Submit*:*w_submit_title*:*Reset*:*w_reset_title*:**:*w_class*:*false*:*w_act*:**:*new_field*:*', '1', '1', '*', '', '', '', '', '1', '', '', '', '', '', '', '', '', '', '', '', '1', '1', '1', '1', 'administrator,', '1', '', '', '0', '0', '0', '0', '1', '', '', '', 'none', '0', '0');");
|
300 |
+
$insert_form_id[] = $wpdb->insert_id;
|
301 |
+
|
302 |
+
if ( WDFMInstance(self::PLUGIN)->is_free != 2 ) {
|
303 |
+
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Feedback Form', 'embedded', '{adminemail}', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"true\" previous_title=\"Previous\" previous_type=\"text\" previous_class=\"wdform-page-button\" previous_checkable=\"false\"><div class=\"wdform_section\"><div class=\"wdform_column\"><div wdid=\"3\" class=\"wdform_row\">%3 - Name%</div><div wdid=\"4\" class=\"wdform_row\">%4 - Email%</div><div wdid=\"5\" class=\"wdform_row\" style=\"position: relative; left: 0px; top: 0px;\">%5 - CMS%</div><div wdid=\"6\" class=\"wdform_row\">%6 - Extension%</div><div wdid=\"7\" class=\"wdform_row\">%7 - Plugin%</div><div wdid=\"2\" class=\"wdform_row\" style=\"position: relative; left: 0px; top: 0px;\">%2 - Subject%</div><div wdid=\"8\" class=\"wdform_row\">%8 - Message%</div><div wdid=\"1\" class=\"wdform_row\">%1 - type_submit_reset_1%</div></div></div><div valign=\"top\" class=\"wdform_footer wd-width-100\"><div class=\"wd-width-100\"><div class=\"wd-width-100 wd-table\" style=\"padding-top:10px;\"><div class=\"wd-table-group\"><div id=\"form_id_temppage_nav1\" class=\"wd-table-row\"></div></div></div></div></div></div></div>', '3', '// Occurs before the form is loaded\r\nfunction before_load() { \r\n} \r\n// Occurs just before submitting the form\r\nfunction before_submit() {\r\n // IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don\'t need to return any value if you don\'t want to stop the submission.\r\n} \r\n// Occurs just before resetting the form\r\nfunction before_reset() { \r\n}// Occurs after form is submitted and reloaded\r\nfunction after_submit() {\r\n \r\n}', '', '', '1', '{all}', '{all}', '9', '1', '3#**id**#Name#**label**#type_name#****#4#**id**#Email#**label**#type_submitter_mail#****#5#**id**#CMS#**label**#type_radio#****#6#**id**#Extension#**label**#type_own_select#****#7#**id**#Plugin#**label**#type_own_select#****#2#**id**#Subject#**label**#type_text#****#8#**id**#Message#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#2_elementform_id_temp#**id**#Text#**label**#type_text#****#', '3#**id**#Name#**label**#type_name#****#4#**id**#Email#**label**#type_submitter_mail#****#5#**id**#CMS#**label**#type_radio#****#6#**id**#Extension#**label**#type_own_select#****#7#**id**#Plugin#**label**#type_own_select#****#2#**id**#Subject#**label**#type_text#****#8#**id**#Message#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '0', 'none', '', '1', '', '', '', '0', '0', '', 'USD', '0', '3*:*id*:*type_name*:*type*:*Name*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:***********:*w_first_val*:*First***Last*******:*w_title*:*Title*********Middle*:*w_mini_labels*:**:*w_size*:*normal*:*w_name_format*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no***no*:*w_name_fields*:*no*:*w_autofill*:**:*new_field*:*4*:*id*:*type_submitter_mail*:*type*:*Email*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no*:*w_verification*:*Email confirmation*:*w_verification_label*:**:*w_verification_placeholder*:*no*:*w_autofill*:**:*new_field*:*5*:*id*:*type_radio*:*type*:*CMS*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*hor*:*w_flow*:*Joomla!***Wordpress*:*w_choices*:*false***false*:*w_choices_checked*:*1*:*w_rowcol*:*yes*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Joomla!***Wordpress*:*w_choices_value*:*****:*w_choices_params*:**:*w_class*:**:*new_field*:*6*:*id*:*type_own_select*:*type*:*Extension*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:*Select extension***Form Maker***Gallery WD***Spider Calendar*:*w_choices*:*true***false***false***false*:*w_choices_checked*:*true***false***false***false*:*w_choices_disabled*:*yes*:*w_required*:*no*:*w_value_disabled*:****Form Maker***Gallery WD***Spider Calendar*:*w_choices_value*:***********:*w_choices_params*:*wdform_select*:*w_class*:**:*new_field*:*7*:*id*:*type_own_select*:*type*:*Plugin*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:*Select plugin***Form Maker***Photo Gallery***Ecommerce WD*:*w_choices*:*true***false***false***false*:*w_choices_checked*:*true***false***false***false*:*w_choices_disabled*:*yes*:*w_required*:*no*:*w_value_disabled*:****Form Maker***Photo Gallery***Ecommerce WD*:*w_choices_value*:***********:*w_choices_params*:*wdform_select*:*w_class*:**:*new_field*:*2*:*id*:*type_text*:*type*:*Subject*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_regExp_status*:**:*w_regExp_value*:**:*w_regExp_common*:**:*w_regExp_arg*:*Incorrect Value*:*w_regExp_alert*:*no*:*w_unique*:*no*:*w_readonly*:**:*new_field*:*8*:*id*:*type_textarea*:*type*:*Message*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size_w*:*100*:*w_size_h*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:**:*new_field*:*1*:*id*:*type_submit_reset*:*type*:*type_submit_reset_1*:*w_field_label*:*Submit*:*w_submit_title*:*Reset*:*w_reset_title*:**:*w_class*:*true*:*w_act*:**:*new_field*:*', '1', '1', '*', '', '', '', '', '1', '', '', '', '', '1*:*show_hide*:*6*:*field_label*:*and*:*all_any*:*5***==***Joomla!*:*next_condition*:**:*new_condition*:*1*:*show_hide*:*7*:*field_label*:*and*:*all_any*:*5***==***Wordpress*:*next_condition*:**:*new_condition*:*', '', '', '', '', '', '', '1', '1', '1', '1', 'administrator,', '1', '', '', '0', '0', '0', '110', '1', 'Feedback Form', 'You may contact us by filling in this form any time you need professional support or have any questions. You can also fill in the form to leave your comments or feedback.', '" . WDFMInstance(self::PLUGIN)->plugin_url . "/images/demo/2.png', 'flash', '0', '0');");
|
304 |
+
$insert_form_id[] = $wpdb->insert_id;
|
305 |
+
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Business Demographic Survey', 'embedded', '{adminemail}', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"true\" previous_title=\"Previous\" previous_type=\"text\" previous_class=\"wdform-page-button\" previous_checkable=\"false\"><div class=\"wdform_section\"><div class=\"wdform_column\"><div wdid=\"2\" class=\"wdform_row\">%2 - What is your employment status?%</div><div wdid=\"3\" class=\"wdform_row\">%3 - What is your level of education?%</div><div wdid=\"4\" class=\"wdform_row\">%4 - In which industry do you work?%</div><div wdid=\"6\" class=\"wdform_row\">%6 - What is the annual revenue of your company?%</div><div wdid=\"5\" class=\"wdform_row\">%5 - Enter characters for verification.%</div><div wdid=\"1\" class=\"wdform_row\">%1 - type_submit_reset_1%</div></div></div><div valign=\"top\" class=\"wdform_footer wd-width-100\"><div class=\"wd-width-100\"><div class=\"wd-width-100 wd-table\" style=\"padding-top:10px;\"><div class=\"wd-table-group\"><div id=\"form_id_temppage_nav1\" class=\"wd-table-row\"></div></div></div></div></div></div></div>', '4', '// Occurs before the form is loaded\r\nfunction before_load() { \r\n} \r\n// Occurs just before submitting the form\r\nfunction before_submit() {\r\n // IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don\'t need to return any value if you don\'t want to stop the submission.\r\n} \r\n// Occurs just before resetting the form\r\nfunction before_reset() { \r\n}// Occurs after form is submitted and reloaded\r\nfunction after_submit() {\r\n \r\n}', '', '', '1', '{all}', '{all}', '7', '1', '2#**id**#What is your employment status?#**label**#type_radio#****#3#**id**#What is your level of education?#**label**#type_radio#****#4#**id**#In which industry do you work?#**label**#type_own_select#****#6#**id**#What is the annual revenue of your company?#**label**#type_radio#****#5#**id**#Enter characters for verification.#**label**#type_captcha#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#6_elementform_id_temp0#**id**#What is your employment status?#**label**#type_radio#****#6_elementform_id_temp1#**id**#What is your level of education?#**label**#type_radio#****#6_elementform_id_temp2#**id**#In which industry do you work?#**label**#type_own_select#****#6_elementform_id_temp3#**id**#Enter characters for verification.#**label**#type_captcha#****#6_elementform_id_temp4#**id**#type_submit_reset_1#**label**#type_submit_reset#****#6_elementform_id_temp5#**id**#type_submit_reset_1#**label**#type_submit_reset#****#6_elementform_id_temp6#**id**##**label**##****#6_elementform_id_temp7#**id**#undefined#**label**#undefined#****#6_elementform_id_temp8#**id**#undefined#**label**#undefined#****#6_elementform_id_temp9#**id**#undefined#**label**#undefined#****#6_elementform_id_temp10#**id**#undefined#**label**#undefined#****#6_elementform_id_temp11#**id**#undefined#**label**#undefined#****#6_elementform_id_temp12#**id**#undefined#**label**#undefined#****#6_elementform_id_temp13#**id**#undefined#**label**#undefined#****#6_elementform_id_temp14#**id**#undefined#**label**#undefined#****#6_elementform_id_temp15#**id**#undefined#**label**#undefined#****#6_elementform_id_temp16#**id**#undefined#**label**#undefined#****#6_elementform_id_temp17#**id**#undefined#**label**#undefined#****#6_elementform_id_temp18#**id**#undefined#**label**#undefined#****#6_elementform_id_temp19#**id**#undefined#**label**#undefined#****#6_elementform_id_temp20#**id**#undefined#**label**#undefined#****#6_elementform_id_temp21#**id**#undefined#**label**#undefined#****#6_elementform_id_temp22#**id**#undefined#**label**#undefined#****#6_elementform_id_temp23#**id**#undefined#**label**#undefined#****#6_elementform_id_temp24#**id**#undefined#**label**#undefined#****#6_elementform_id_temp25#**id**#undefined#**label**#undefined#****#6_elementform_id_temp26#**id**#undefined#**label**#undefined#****#6_elementform_id_temp27#**id**#undefined#**label**#undefined#****#6_elementform_id_temp28#**id**#undefined#**label**#undefined#****#6_elementform_id_temp29#**id**#undefined#**label**#undefined#****#6_elementform_id_temp30#**id**#undefined#**label**#undefined#****#6_elementform_id_temp31#**id**#undefined#**label**#undefined#****#6_elementform_id_temp32#**id**#undefined#**label**#undefined#****#6_elementform_id_temp33#**id**#undefined#**label**#undefined#****#6_elementform_id_temp34#**id**#undefined#**label**#undefined#****#6_elementform_id_temp35#**id**#undefined#**label**#undefined#****#6_elementform_id_temp36#**id**#undefined#**label**#undefined#****#6_elementform_id_temp37#**id**#undefined#**label**#undefined#****#6_elementform_id_temp38#**id**#undefined#**label**#undefined#****#6_elementform_id_temp39#**id**#undefined#**label**#undefined#****#6_elementform_id_temp40#**id**#undefined#**label**#undefined#****#6_elementform_id_temp41#**id**#undefined#**label**#undefined#****#6_elementform_id_temp42#**id**#undefined#**label**#undefined#****#6_elementform_id_temp43#**id**#undefined#**label**#undefined#****#6_elementform_id_temp44#**id**#undefined#**label**#undefined#****#6_elementform_id_temp45#**id**#undefined#**label**#undefined#****#6_elementform_id_temp46#**id**#undefined#**label**#undefined#****#6_elementform_id_temp47#**id**#undefined#**label**#undefined#****#6_elementform_id_temp48#**id**#undefined#**label**#undefined#****#6_elementform_id_temp49#**id**#undefined#**label**#undefined#****#', '2#**id**#What is your employment status?#**label**#type_radio#****#3#**id**#What is your level of education?#**label**#type_radio#****#4#**id**#In which industry do you work?#**label**#type_own_select#****#6#**id**#What is the annual revenue of your company?#**label**#type_radio#****#5#**id**#Enter characters for verification.#**label**#type_captcha#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '0', 'none', '', '1', '', '', '', '0', 'testmode', '', '', '0', '2*:*id*:*type_radio*:*type*:*What is your employment status?*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*ver*:*w_flow*:*Employed full time***Trade or Vocational degree***Not employed, but looking for work***Not employed and not looking for work***Retired***Student***Homemaker***Prefer not to answer*:*w_choices*:*false***false***false***false***false***false***false***false*:*w_choices_checked*:*1*:*w_rowcol*:*no*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Employed full time***Trade or Vocational degree***Not employed, but looking for work***Not employed and not looking for work***Retired***Student***Homemaker***Prefer not to answer*:*w_choices_value*:***********************:*w_choices_params*:**:*w_class*:**:*new_field*:*3*:*id*:*type_radio*:*type*:*What is your level of education?*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*ver*:*w_flow*:*Some high school***High school graduate or equivalent***Trade or Vocational Degree***Some college***Associate degree***Bachelor\'s degree***Graduate or Professional degree***Prefer not to answer*:*w_choices*:*false***false***false***false***false***false***false***false*:*w_choices_checked*:*1*:*w_rowcol*:*no*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Some high school***High school graduate or equivalent***Trade or Vocational Degree***Some college***Associate degree***Bachelor\'s degree***Graduate or Professional degree***Prefer not to answer*:*w_choices_value*:***********************:*w_choices_params*:**:*w_class*:**:*new_field*:*4*:*id*:*type_own_select*:*type*:*In which industry do you work?*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:*Select industry***Agriculture***Engineering***Information Technologies***Media***Local Business*:*w_choices*:*true***false***false***false***false***false*:*w_choices_checked*:*true***false***false***false***false***false*:*w_choices_disabled*:*no*:*w_required*:*no*:*w_value_disabled*:****Agriculture***Engineering***Information Technologies***Media***Local Business*:*w_choices_value*:*****************:*w_choices_params*:*wdform_select*:*w_class*:**:*new_field*:*6*:*id*:*type_radio*:*type*:*What is the annual revenue of your company?*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*ver*:*w_flow*:*Under $10,000***$10,001 to $50,000***$50,001 to $100,000***$100,001 to $500,000***$500,001 to $1 Million***$1 Million to $10 Million***$10 Million to $50 Million***$50 Million to $100 Million***Over $100 Million*:*w_choices*:*false***false***false***false***false***false***false***false***false*:*w_choices_checked*:*1*:*w_rowcol*:*no*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Under $10,000***$10,001 to $50,000***$50,001 to $100,000***$100,001 to $500,000***$500,001 to $1 Million***$1 Million to $10 Million***$10 Million to $50 Million***$50 Million to $100 Million***Over $100 Million*:*w_choices_value*:**************************:*w_choices_params*:**:*w_class*:**:*new_field*:*5*:*id*:*type_captcha*:*type*:*Enter characters for verification.*:*w_field_label*:**:*w_field_label_size*:*left*:*w_field_label_pos*:*yes*:*w_hide_label*:*6*:*w_digit*:**:*w_class*:**:*new_field*:*1*:*id*:*type_submit_reset*:*type*:*type_submit_reset_1*:*w_field_label*:*Submit*:*w_submit_title*:*Reset*:*w_reset_title*:**:*w_class*:*false*:*w_act*:**:*new_field*:*', '1', '1', '*', '', '', '', '', '1', '', '', '', '', '', '', '', '', '', '', '', '1', '1', '1', '1', 'administrator,', '1', '', '', '0', '0', '0', '0', '1', 'Business Demographic Survey', 'Thank you for joining our business demographic survey. Please give us your feedback by filling in the information bellow.', '', 'none', '1', '0');");
|
306 |
$insert_form_id[] = $wpdb->insert_id;
|
307 |
+
$wpdb->query("INSERT INTO `" . $wpdb->prefix . "formmaker` (`id`, `title`, `type`, `mail`, `form_front`, `theme`, `javascript`, `submit_text`, `url`, `submit_text_type`, `script_mail`, `script_mail_user`, `counter`, `published`, `label_order`, `label_order_current`, `article_id`, `pagination`, `show_title`, `show_numbers`, `public_key`, `private_key`, `recaptcha_theme`, `paypal_mode`, `checkout_mode`, `paypal_email`, `payment_currency`, `tax`, `form_fields`, `savedb`, `sendemail`, `requiredmark`, `from_mail`, `from_name`, `reply_to`, `send_to`, `autogen_layout`, `custom_front`, `mail_from_user`, `mail_from_name_user`, `reply_to_user`, `condition`, `mail_cc`, `mail_cc_user`, `mail_bcc`, `mail_bcc_user`, `mail_subject`, `mail_subject_user`, `mail_mode`, `mail_mode_user`, `mail_attachment`, `mail_attachment_user`, `user_id_wd`, `sortable`, `frontend_submit_fields`, `frontend_submit_stat_fields`, `mail_emptyfields`, `mail_verify`, `mail_verify_expiretime`, `mail_verification_post_id`, `save_uploads`, `header_title`, `header_description`, `header_image_url`, `header_image_animation`, `header_hide_image`, `jsversion`) VALUES (NULL, 'Cupcake Order Form', 'embedded', '{adminemail}', '<div class=\"wdform-page-and-images\"><div id=\"form_id_tempform_view1\" class=\"wdform_page\" page_title=\"Untitled page\" next_title=\"Next\" next_type=\"text\" next_class=\"wdform-page-button\" next_checkable=\"true\" previous_title=\"Previous\" previous_type=\"text\" previous_class=\"wdform-page-button\" previous_checkable=\"false\"><div class=\"wdform_section\"><div class=\"wdform_column\"><div wdid=\"2\" class=\"wdform_row\">%2 - Name%</div><div wdid=\"3\" class=\"wdform_row\">%3 - Email%</div><div wdid=\"4\" class=\"wdform_row\">%4 - Date%</div><div wdid=\"5\" class=\"wdform_row\">%5 - Cupcakes Flavors (1 doz. minimum)%</div><div wdid=\"6\" class=\"wdform_row\">%6 - Quantity%</div><div wdid=\"7\" class=\"wdform_row\">%7 - Details (if any)%</div><div wdid=\"1\" class=\"wdform_row\">%1 - type_submit_reset_1%</div></div></div><div valign=\"top\" class=\"wdform_footer wd-width-100\"><div class=\"wd-width-100\"><div class=\"wd-width-100 wd-table\" style=\"padding-top:10px;\"><div class=\"wd-table-group\"><div id=\"form_id_temppage_nav1\" class=\"wd-table-row\"></div></div></div></div></div></div></div>', '6', '// Occurs before the form is loaded\r\nfunction before_load() { \r\n} \r\n// Occurs just before submitting the form\r\nfunction before_submit() {\r\n // IMPORTANT! If you want to interrupt (stop) the submitting of the form, this function should return true. You don\'t need to return any value if you don\'t want to stop the submission.\r\n} \r\n// Occurs just before resetting the form\r\nfunction before_reset() { \r\n}// Occurs after form is submitted and reloaded\r\nfunction after_submit() {\r\n \r\n}', '', '', '1', '{all}', '{all}', '8', '1', '2#**id**#Name#**label**#type_name#****#3#**id**#Email#**label**#type_submitter_mail#****#4#**id**#Date#**label**#type_date_new#****#5#**id**#Cupcakes Flavors (1 doz. minimum)#**label**#type_radio#****#6#**id**#Quantity#**label**#type_spinner#****#7#**id**#Details (if any)#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#5_elementform_id_temp0#**id**#Name#**label**#type_name#****#5_elementform_id_temp1#**id**#Email#**label**#type_submitter_mail#****#5_elementform_id_temp2#**id**#Date#**label**#type_date_new#****#5_elementform_id_temp3#**id**#Name:* Email:* Date* Cupcakes Flavors (1 doz. minimum)#**label**#type_radio#****#5_elementform_id_temp4#**id**#Quantity#**label**#type_spinner#****#5_elementform_id_temp5#**id**#Details (if any)#**label**#type_textarea#****#5_elementform_id_temp6#**id**#type_submit_reset_1#**label**#type_submit_reset#****#5_elementform_id_temp7#**id**#Name#**label**#type_name#****#5_elementform_id_temp8#**id**#Email#**label**#type_submitter_mail#****#5_elementform_id_temp9#**id**#Date#**label**#type_date_new#****#5_elementform_id_temp10#**id**#type_submit_reset_1#**label**#type_submit_reset#****#5_elementform_id_temp11#**id**#type_submit_reset_1#**label**#type_submit_reset#****#5_elementform_id_temp12#**id**#undefined#**label**#undefined#****#5_elementform_id_temp13#**id**#undefined#**label**#undefined#****#5_elementform_id_temp14#**id**#undefined#**label**#undefined#****#5_elementform_id_temp15#**id**#undefined#**label**#undefined#****#5_elementform_id_temp16#**id**#undefined#**label**#undefined#****#5_elementform_id_temp17#**id**#undefined#**label**#undefined#****#5_elementform_id_temp18#**id**#undefined#**label**#undefined#****#5_elementform_id_temp19#**id**#undefined#**label**#undefined#****#5_elementform_id_temp20#**id**#undefined#**label**#undefined#****#5_elementform_id_temp21#**id**#undefined#**label**#undefined#****#5_elementform_id_temp22#**id**#undefined#**label**#undefined#****#5_elementform_id_temp23#**id**#undefined#**label**#undefined#****#5_elementform_id_temp24#**id**#undefined#**label**#undefined#****#5_elementform_id_temp25#**id**#undefined#**label**#undefined#****#5_elementform_id_temp26#**id**#undefined#**label**#undefined#****#5_elementform_id_temp27#**id**#undefined#**label**#undefined#****#5_elementform_id_temp28#**id**#undefined#**label**#undefined#****#5_elementform_id_temp29#**id**#undefined#**label**#undefined#****#5_elementform_id_temp30#**id**#undefined#**label**#undefined#****#5_elementform_id_temp31#**id**#undefined#**label**#undefined#****#5_elementform_id_temp32#**id**#undefined#**label**#undefined#****#5_elementform_id_temp33#**id**#undefined#**label**#undefined#****#5_elementform_id_temp34#**id**#undefined#**label**#undefined#****#5_elementform_id_temp35#**id**#undefined#**label**#undefined#****#5_elementform_id_temp36#**id**#undefined#**label**#undefined#****#5_elementform_id_temp37#**id**#undefined#**label**#undefined#****#5_elementform_id_temp38#**id**#undefined#**label**#undefined#****#5_elementform_id_temp39#**id**#undefined#**label**#undefined#****#5_elementform_id_temp40#**id**#undefined#**label**#undefined#****#5_elementform_id_temp41#**id**#undefined#**label**#undefined#****#5_elementform_id_temp42#**id**#undefined#**label**#undefined#****#5_elementform_id_temp43#**id**#undefined#**label**#undefined#****#5_elementform_id_temp44#**id**#undefined#**label**#undefined#****#5_elementform_id_temp45#**id**#undefined#**label**#undefined#****#5_elementform_id_temp46#**id**#undefined#**label**#undefined#****#5_elementform_id_temp47#**id**#undefined#**label**#undefined#****#5_elementform_id_temp48#**id**#undefined#**label**#undefined#****#5_elementform_id_temp49#**id**#undefined#**label**#undefined#****#', '2#**id**#Name#**label**#type_name#****#3#**id**#Email#**label**#type_submitter_mail#****#4#**id**#Date#**label**#type_date_new#****#5#**id**#Cupcakes Flavors (1 doz. minimum)#**label**#type_radio#****#6#**id**#Quantity#**label**#type_spinner#****#7#**id**#Details (if any)#**label**#type_textarea#****#1#**id**#type_submit_reset_1#**label**#type_submit_reset#****#', '0', 'none', '', '1', '', '', '', '0', 'testmode', '', '', '0', '2*:*id*:*type_name*:*type*:*Name*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:***********:*w_first_val*:***********:*w_title*:*Title*********Middle*:*w_mini_labels*:**:*w_size*:*normal*:*w_name_format*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no***no*:*w_name_fields*:*no*:*w_autofill*:**:*new_field*:*3*:*id*:*type_submitter_mail*:*type*:*Email*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_first_val*:**:*w_title*:*yes*:*w_required*:*no*:*w_unique*:**:*w_class*:*no*:*w_verification*:*Email confirmation*:*w_verification_label*:**:*w_verification_placeholder*:*no*:*w_autofill*:**:*new_field*:*4*:*id*:*type_date_new*:*type*:*Date*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size*:**:*w_date*:*yes*:*w_required*:*yes*:*w_show_image*:**:*w_class*:*mm/dd/yy*:*w_format*:*0*:*w_start_day*:**:*w_default_date*:**:*w_min_date*:**:*w_max_date*:**:*w_invalid_dates*:*yes***yes***yes***yes***yes***yes***yes*:*w_show_days*:*yes*:*w_hide_time*:*...*:*w_but_val*:*no*:*w_disable_past_days*:**:*new_field*:*5*:*id*:*type_radio*:*type*:*Cupcakes Flavors (1 doz. minimum)*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*right*:*w_field_option_pos*:*no*:*w_hide_label*:*ver*:*w_flow*:*Red Velvet***Vanilla***Chocolate***Guinness***Coconut***Lemon***Chocolate Mint*:*w_choices*:*false***false***false***false***false***false***false*:*w_choices_checked*:*1*:*w_rowcol*:*no*:*w_required*:*no*:*w_randomize*:*no*:*w_allow_other*:*0*:*w_allow_other_num*:*no*:*w_value_disabled*:*Red Velvet***Vanilla***Chocolate***Guinness***Coconut***Lemon***Chocolate Mint*:*w_choices_value*:********************:*w_choices_params*:**:*w_class*:**:*new_field*:*6*:*id*:*type_spinner*:*type*:*Quantity*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:*60*:*w_field_width*:**:*w_field_min_value*:**:*w_field_max_value*:*1*:*w_field_step*:*null*:*w_field_value*:*no*:*w_required*:**:*w_class*:**:*new_field*:*7*:*id*:*type_textarea*:*type*:*Details (if any)*:*w_field_label*:**:*w_field_label_size*:*top*:*w_field_label_pos*:*no*:*w_hide_label*:**:*w_size_w*:*100*:*w_size_h*:**:*w_first_val*:**:*w_title*:*no*:*w_required*:*no*:*w_unique*:**:*w_class*:**:*new_field*:*1*:*id*:*type_submit_reset*:*type*:*type_submit_reset_1*:*w_field_label*:*Submit*:*w_submit_title*:*Reset*:*w_reset_title*:**:*w_class*:*false*:*w_act*:**:*new_field*:*', '1', '1', '*', '', '', '', '', '1', '', '', '', '', '', '', '', '', '', '', '', '1', '1', '1', '1', 'administrator,', '1', '', '', '0', '0', '0', '0', '1', 'Cupcake Order Form', '', '', 'none', '1', '0');");
|
308 |
$insert_form_id[] = $wpdb->insert_id;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
309 |
}
|
310 |
else {
|
311 |
update_option('contact_form_forms', implode(',', $insert_form_id));
|
form_maker_update.php
CHANGED
@@ -239,6 +239,21 @@ class WDCFMUpdate {
|
|
239 |
if (version_compare($version, '1.12.12') == -1) {
|
240 |
$wpdb->query("ALTER TABLE `" . $wpdb->prefix . "formmaker` CHANGE `mail` `mail` longtext NOT NULL");
|
241 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
242 |
return;
|
243 |
}
|
244 |
}
|
239 |
if (version_compare($version, '1.12.12') == -1) {
|
240 |
$wpdb->query("ALTER TABLE `" . $wpdb->prefix . "formmaker` CHANGE `mail` `mail` longtext NOT NULL");
|
241 |
}
|
242 |
+
if (version_compare($version, '1.12.21') == -1) {
|
243 |
+
$wpdb->query("ALTER TABLE `" . $wpdb->prefix . "formmaker` CHANGE `label_order` `label_order` longtext NOT NULL");
|
244 |
+
$wpdb->query("ALTER TABLE `" . $wpdb->prefix . "formmaker` CHANGE `label_order_current` `label_order_current` longtext NOT NULL");
|
245 |
+
$wpdb->query("ALTER TABLE `" . $wpdb->prefix . "formmaker_backup` CHANGE `label_order` `label_order` longtext NOT NULL");
|
246 |
+
$wpdb->query("ALTER TABLE `" . $wpdb->prefix . "formmaker_backup` CHANGE `label_order_current` `label_order_current` longtext NOT NULL");
|
247 |
+
}
|
248 |
+
if (version_compare($version, '1.12.22') == -1) {
|
249 |
+
$group_id = $wpdb->get_var( 'SELECT MAX( group_id ) FROM ' . $wpdb->prefix . 'formmaker_submits' );
|
250 |
+
$group_id++;
|
251 |
+
$formmaker_groups = "CREATE TABLE IF NOT EXISTS `" . $wpdb->prefix . "formmaker_groups` (
|
252 |
+
`id` int(11) NOT NULL AUTO_INCREMENT,
|
253 |
+
PRIMARY KEY (`id`)
|
254 |
+
) DEFAULT CHARSET=utf8 AUTO_INCREMENT=" . $group_id;
|
255 |
+
$wpdb->query($formmaker_groups);
|
256 |
+
}
|
257 |
return;
|
258 |
}
|
259 |
}
|
framework/WDW_FM_Library.php
CHANGED
@@ -1,6 +1,31 @@
|
|
1 |
<?php
|
2 |
|
3 |
class WDW_FMC_Library {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
4 |
public static $qpKeys = array(
|
5 |
"\x00",
|
6 |
"\x01",
|
@@ -518,7 +543,7 @@ class WDW_FMC_Library {
|
|
518 |
?>
|
519 |
<th id="<?php echo $id; ?>" class="<?php echo implode(' ', $class); ?>">
|
520 |
<a href="<?php echo add_query_arg( array('orderby' => $id, 'order' => $order), $page_url ); ?>"
|
521 |
-
title="<?php _e('Click to sort by this item',
|
522 |
<span><?php echo $text; ?></span><span class="sorting-indicator"></span>
|
523 |
</a>
|
524 |
</th>
|
@@ -838,7 +863,7 @@ class WDW_FMC_Library {
|
|
838 |
}
|
839 |
|
840 |
public static function fm_redirect($url) {
|
841 |
-
$url = html_entity_decode(wp_nonce_url($url,
|
842 |
?>
|
843 |
<script>
|
844 |
window.location = "<?php echo $url; ?>";
|
@@ -858,6 +883,7 @@ class WDW_FMC_Library {
|
|
858 |
if ( strstr($str, '"') ) {
|
859 |
$str = '"' . str_replace('"', '""', $str) . '"';
|
860 |
}
|
|
|
861 |
}
|
862 |
|
863 |
/**
|
@@ -912,11 +938,11 @@ class WDW_FMC_Library {
|
|
912 |
$frontend_dir = '/form-maker-frontend/';
|
913 |
if ( !is_dir($wp_upload_dir['basedir'] . $frontend_dir) ) {
|
914 |
mkdir($wp_upload_dir['basedir'] . $frontend_dir);
|
915 |
-
file_put_contents($wp_upload_dir['basedir'] . $frontend_dir . 'index.html',
|
916 |
}
|
917 |
if ( !is_dir($wp_upload_dir['basedir'] . $frontend_dir . 'js') ) {
|
918 |
mkdir($wp_upload_dir['basedir'] . $frontend_dir . 'js');
|
919 |
-
file_put_contents($wp_upload_dir['basedir'] . $frontend_dir . 'js/index.html',
|
920 |
}
|
921 |
$frontend_js = $wp_upload_dir['basedir'] . $frontend_dir . 'js/fm-script-' . $form_id . '.js';
|
922 |
if ( !$force_rewrite && file_exists($frontend_js) ) {
|
@@ -932,68 +958,17 @@ class WDW_FMC_Library {
|
|
932 |
$jsfile = fopen($frontend_js, "w");
|
933 |
$pattern = '/\/\/(.+)(\r\n|\r|\n)/';
|
934 |
|
935 |
-
$row_display =
|
936 |
$row->javascript = str_replace('function before_reset()', 'function before_reset' . $form_id . '()', $row->javascript);
|
937 |
$row->javascript = str_replace('function before_load()', 'function before_load' . $form_id . '()', $row->javascript);
|
938 |
$row->javascript = str_replace('function before_submit()', 'function before_submit' . $form_id . '()', $row->javascript);
|
|
|
939 |
$check_js = '';
|
940 |
-
$onsubmit_js = '';
|
941 |
$onload_js = '';
|
942 |
-
$
|
943 |
-
|
944 |
-
'EUR',
|
945 |
-
'GBP',
|
946 |
-
'JPY',
|
947 |
-
'CAD',
|
948 |
-
'MXN',
|
949 |
-
'HKD',
|
950 |
-
'HUF',
|
951 |
-
'NOK',
|
952 |
-
'NZD',
|
953 |
-
'SGD',
|
954 |
-
'SEK',
|
955 |
-
'PLN',
|
956 |
-
'AUD',
|
957 |
-
'DKK',
|
958 |
-
'CHF',
|
959 |
-
'CZK',
|
960 |
-
'ILS',
|
961 |
-
'BRL',
|
962 |
-
'TWD',
|
963 |
-
'MYR',
|
964 |
-
'PHP',
|
965 |
-
'THB',
|
966 |
-
);
|
967 |
-
$currency_sign = array(
|
968 |
-
'$',
|
969 |
-
'€',
|
970 |
-
'£',
|
971 |
-
'¥',
|
972 |
-
'C$',
|
973 |
-
'Mex$',
|
974 |
-
'HK$',
|
975 |
-
'Ft',
|
976 |
-
'kr',
|
977 |
-
'NZ$',
|
978 |
-
'S$',
|
979 |
-
'kr',
|
980 |
-
'zl',
|
981 |
-
'A$',
|
982 |
-
'kr',
|
983 |
-
'CHF',
|
984 |
-
'Kc',
|
985 |
-
'₪',
|
986 |
-
'R$',
|
987 |
-
'NT$',
|
988 |
-
'RM',
|
989 |
-
'₱',
|
990 |
-
'฿',
|
991 |
-
);
|
992 |
if ( $row->payment_currency ) {
|
993 |
-
$form_currency =
|
994 |
-
}
|
995 |
-
else {
|
996 |
-
$form_currency = '';
|
997 |
}
|
998 |
$form_paypal_tax = $row->tax;
|
999 |
$stripe_enable = 0;
|
@@ -2579,7 +2554,7 @@ class WDW_FMC_Library {
|
|
2579 |
if ( $disable_past_days == 'true' ) {
|
2580 |
$check_js .= '
|
2581 |
if( Date.parse(jQuery("#wdform_' . $id1 . '_element' . $form_id . '").val() + " 23:59:59") < fm_currentDate.getTime() ) {
|
2582 |
-
alert("' . __('You cannot select former dates. Choose a date starting from the current one.',
|
2583 |
return false;
|
2584 |
}';
|
2585 |
}
|
@@ -2991,7 +2966,7 @@ class WDW_FMC_Library {
|
|
2991 |
array_push($req_fields, $id1);
|
2992 |
}
|
2993 |
$file_upload_check[$id1] = $param['w_extension'];
|
2994 |
-
if (
|
2995 |
$onsubmit_js .= 'alert( "You can\'t upload file in demo.");';
|
2996 |
}
|
2997 |
break;
|
@@ -3157,7 +3132,7 @@ class WDW_FMC_Library {
|
|
3157 |
$check_js .= '
|
3158 |
if(x.find(jQuery("div[wdid=' . $id1 . ']")).length != 0 && x.find(jQuery("div[wdid=' . $id1 . ']")).css("display") != "none") {
|
3159 |
if(jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").val() == "' . $w_title[0] . '" || jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").val() == "") {
|
3160 |
-
alert("' . addslashes($label . ' ' . __('field is required.',
|
3161 |
old_bg=x.find(jQuery("div[wdid=' . $id1 . ']")).css("background-color");
|
3162 |
x.find(jQuery("div[wdid=' . $id1 . ']")).effect( "shake", {}, 500 ).css("background-color","#FF8F8B").animate({backgroundColor: old_bg}, {duration: 500, queue: false });
|
3163 |
jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").focus();
|
@@ -3187,7 +3162,7 @@ class WDW_FMC_Library {
|
|
3187 |
var range_max=' . ($param['w_range_max'] ? $param['w_range_max'] : -1) . ';
|
3188 |
if(' . ($required ? 'true' : 'false') . ' || jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").val() != "' . $w_title[0] . '" || jQuery("#wdform_' . $id1 . '_element_cents' . $form_id . '").val() != "' . $w_title[1] . '") {
|
3189 |
if((range_max!=-1 && parseFloat(price)>range_max) || parseFloat(price)<range_min) {
|
3190 |
-
alert("' . addslashes((__('The',
|
3191 |
old_bg=x.find(jQuery("div[wdid=' . $id1 . ']")).css("background-color");
|
3192 |
x.find(jQuery("div[wdid=' . $id1 . ']")).effect( "shake", {}, 500 ).css("background-color","#FF8F8B").animate({backgroundColor: old_bg}, {duration: 500, queue: false });
|
3193 |
jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").focus();
|
@@ -3313,7 +3288,7 @@ class WDW_FMC_Library {
|
|
3313 |
$onsubmit_js .= '
|
3314 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_label' . $form_id . '\" />").val(jQuery("#wdform_' . $id1 . '_element' . $form_id . ' option:selected").text()).appendTo("#form' . $form_id . '");';
|
3315 |
$onsubmit_js .= '
|
3316 |
-
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_quantity_label' . $form_id . '\" />").val("' . (__("Quantity",
|
3317 |
foreach ( $param['w_property'] as $key => $property ) {
|
3318 |
$onsubmit_js .= '
|
3319 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_property_label' . $form_id . $key . '\" />").val("' . $property . '").appendTo("#form' . $form_id . '");';
|
@@ -3395,7 +3370,7 @@ class WDW_FMC_Library {
|
|
3395 |
$onsubmit_js .= '
|
3396 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_label' . $form_id . '\" />").val((jQuery("#wdform_' . $id1 . '_element' . $form_id . ' input:checked").length != 0) ? jQuery("#wdform_' . $id1 . '_element' . $form_id . ' input:checked").attr("id").replace("element", "elementlabel_") : "").appendTo("#form' . $form_id . '");';
|
3397 |
$onsubmit_js .= '
|
3398 |
-
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_quantity_label' . $form_id . '\" />").val("' . (__("Quantity",
|
3399 |
foreach ( $param['w_property'] as $key => $property ) {
|
3400 |
$onsubmit_js .= '
|
3401 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_property_label' . $form_id . $key . '\" />").val("' . $property . '").appendTo("#form' . $form_id . '");';
|
@@ -3477,7 +3452,7 @@ class WDW_FMC_Library {
|
|
3477 |
$onsubmit_js .= '
|
3478 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_label' . $form_id . '\" />").val(jQuery("label[for=\'"+jQuery("input[name^=\'wdform_' . $id1 . '_element' . $form_id . '\']:checked").attr("id")+"\']").eq(0).text()).appendTo("#form' . $form_id . '");';
|
3479 |
$onsubmit_js .= '
|
3480 |
-
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_quantity_label' . $form_id . '\" />").val("' . (__("Quantity",
|
3481 |
foreach ( $param['w_property'] as $key => $property ) {
|
3482 |
$onsubmit_js .= '
|
3483 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_property_label' . $form_id . $key . '\" />").val("' . $property . '").appendTo("#form' . $form_id . '");';
|
@@ -3664,7 +3639,7 @@ class WDW_FMC_Library {
|
|
3664 |
$onload_js .= '
|
3665 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '")[0].spin = null;
|
3666 |
spinner = jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner();
|
3667 |
-
if ("' . $param['w_field_value'] . '" == "null") { spinner.spinner("value", ""); }
|
3668 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ min: "' . $param['w_field_min_value'] . '"});
|
3669 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ max: "' . $param['w_field_max_value'] . '"});
|
3670 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ step: "' . $param['w_field_step'] . '"});';
|
@@ -3759,10 +3734,10 @@ class WDW_FMC_Library {
|
|
3759 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '0")[0].spin = null;
|
3760 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '1")[0].spin = null;
|
3761 |
spinner0 = jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '0").spinner();
|
3762 |
-
if ("' . $param['w_field_value1'] . '" == "null") { spinner0.spinner("value", ""); }
|
3763 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ step: ' . $param['w_field_range_step'] . '});
|
3764 |
spinner1 = jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '1").spinner();
|
3765 |
-
if ("' . $param['w_field_value2'] . '" == "null") { spinner1.spinner("value", ""); }
|
3766 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ step: ' . $param['w_field_range_step'] . '});';
|
3767 |
if ( $required ) {
|
3768 |
array_push($req_fields, $id1);
|
@@ -3814,7 +3789,7 @@ class WDW_FMC_Library {
|
|
3814 |
var isAllowdedSubmit = true;
|
3815 |
if(x.find(jQuery("div[wdid=' . $id1 . ']")).length != 0 && x.find(jQuery("div[wdid=' . $id1 . ']")).css("display") != "none") {
|
3816 |
if(parseInt(jQuery("#wdform_' . $id1 . '_sum_element' . $form_id . '").html()) > ' . $param['w_total'] . ') {
|
3817 |
-
alert("' . addslashes(__("Your score should be less than",
|
3818 |
return false;
|
3819 |
}
|
3820 |
}';
|
@@ -3930,7 +3905,7 @@ class WDW_FMC_Library {
|
|
3930 |
});
|
3931 |
<?php
|
3932 |
$js_content = ob_get_clean();
|
3933 |
-
|
3934 |
fwrite($jsfile, $js_content);
|
3935 |
fclose($jsfile);
|
3936 |
clearstatcache();
|
@@ -3948,7 +3923,7 @@ class WDW_FMC_Library {
|
|
3948 |
$group_id_s = array();
|
3949 |
$form_id = (int) $_REQUEST['form_id'];
|
3950 |
$limitstart = (int) $_REQUEST['limitstart'];
|
3951 |
-
$search_labels =
|
3952 |
$verified_emails = isset($_REQUEST['verified_emails']) ? json_decode(stripslashes($_REQUEST['verified_emails']), TRUE) : array();
|
3953 |
$paypal_info_fields = array(
|
3954 |
'currency',
|
@@ -4230,7 +4205,7 @@ class WDW_FMC_Library {
|
|
4230 |
$title = ($title != '') ? strtolower($title) : 'items';
|
4231 |
ob_start();
|
4232 |
?><tr class="no-items">
|
4233 |
-
<td class="colspanchange" colspan="0"><?php echo sprintf(__('No %s found.',
|
4234 |
</tr><?php
|
4235 |
return ob_get_clean();
|
4236 |
}
|
@@ -4275,7 +4250,7 @@ class WDW_FMC_Library {
|
|
4275 |
*/
|
4276 |
public static function deactivate_all_addons() {
|
4277 |
include_once( ABSPATH . 'wp-admin/includes/plugin.php' );
|
4278 |
-
$addons =
|
4279 |
foreach ( $addons as $addon ) {
|
4280 |
if( is_plugin_active( $addon ) ) {
|
4281 |
deactivate_plugins( $addon );
|
@@ -4291,203 +4266,203 @@ class WDW_FMC_Library {
|
|
4291 |
public static function get_countries() {
|
4292 |
$countries = array(
|
4293 |
"" => "",
|
4294 |
-
"Afghanistan" => __("Afghanistan",
|
4295 |
-
"Albania" => __("Albania",
|
4296 |
-
"Algeria" => __("Algeria",
|
4297 |
-
"Andorra" => __("Andorra",
|
4298 |
-
"Angola" => __("Angola",
|
4299 |
-
"Antigua and Barbuda" => __("Antigua and Barbuda",
|
4300 |
-
"Argentina" => __("Argentina",
|
4301 |
-
"Armenia" => __("Armenia",
|
4302 |
-
"Australia" => __("Australia",
|
4303 |
-
"Austria" => __("Austria",
|
4304 |
-
"Azerbaijan" => __("Azerbaijan",
|
4305 |
-
"Bahamas" => __("Bahamas",
|
4306 |
-
"Bahrain" => __("Bahrain",
|
4307 |
-
"Bangladesh" => __("Bangladesh",
|
4308 |
-
"Barbados" => __("Barbados",
|
4309 |
-
"Belarus" => __("Belarus",
|
4310 |
-
"Belgium" => __("Belgium",
|
4311 |
-
"Belize" => __("Belize",
|
4312 |
-
"Benin" => __("Benin",
|
4313 |
-
"Bhutan" => __("Bhutan",
|
4314 |
-
"Bolivia" => __("Bolivia",
|
4315 |
-
"Bosnia and Herzegovina" => __("Bosnia and Herzegovina",
|
4316 |
-
"Botswana" => __("Botswana",
|
4317 |
-
"Brazil" => __("Brazil",
|
4318 |
-
"Brunei" => __("Brunei",
|
4319 |
-
"Bulgaria" => __("Bulgaria",
|
4320 |
-
"Burkina" => __("Burkina Faso",
|
4321 |
-
"Burundi" => __("Burundi",
|
4322 |
-
"Cambodia" => __("Cambodia",
|
4323 |
-
"Cameroon" => __("Cameroon",
|
4324 |
-
"Canada" => __("Canada",
|
4325 |
-
"Cape Verde" => __("Cape Verde",
|
4326 |
-
"Central African Republic" => __("Central African Republic",
|
4327 |
-
"Chad" => __("Chad",
|
4328 |
-
"Chile" => __("Chile",
|
4329 |
-
"China" => __("China",
|
4330 |
-
"Colombia" => __("Colombia",
|
4331 |
-
"Comoros" => __("Comoros",
|
4332 |
-
"Congo (Brazzaville)" => __("Congo (Brazzaville)",
|
4333 |
-
"Congo" => __("Congo",
|
4334 |
-
"Costa Rica" => __("Costa Rica",
|
4335 |
-
"Cote d'Ivoire" => __("Cote d'Ivoire",
|
4336 |
-
"Croatia" => __("Croatia",
|
4337 |
-
"Cuba" => __("Cuba",
|
4338 |
-
"Curacao" => __("Curacao",
|
4339 |
-
"Cyprus" => __("Cyprus",
|
4340 |
-
"Czech Republic" => __("Czech Republic",
|
4341 |
-
"Denmark" => __("Denmark",
|
4342 |
-
"Djibouti" => __("Djibouti",
|
4343 |
-
"Dominica" => __("Dominica",
|
4344 |
-
"Dominican Republic" => __("Dominican Republic",
|
4345 |
-
"East Timor (Timor Timur" => __("East Timor (Timor Timur)",
|
4346 |
-
"Ecuador" => __("Ecuador",
|
4347 |
-
"Egypt" => __("Egypt",
|
4348 |
-
"El Salvador" => __("El Salvador",
|
4349 |
-
"Equatorial" => __("Equatorial Guinea",
|
4350 |
-
"Eritrea" => __("Eritrea",
|
4351 |
-
"Estonia" => __("Estonia",
|
4352 |
-
"Ethiopia" => __("Ethiopia",
|
4353 |
-
"Fiji" => __("Fiji",
|
4354 |
-
"Finland" => __("Finland",
|
4355 |
-
"France" => __("France",
|
4356 |
-
"Gabon" => __("Gabon",
|
4357 |
-
"Gambia, The" => __("Gambia, The",
|
4358 |
-
"Georgia" => __("Georgia",
|
4359 |
-
"Germany" => __("Germany",
|
4360 |
-
"Ghana" => __("Ghana",
|
4361 |
-
"Greece" => __("Greece",
|
4362 |
-
"Grenada" => __("Grenada",
|
4363 |
-
"Guatemala" => __("Guatemala",
|
4364 |
-
"Guinea" => __("Guinea",
|
4365 |
-
"Guinea-Bissau" => __("Guinea-Bissau",
|
4366 |
-
"Guyana" => __("Guyana",
|
4367 |
-
"Haiti" => __("Haiti",
|
4368 |
-
"Honduras" => __("Honduras",
|
4369 |
-
"Hong Kong" => __("Hong Kong",
|
4370 |
-
"Hungary" => __("Hungary",
|
4371 |
-
"Iceland" => __("Iceland",
|
4372 |
-
"India" => __("India",
|
4373 |
-
"Indonesia" => __("Indonesia",
|
4374 |
-
"Iran" => __("Iran",
|
4375 |
-
"Iraq" => __("Iraq",
|
4376 |
-
"Ireland" => __("Ireland",
|
4377 |
-
"Israel" => __("Israel",
|
4378 |
-
"Italy" => __("Italy",
|
4379 |
-
"Jamaica" => __("Jamaica",
|
4380 |
-
"Japan" => __("Japan",
|
4381 |
-
"Jordan" => __("Jordan",
|
4382 |
-
"Kazakhstan" => __("Kazakhstan",
|
4383 |
-
"Kenya" => __("Kenya",
|
4384 |
-
"Kiribati" => __("Kiribati",
|
4385 |
-
"Korea, North" => __("Korea, North",
|
4386 |
-
"Korea, South" => __("Korea, South",
|
4387 |
-
"Kuwait" => __("Kuwait",
|
4388 |
-
"Kyrgyzstan" => __("Kyrgyzstan",
|
4389 |
-
"Laos" => __("Laos",
|
4390 |
-
"Latvia" => __("Latvia",
|
4391 |
-
"Lebanon" => __("Lebanon",
|
4392 |
-
"Lesotho" => __("Lesotho",
|
4393 |
-
"Liberia" => __("Liberia",
|
4394 |
-
"Libya" => __("Libya",
|
4395 |
-
"Liechtenstein" => __("Liechtenstein",
|
4396 |
-
"Lithuania" => __("Lithuania",
|
4397 |
-
"Luxembourg" => __("Luxembourg",
|
4398 |
-
"Macedonia" => __("Macedonia",
|
4399 |
-
"Madagascar" => __("Madagascar",
|
4400 |
-
"Malawi" => __("Malawi",
|
4401 |
-
"Malaysia" => __("Malaysia",
|
4402 |
-
"Maldives" => __("Maldives",
|
4403 |
-
"Mali" => __("Mali",
|
4404 |
-
"Malta" => __("Malta",
|
4405 |
-
"Marshall Islands" => __("Marshall Islands",
|
4406 |
-
"Mauritania" => __("Mauritania",
|
4407 |
-
"Mauritius" => __("Mauritius",
|
4408 |
-
"Mexico" => __("Mexico",
|
4409 |
-
"Micronesia" => __("Micronesia",
|
4410 |
-
"Moldova" => __("Moldova",
|
4411 |
-
"Monaco" => __("Monaco",
|
4412 |
-
"Mongolia" => __("Mongolia",
|
4413 |
-
"Morocco" => __("Morocco",
|
4414 |
-
"Mozambique" => __("Mozambique",
|
4415 |
-
"Myanmar" => __("Myanmar",
|
4416 |
-
"Namibia" => __("Namibia",
|
4417 |
-
"Nauru" => __("Nauru",
|
4418 |
-
"Nepal" => __("Nepal",
|
4419 |
-
"Netherlands" => __("Netherlands",
|
4420 |
-
"New Zealand" => __("New Zealand",
|
4421 |
-
"Nicaragua" => __("Nicaragua",
|
4422 |
-
"Niger" => __("Niger",
|
4423 |
-
"Nigeria" => __("Nigeria",
|
4424 |
-
"Norway" => __("Norway",
|
4425 |
-
"Oman" => __("Oman",
|
4426 |
-
"Pakistan" => __("Pakistan",
|
4427 |
-
"Palau" => __("Palau",
|
4428 |
-
"Panama" => __("Panama",
|
4429 |
-
"Papua New Guinea" => __("Papua New Guinea",
|
4430 |
-
"Paraguay" => __("Paraguay",
|
4431 |
-
"Peru" => __("Peru",
|
4432 |
-
"Philippines" => __("Philippines",
|
4433 |
-
"Poland" => __("Poland",
|
4434 |
-
"Portugal" => __("Portugal",
|
4435 |
-
"Puerto Rico" => __("Puerto Rico",
|
4436 |
-
"Qatar" => __("Qatar",
|
4437 |
-
"Romania" => __("Romania",
|
4438 |
-
"Russia" => __("Russia",
|
4439 |
-
"Rwanda" => __("Rwanda",
|
4440 |
-
"Saint Kitts and Nevis" => __("Saint Kitts and Nevis",
|
4441 |
-
"Saint Lucia" => __("Saint Lucia",
|
4442 |
-
"Saint Vincent" => __("Saint Vincent",
|
4443 |
-
"Samoa" => __("Samoa",
|
4444 |
-
"San Marino" => __("San Marino",
|
4445 |
-
"Sao Tome and Principe" => __("Sao Tome and Principe",
|
4446 |
-
"Saudi Arabia" => __("Saudi Arabia",
|
4447 |
-
"Senegal" => __("Senegal",
|
4448 |
-
"Serbia and Montenegro" => __("Serbia and Montenegro",
|
4449 |
-
"Seychelles" => __("Seychelles",
|
4450 |
-
"Sierra Leone" => __("Sierra Leone",
|
4451 |
-
"Singapore" => __("Singapore",
|
4452 |
-
"Slovakia" => __("Slovakia",
|
4453 |
-
"Slovenia" => __("Slovenia",
|
4454 |
-
"Solomon Islands" => __("Solomon Islands",
|
4455 |
-
"Somalia" => __("Somalia",
|
4456 |
-
"South Africa" => __("South Africa",
|
4457 |
-
"Spain" => __("Spain",
|
4458 |
-
"Sri Lanka" => __("Sri Lanka",
|
4459 |
-
"Sudan" => __("Sudan",
|
4460 |
-
"Suriname" => __("Suriname",
|
4461 |
-
"Swaziland" => __("Swaziland",
|
4462 |
-
"Sweden" => __("Sweden",
|
4463 |
-
"Switzerland" => __("Switzerland",
|
4464 |
-
"Syria" => __("Syria",
|
4465 |
-
"Taiwan" => __("Taiwan",
|
4466 |
-
"Tajikistan" => __("Tajikistan",
|
4467 |
-
"Tanzania" => __("Tanzania",
|
4468 |
-
"Thailand" => __("Thailand",
|
4469 |
-
"Togo" => __("Togo",
|
4470 |
-
"Tonga" => __("Tonga",
|
4471 |
-
"Trinidad and Tobago" => __("Trinidad and Tobago",
|
4472 |
-
"Tunisia" => __("Tunisia",
|
4473 |
-
"Turkey" => __("Turkey",
|
4474 |
-
"Turkmenistan" => __("Turkmenistan",
|
4475 |
-
"Tuvalu" => __("Tuvalu",
|
4476 |
-
"Uganda" => __("Uganda",
|
4477 |
-
"Ukraine" => __("Ukraine",
|
4478 |
-
"United Arab Emirates" => __("United Arab Emirates",
|
4479 |
-
"United Kingdom" => __("United Kingdom",
|
4480 |
-
"United States" => __("United States",
|
4481 |
-
"Uruguay" => __("Uruguay",
|
4482 |
-
"Uzbekistan" => __("Uzbekistan",
|
4483 |
-
"Vanuatu" => __("Vanuatu",
|
4484 |
-
"Vatican City" => __("Vatican City",
|
4485 |
-
"Venezuela" => __("Venezuela",
|
4486 |
-
"Vietnam" => __("Vietnam",
|
4487 |
-
"Wales" => __("Wales",
|
4488 |
-
"Yemen" => __("Yemen",
|
4489 |
-
"Zambia" => __("Zambia",
|
4490 |
-
"Zimbabwe" => __("Zimbabwe",
|
4491 |
);
|
4492 |
|
4493 |
return $countries;
|
@@ -4501,57 +4476,57 @@ class WDW_FMC_Library {
|
|
4501 |
public static function get_states() {
|
4502 |
$states = array(
|
4503 |
"" => "",
|
4504 |
-
"Alabama" => __("Alabama",
|
4505 |
-
"Alaska" => __("Alaska",
|
4506 |
-
"Arizona" => __("Arizona",
|
4507 |
-
"Arkansas" => __("Arkansas",
|
4508 |
-
"California" => __("California",
|
4509 |
-
"Colorado" => __("Colorado",
|
4510 |
-
"Connecticut" => __("Connecticut",
|
4511 |
-
"Delaware" => __("Delaware",
|
4512 |
-
"District Of Columbia" => __("District Of Columbia",
|
4513 |
-
"Florida" => __("Florida",
|
4514 |
-
"Georgia" => __("Georgia",
|
4515 |
-
"Hawaii" => __("Hawaii",
|
4516 |
-
"Idaho" => __("Idaho",
|
4517 |
-
"Illinois" => __("Illinois",
|
4518 |
-
"Indiana" => __("Indiana",
|
4519 |
-
"Iowa" => __("Iowa",
|
4520 |
-
"Kansas" => __("Kansas",
|
4521 |
-
"Kentucky" => __("Kentucky",
|
4522 |
-
"Louisiana" => __("Louisiana",
|
4523 |
-
"Maine" => __("Maine",
|
4524 |
-
"Maryland" => __("Maryland",
|
4525 |
-
"Massachusetts" => __("Massachusetts",
|
4526 |
-
"Michigan" => __("Michigan",
|
4527 |
-
"Minnesota" => __("Minnesota",
|
4528 |
-
"Mississippi" => __("Mississippi",
|
4529 |
-
"Missouri" => __("Missouri",
|
4530 |
-
"Montana" => __("Montana",
|
4531 |
-
"Nebraska" => __("Nebraska",
|
4532 |
-
"Nevada" => __("Nevada",
|
4533 |
-
"New Hampshire" => __("New Hampshire",
|
4534 |
-
"New Jersey" => __("New Jersey",
|
4535 |
-
"New Mexico" => __("New Mexico",
|
4536 |
-
"New York" => __("New York",
|
4537 |
-
"North Carolina" => __("North Carolina",
|
4538 |
-
"North Dakota" => __("North Dakota",
|
4539 |
-
"Ohio" => __("Ohio",
|
4540 |
-
"Oklahoma" => __("Oklahoma",
|
4541 |
-
"Oregon" => __("Oregon",
|
4542 |
-
"Pennsylvania" => __("Pennsylvania",
|
4543 |
-
"Rhode Island" => __("Rhode Island",
|
4544 |
-
"South Carolina" => __("South Carolina",
|
4545 |
-
"South Dakota" => __("South Dakota",
|
4546 |
-
"Tennessee" => __("Tennessee",
|
4547 |
-
"Texas" => __("Texas",
|
4548 |
-
"Utah" => __("Utah",
|
4549 |
-
"Vermont" => __("Vermont",
|
4550 |
-
"Virginia" => __("Virginia",
|
4551 |
-
"Washington" => __("Washington",
|
4552 |
-
"West Virginia" => __("West Virginia",
|
4553 |
-
"Wisconsin" => __("Wisconsin",
|
4554 |
-
"Wyoming" => __("Wyoming",
|
4555 |
);
|
4556 |
|
4557 |
return $states;
|
@@ -4565,15 +4540,15 @@ class WDW_FMC_Library {
|
|
4565 |
public static function localize_ui_datepicker() {
|
4566 |
return 'jQuery(document).ready(function(jQuery){
|
4567 |
jQuery.datepicker.setDefaults( {
|
4568 |
-
"closeText":"' . __('Done',
|
4569 |
-
"prevText":"' . __('Prev',
|
4570 |
-
"nextText":"' . __('Next',
|
4571 |
-
"currentText":"' . __('Today',
|
4572 |
-
"monthNames":["' . __('January',
|
4573 |
-
"monthNamesShort":["' . __('Jan',
|
4574 |
-
"dayNames":["' . __('Sunday',
|
4575 |
-
"dayNamesShort":["' . __('Sun',
|
4576 |
-
"dayNamesMin":["' . __('Su',
|
4577 |
});
|
4578 |
})';
|
4579 |
}
|
@@ -4697,6 +4672,7 @@ class WDW_FMC_Library {
|
|
4697 |
|
4698 |
return $sent;
|
4699 |
}
|
|
|
4700 |
public static $email_content_type;
|
4701 |
public static $email_charset;
|
4702 |
public static $email_from;
|
@@ -4704,9 +4680,11 @@ class WDW_FMC_Library {
|
|
4704 |
public static function mail_content_type() {
|
4705 |
return self::$email_content_type;
|
4706 |
}
|
|
|
4707 |
public static function mail_charset() {
|
4708 |
return self::$email_charset;
|
4709 |
}
|
|
|
4710 |
public static function mail_from() {
|
4711 |
return self::$email_from;
|
4712 |
}
|
@@ -5040,7 +5018,81 @@ class WDW_FMC_Library {
|
|
5040 |
public static function decodeQuotedPrintable( $string ) {
|
5041 |
return quoted_printable_decode($string);
|
5042 |
}
|
5043 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5044 |
/**
|
5045 |
* Session start if not started.
|
5046 |
*/
|
1 |
<?php
|
2 |
|
3 |
class WDW_FMC_Library {
|
4 |
+
/**
|
5 |
+
* PLUGIN = 2 points to Contact Form Maker
|
6 |
+
*/
|
7 |
+
const PLUGIN = 2;
|
8 |
+
|
9 |
+
/**
|
10 |
+
* The single instance of the class.
|
11 |
+
*/
|
12 |
+
protected static $_instance = null;
|
13 |
+
|
14 |
+
/**
|
15 |
+
* Main WDW_FM_Library Instance.
|
16 |
+
*
|
17 |
+
* Ensures only one instance is loaded or can be loaded.
|
18 |
+
*
|
19 |
+
* @static
|
20 |
+
* @return WDW_FM_Library - Main instance.
|
21 |
+
*/
|
22 |
+
public static function instance() {
|
23 |
+
if ( is_null( self::$_instance ) ) {
|
24 |
+
self::$_instance = new self();
|
25 |
+
}
|
26 |
+
return self::$_instance;
|
27 |
+
}
|
28 |
+
|
29 |
public static $qpKeys = array(
|
30 |
"\x00",
|
31 |
"\x01",
|
543 |
?>
|
544 |
<th id="<?php echo $id; ?>" class="<?php echo implode(' ', $class); ?>">
|
545 |
<a href="<?php echo add_query_arg( array('orderby' => $id, 'order' => $order), $page_url ); ?>"
|
546 |
+
title="<?php _e('Click to sort by this item', WDFMInstance(self::PLUGIN)->prefix); ?>">
|
547 |
<span><?php echo $text; ?></span><span class="sorting-indicator"></span>
|
548 |
</a>
|
549 |
</th>
|
863 |
}
|
864 |
|
865 |
public static function fm_redirect($url) {
|
866 |
+
$url = html_entity_decode(wp_nonce_url($url, WDFMInstance(self::PLUGIN)->nonce, WDFMInstance(self::PLUGIN)->nonce));
|
867 |
?>
|
868 |
<script>
|
869 |
window.location = "<?php echo $url; ?>";
|
883 |
if ( strstr($str, '"') ) {
|
884 |
$str = '"' . str_replace('"', '""', $str) . '"';
|
885 |
}
|
886 |
+
$str = ltrim($str, '=+-@');
|
887 |
}
|
888 |
|
889 |
/**
|
938 |
$frontend_dir = '/form-maker-frontend/';
|
939 |
if ( !is_dir($wp_upload_dir['basedir'] . $frontend_dir) ) {
|
940 |
mkdir($wp_upload_dir['basedir'] . $frontend_dir);
|
941 |
+
file_put_contents($wp_upload_dir['basedir'] . $frontend_dir . 'index.html', self::forbidden_template());
|
942 |
}
|
943 |
if ( !is_dir($wp_upload_dir['basedir'] . $frontend_dir . 'js') ) {
|
944 |
mkdir($wp_upload_dir['basedir'] . $frontend_dir . 'js');
|
945 |
+
file_put_contents($wp_upload_dir['basedir'] . $frontend_dir . 'js/index.html', self::forbidden_template());
|
946 |
}
|
947 |
$frontend_js = $wp_upload_dir['basedir'] . $frontend_dir . 'js/fm-script-' . $form_id . '.js';
|
948 |
if ( !$force_rewrite && file_exists($frontend_js) ) {
|
958 |
$jsfile = fopen($frontend_js, "w");
|
959 |
$pattern = '/\/\/(.+)(\r\n|\r|\n)/';
|
960 |
|
961 |
+
$row_display = self::display_options($form_id);
|
962 |
$row->javascript = str_replace('function before_reset()', 'function before_reset' . $form_id . '()', $row->javascript);
|
963 |
$row->javascript = str_replace('function before_load()', 'function before_load' . $form_id . '()', $row->javascript);
|
964 |
$row->javascript = str_replace('function before_submit()', 'function before_submit' . $form_id . '()', $row->javascript);
|
965 |
+
$row->javascript = str_replace('function after_submit()', 'function after_submit' . $form_id . '()', $row->javascript);
|
966 |
$check_js = '';
|
|
|
967 |
$onload_js = '';
|
968 |
+
$onsubmit_js = '';
|
969 |
+
$form_currency = '';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
970 |
if ( $row->payment_currency ) {
|
971 |
+
$form_currency = self::replace_currency_code( $row->payment_currency );
|
|
|
|
|
|
|
972 |
}
|
973 |
$form_paypal_tax = $row->tax;
|
974 |
$stripe_enable = 0;
|
2554 |
if ( $disable_past_days == 'true' ) {
|
2555 |
$check_js .= '
|
2556 |
if( Date.parse(jQuery("#wdform_' . $id1 . '_element' . $form_id . '").val() + " 23:59:59") < fm_currentDate.getTime() ) {
|
2557 |
+
alert("' . __('You cannot select former dates. Choose a date starting from the current one.', WDFMInstance(self::PLUGIN)->prefix) . '");
|
2558 |
return false;
|
2559 |
}';
|
2560 |
}
|
2966 |
array_push($req_fields, $id1);
|
2967 |
}
|
2968 |
$file_upload_check[$id1] = $param['w_extension'];
|
2969 |
+
if ( WDFMInstance(self::PLUGIN)->is_demo ) {
|
2970 |
$onsubmit_js .= 'alert( "You can\'t upload file in demo.");';
|
2971 |
}
|
2972 |
break;
|
3132 |
$check_js .= '
|
3133 |
if(x.find(jQuery("div[wdid=' . $id1 . ']")).length != 0 && x.find(jQuery("div[wdid=' . $id1 . ']")).css("display") != "none") {
|
3134 |
if(jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").val() == "' . $w_title[0] . '" || jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").val() == "") {
|
3135 |
+
alert("' . addslashes($label . ' ' . __('field is required.', WDFMInstance(self::PLUGIN)->prefix)) . '");
|
3136 |
old_bg=x.find(jQuery("div[wdid=' . $id1 . ']")).css("background-color");
|
3137 |
x.find(jQuery("div[wdid=' . $id1 . ']")).effect( "shake", {}, 500 ).css("background-color","#FF8F8B").animate({backgroundColor: old_bg}, {duration: 500, queue: false });
|
3138 |
jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").focus();
|
3162 |
var range_max=' . ($param['w_range_max'] ? $param['w_range_max'] : -1) . ';
|
3163 |
if(' . ($required ? 'true' : 'false') . ' || jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").val() != "' . $w_title[0] . '" || jQuery("#wdform_' . $id1 . '_element_cents' . $form_id . '").val() != "' . $w_title[1] . '") {
|
3164 |
if((range_max!=-1 && parseFloat(price)>range_max) || parseFloat(price)<range_min) {
|
3165 |
+
alert("' . addslashes((__('The', WDFMInstance(self::PLUGIN)->prefix)) . $label . (__('value must be between', WDFMInstance(self::PLUGIN)->prefix)) . ($param['w_range_min'] ? $param['w_range_min'] : 0) . '-' . ($param['w_range_max'] ? $param['w_range_max'] : "any")) . '");
|
3166 |
old_bg=x.find(jQuery("div[wdid=' . $id1 . ']")).css("background-color");
|
3167 |
x.find(jQuery("div[wdid=' . $id1 . ']")).effect( "shake", {}, 500 ).css("background-color","#FF8F8B").animate({backgroundColor: old_bg}, {duration: 500, queue: false });
|
3168 |
jQuery("#wdform_' . $id1 . '_element_dollars' . $form_id . '").focus();
|
3288 |
$onsubmit_js .= '
|
3289 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_label' . $form_id . '\" />").val(jQuery("#wdform_' . $id1 . '_element' . $form_id . ' option:selected").text()).appendTo("#form' . $form_id . '");';
|
3290 |
$onsubmit_js .= '
|
3291 |
+
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_quantity_label' . $form_id . '\" />").val("' . (__("Quantity", WDFMInstance(self::PLUGIN)->prefix)) . '").appendTo("#form' . $form_id . '");';
|
3292 |
foreach ( $param['w_property'] as $key => $property ) {
|
3293 |
$onsubmit_js .= '
|
3294 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_property_label' . $form_id . $key . '\" />").val("' . $property . '").appendTo("#form' . $form_id . '");';
|
3370 |
$onsubmit_js .= '
|
3371 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_label' . $form_id . '\" />").val((jQuery("#wdform_' . $id1 . '_element' . $form_id . ' input:checked").length != 0) ? jQuery("#wdform_' . $id1 . '_element' . $form_id . ' input:checked").attr("id").replace("element", "elementlabel_") : "").appendTo("#form' . $form_id . '");';
|
3372 |
$onsubmit_js .= '
|
3373 |
+
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_quantity_label' . $form_id . '\" />").val("' . (__("Quantity", WDFMInstance(self::PLUGIN)->prefix)) . '").appendTo("#form' . $form_id . '");';
|
3374 |
foreach ( $param['w_property'] as $key => $property ) {
|
3375 |
$onsubmit_js .= '
|
3376 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_property_label' . $form_id . $key . '\" />").val("' . $property . '").appendTo("#form' . $form_id . '");';
|
3452 |
$onsubmit_js .= '
|
3453 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_label' . $form_id . '\" />").val(jQuery("label[for=\'"+jQuery("input[name^=\'wdform_' . $id1 . '_element' . $form_id . '\']:checked").attr("id")+"\']").eq(0).text()).appendTo("#form' . $form_id . '");';
|
3454 |
$onsubmit_js .= '
|
3455 |
+
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_quantity_label' . $form_id . '\" />").val("' . (__("Quantity", WDFMInstance(self::PLUGIN)->prefix)) . '").appendTo("#form' . $form_id . '");';
|
3456 |
foreach ( $param['w_property'] as $key => $property ) {
|
3457 |
$onsubmit_js .= '
|
3458 |
jQuery("<input type=\"hidden\" name=\"wdform_' . $id1 . '_element_property_label' . $form_id . $key . '\" />").val("' . $property . '").appendTo("#form' . $form_id . '");';
|
3639 |
$onload_js .= '
|
3640 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '")[0].spin = null;
|
3641 |
spinner = jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner();
|
3642 |
+
if ("' . $param['w_field_value'] . '" == "null" && jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").val() == "") { spinner.spinner("value", ""); }
|
3643 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ min: "' . $param['w_field_min_value'] . '"});
|
3644 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ max: "' . $param['w_field_max_value'] . '"});
|
3645 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ step: "' . $param['w_field_step'] . '"});';
|
3734 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '0")[0].spin = null;
|
3735 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '1")[0].spin = null;
|
3736 |
spinner0 = jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '0").spinner();
|
3737 |
+
if ("' . $param['w_field_value1'] . '" == "null" && jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '0").val() == "") { spinner0.spinner("value", ""); }
|
3738 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ step: ' . $param['w_field_range_step'] . '});
|
3739 |
spinner1 = jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '1").spinner();
|
3740 |
+
if ("' . $param['w_field_value2'] . '" == "null" && jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '1").val() == "") { spinner1.spinner("value", ""); }
|
3741 |
jQuery("#form' . $form_id . ' #wdform_' . $id1 . '_element' . $form_id . '").spinner({ step: ' . $param['w_field_range_step'] . '});';
|
3742 |
if ( $required ) {
|
3743 |
array_push($req_fields, $id1);
|
3789 |
var isAllowdedSubmit = true;
|
3790 |
if(x.find(jQuery("div[wdid=' . $id1 . ']")).length != 0 && x.find(jQuery("div[wdid=' . $id1 . ']")).css("display") != "none") {
|
3791 |
if(parseInt(jQuery("#wdform_' . $id1 . '_sum_element' . $form_id . '").html()) > ' . $param['w_total'] . ') {
|
3792 |
+
alert("' . addslashes(__("Your score should be less than", WDFMInstance(self::PLUGIN)->prefix)) . ' ' . $param['w_total'] . '");
|
3793 |
return false;
|
3794 |
}
|
3795 |
}';
|
3905 |
});
|
3906 |
<?php
|
3907 |
$js_content = ob_get_clean();
|
3908 |
+
self::$fm_js_content = $js_content;
|
3909 |
fwrite($jsfile, $js_content);
|
3910 |
fclose($jsfile);
|
3911 |
clearstatcache();
|
3923 |
$group_id_s = array();
|
3924 |
$form_id = (int) $_REQUEST['form_id'];
|
3925 |
$limitstart = (int) $_REQUEST['limitstart'];
|
3926 |
+
$search_labels = WDW_FM_Library(self::PLUGIN)->get('search_labels', '');
|
3927 |
$verified_emails = isset($_REQUEST['verified_emails']) ? json_decode(stripslashes($_REQUEST['verified_emails']), TRUE) : array();
|
3928 |
$paypal_info_fields = array(
|
3929 |
'currency',
|
4205 |
$title = ($title != '') ? strtolower($title) : 'items';
|
4206 |
ob_start();
|
4207 |
?><tr class="no-items">
|
4208 |
+
<td class="colspanchange" colspan="0"><?php echo sprintf(__('No %s found.', WDFMInstance(self::PLUGIN)->prefix), $title); ?></td>
|
4209 |
</tr><?php
|
4210 |
return ob_get_clean();
|
4211 |
}
|
4250 |
*/
|
4251 |
public static function deactivate_all_addons() {
|
4252 |
include_once( ABSPATH . 'wp-admin/includes/plugin.php' );
|
4253 |
+
$addons = self::get_all_addons_path();
|
4254 |
foreach ( $addons as $addon ) {
|
4255 |
if( is_plugin_active( $addon ) ) {
|
4256 |
deactivate_plugins( $addon );
|
4266 |
public static function get_countries() {
|
4267 |
$countries = array(
|
4268 |
"" => "",
|
4269 |
+
"Afghanistan" => __("Afghanistan", WDFMInstance(self::PLUGIN)->prefix),
|
4270 |
+
"Albania" => __("Albania", WDFMInstance(self::PLUGIN)->prefix),
|
4271 |
+
"Algeria" => __("Algeria", WDFMInstance(self::PLUGIN)->prefix),
|
4272 |
+
"Andorra" => __("Andorra", WDFMInstance(self::PLUGIN)->prefix),
|
4273 |
+
"Angola" => __("Angola", WDFMInstance(self::PLUGIN)->prefix),
|
4274 |
+
"Antigua and Barbuda" => __("Antigua and Barbuda", WDFMInstance(self::PLUGIN)->prefix),
|
4275 |
+
"Argentina" => __("Argentina", WDFMInstance(self::PLUGIN)->prefix),
|
4276 |
+
"Armenia" => __("Armenia", WDFMInstance(self::PLUGIN)->prefix),
|
4277 |
+
"Australia" => __("Australia", WDFMInstance(self::PLUGIN)->prefix),
|
4278 |
+
"Austria" => __("Austria", WDFMInstance(self::PLUGIN)->prefix),
|
4279 |
+
"Azerbaijan" => __("Azerbaijan", WDFMInstance(self::PLUGIN)->prefix),
|
4280 |
+
"Bahamas" => __("Bahamas", WDFMInstance(self::PLUGIN)->prefix),
|
4281 |
+
"Bahrain" => __("Bahrain", WDFMInstance(self::PLUGIN)->prefix),
|
4282 |
+
"Bangladesh" => __("Bangladesh", WDFMInstance(self::PLUGIN)->prefix),
|
4283 |
+
"Barbados" => __("Barbados", WDFMInstance(self::PLUGIN)->prefix),
|
4284 |
+
"Belarus" => __("Belarus", WDFMInstance(self::PLUGIN)->prefix),
|
4285 |
+
"Belgium" => __("Belgium", WDFMInstance(self::PLUGIN)->prefix),
|
4286 |
+
"Belize" => __("Belize", WDFMInstance(self::PLUGIN)->prefix),
|
4287 |
+
"Benin" => __("Benin", WDFMInstance(self::PLUGIN)->prefix),
|
4288 |
+
"Bhutan" => __("Bhutan", WDFMInstance(self::PLUGIN)->prefix),
|
4289 |
+
"Bolivia" => __("Bolivia", WDFMInstance(self::PLUGIN)->prefix),
|
4290 |
+
"Bosnia and Herzegovina" => __("Bosnia and Herzegovina", WDFMInstance(self::PLUGIN)->prefix),
|
4291 |
+
"Botswana" => __("Botswana", WDFMInstance(self::PLUGIN)->prefix),
|
4292 |
+
"Brazil" => __("Brazil", WDFMInstance(self::PLUGIN)->prefix),
|
4293 |
+
"Brunei" => __("Brunei", WDFMInstance(self::PLUGIN)->prefix),
|
4294 |
+
"Bulgaria" => __("Bulgaria", WDFMInstance(self::PLUGIN)->prefix),
|
4295 |
+
"Burkina" => __("Burkina Faso", WDFMInstance(self::PLUGIN)->prefix),
|
4296 |
+
"Burundi" => __("Burundi", WDFMInstance(self::PLUGIN)->prefix),
|
4297 |
+
"Cambodia" => __("Cambodia", WDFMInstance(self::PLUGIN)->prefix),
|
4298 |
+
"Cameroon" => __("Cameroon", WDFMInstance(self::PLUGIN)->prefix),
|
4299 |
+
"Canada" => __("Canada", WDFMInstance(self::PLUGIN)->prefix),
|
4300 |
+
"Cape Verde" => __("Cape Verde", WDFMInstance(self::PLUGIN)->prefix),
|
4301 |
+
"Central African Republic" => __("Central African Republic", WDFMInstance(self::PLUGIN)->prefix),
|
4302 |
+
"Chad" => __("Chad", WDFMInstance(self::PLUGIN)->prefix),
|
4303 |
+
"Chile" => __("Chile", WDFMInstance(self::PLUGIN)->prefix),
|
4304 |
+
"China" => __("China", WDFMInstance(self::PLUGIN)->prefix),
|
4305 |
+
"Colombia" => __("Colombia", WDFMInstance(self::PLUGIN)->prefix),
|
4306 |
+
"Comoros" => __("Comoros", WDFMInstance(self::PLUGIN)->prefix),
|
4307 |
+
"Congo (Brazzaville)" => __("Congo (Brazzaville)", WDFMInstance(self::PLUGIN)->prefix),
|
4308 |
+
"Congo" => __("Congo", WDFMInstance(self::PLUGIN)->prefix),
|
4309 |
+
"Costa Rica" => __("Costa Rica", WDFMInstance(self::PLUGIN)->prefix),
|
4310 |
+
"Cote d'Ivoire" => __("Cote d'Ivoire", WDFMInstance(self::PLUGIN)->prefix),
|
4311 |
+
"Croatia" => __("Croatia", WDFMInstance(self::PLUGIN)->prefix),
|
4312 |
+
"Cuba" => __("Cuba", WDFMInstance(self::PLUGIN)->prefix),
|
4313 |
+
"Curacao" => __("Curacao", WDFMInstance(self::PLUGIN)->prefix),
|
4314 |
+
"Cyprus" => __("Cyprus", WDFMInstance(self::PLUGIN)->prefix),
|
4315 |
+
"Czech Republic" => __("Czech Republic", WDFMInstance(self::PLUGIN)->prefix),
|
4316 |
+
"Denmark" => __("Denmark", WDFMInstance(self::PLUGIN)->prefix),
|
4317 |
+
"Djibouti" => __("Djibouti", WDFMInstance(self::PLUGIN)->prefix),
|
4318 |
+
"Dominica" => __("Dominica", WDFMInstance(self::PLUGIN)->prefix),
|
4319 |
+
"Dominican Republic" => __("Dominican Republic", WDFMInstance(self::PLUGIN)->prefix),
|
4320 |
+
"East Timor (Timor Timur" => __("East Timor (Timor Timur)", WDFMInstance(self::PLUGIN)->prefix),
|
4321 |
+
"Ecuador" => __("Ecuador", WDFMInstance(self::PLUGIN)->prefix),
|
4322 |
+
"Egypt" => __("Egypt", WDFMInstance(self::PLUGIN)->prefix),
|
4323 |
+
"El Salvador" => __("El Salvador", WDFMInstance(self::PLUGIN)->prefix),
|
4324 |
+
"Equatorial" => __("Equatorial Guinea", WDFMInstance(self::PLUGIN)->prefix),
|
4325 |
+
"Eritrea" => __("Eritrea", WDFMInstance(self::PLUGIN)->prefix),
|
4326 |
+
"Estonia" => __("Estonia", WDFMInstance(self::PLUGIN)->prefix),
|
4327 |
+
"Ethiopia" => __("Ethiopia", WDFMInstance(self::PLUGIN)->prefix),
|
4328 |
+
"Fiji" => __("Fiji", WDFMInstance(self::PLUGIN)->prefix),
|
4329 |
+
"Finland" => __("Finland", WDFMInstance(self::PLUGIN)->prefix),
|
4330 |
+
"France" => __("France", WDFMInstance(self::PLUGIN)->prefix),
|
4331 |
+
"Gabon" => __("Gabon", WDFMInstance(self::PLUGIN)->prefix),
|
4332 |
+
"Gambia, The" => __("Gambia, The", WDFMInstance(self::PLUGIN)->prefix),
|
4333 |
+
"Georgia" => __("Georgia", WDFMInstance(self::PLUGIN)->prefix),
|
4334 |
+
"Germany" => __("Germany", WDFMInstance(self::PLUGIN)->prefix),
|
4335 |
+
"Ghana" => __("Ghana", WDFMInstance(self::PLUGIN)->prefix),
|
4336 |
+
"Greece" => __("Greece", WDFMInstance(self::PLUGIN)->prefix),
|
4337 |
+
"Grenada" => __("Grenada", WDFMInstance(self::PLUGIN)->prefix),
|
4338 |
+
"Guatemala" => __("Guatemala", WDFMInstance(self::PLUGIN)->prefix),
|
4339 |
+
"Guinea" => __("Guinea", WDFMInstance(self::PLUGIN)->prefix),
|
4340 |
+
"Guinea-Bissau" => __("Guinea-Bissau", WDFMInstance(self::PLUGIN)->prefix),
|
4341 |
+
"Guyana" => __("Guyana", WDFMInstance(self::PLUGIN)->prefix),
|
4342 |
+
"Haiti" => __("Haiti", WDFMInstance(self::PLUGIN)->prefix),
|
4343 |
+
"Honduras" => __("Honduras", WDFMInstance(self::PLUGIN)->prefix),
|
4344 |
+
"Hong Kong" => __("Hong Kong", WDFMInstance(self::PLUGIN)->prefix),
|
4345 |
+
"Hungary" => __("Hungary", WDFMInstance(self::PLUGIN)->prefix),
|
4346 |
+
"Iceland" => __("Iceland", WDFMInstance(self::PLUGIN)->prefix),
|
4347 |
+
"India" => __("India", WDFMInstance(self::PLUGIN)->prefix),
|
4348 |
+
"Indonesia" => __("Indonesia", WDFMInstance(self::PLUGIN)->prefix),
|
4349 |
+
"Iran" => __("Iran", WDFMInstance(self::PLUGIN)->prefix),
|
4350 |
+
"Iraq" => __("Iraq", WDFMInstance(self::PLUGIN)->prefix),
|
4351 |
+
"Ireland" => __("Ireland", WDFMInstance(self::PLUGIN)->prefix),
|
4352 |
+
"Israel" => __("Israel", WDFMInstance(self::PLUGIN)->prefix),
|
4353 |
+
"Italy" => __("Italy", WDFMInstance(self::PLUGIN)->prefix),
|
4354 |
+
"Jamaica" => __("Jamaica", WDFMInstance(self::PLUGIN)->prefix),
|
4355 |
+
"Japan" => __("Japan", WDFMInstance(self::PLUGIN)->prefix),
|
4356 |
+
"Jordan" => __("Jordan", WDFMInstance(self::PLUGIN)->prefix),
|
4357 |
+
"Kazakhstan" => __("Kazakhstan", WDFMInstance(self::PLUGIN)->prefix),
|
4358 |
+
"Kenya" => __("Kenya", WDFMInstance(self::PLUGIN)->prefix),
|
4359 |
+
"Kiribati" => __("Kiribati", WDFMInstance(self::PLUGIN)->prefix),
|
4360 |
+
"Korea, North" => __("Korea, North", WDFMInstance(self::PLUGIN)->prefix),
|
4361 |
+
"Korea, South" => __("Korea, South", WDFMInstance(self::PLUGIN)->prefix),
|
4362 |
+
"Kuwait" => __("Kuwait", WDFMInstance(self::PLUGIN)->prefix),
|
4363 |
+
"Kyrgyzstan" => __("Kyrgyzstan", WDFMInstance(self::PLUGIN)->prefix),
|
4364 |
+
"Laos" => __("Laos", WDFMInstance(self::PLUGIN)->prefix),
|
4365 |
+
"Latvia" => __("Latvia", WDFMInstance(self::PLUGIN)->prefix),
|
4366 |
+
"Lebanon" => __("Lebanon", WDFMInstance(self::PLUGIN)->prefix),
|
4367 |
+
"Lesotho" => __("Lesotho", WDFMInstance(self::PLUGIN)->prefix),
|
4368 |
+
"Liberia" => __("Liberia", WDFMInstance(self::PLUGIN)->prefix),
|
4369 |
+
"Libya" => __("Libya", WDFMInstance(self::PLUGIN)->prefix),
|
4370 |
+
"Liechtenstein" => __("Liechtenstein", WDFMInstance(self::PLUGIN)->prefix),
|
4371 |
+
"Lithuania" => __("Lithuania", WDFMInstance(self::PLUGIN)->prefix),
|
4372 |
+
"Luxembourg" => __("Luxembourg", WDFMInstance(self::PLUGIN)->prefix),
|
4373 |
+
"Macedonia" => __("Macedonia", WDFMInstance(self::PLUGIN)->prefix),
|
4374 |
+
"Madagascar" => __("Madagascar", WDFMInstance(self::PLUGIN)->prefix),
|
4375 |
+
"Malawi" => __("Malawi", WDFMInstance(self::PLUGIN)->prefix),
|
4376 |
+
"Malaysia" => __("Malaysia", WDFMInstance(self::PLUGIN)->prefix),
|
4377 |
+
"Maldives" => __("Maldives", WDFMInstance(self::PLUGIN)->prefix),
|
4378 |
+
"Mali" => __("Mali", WDFMInstance(self::PLUGIN)->prefix),
|
4379 |
+
"Malta" => __("Malta", WDFMInstance(self::PLUGIN)->prefix),
|
4380 |
+
"Marshall Islands" => __("Marshall Islands", WDFMInstance(self::PLUGIN)->prefix),
|
4381 |
+
"Mauritania" => __("Mauritania", WDFMInstance(self::PLUGIN)->prefix),
|
4382 |
+
"Mauritius" => __("Mauritius", WDFMInstance(self::PLUGIN)->prefix),
|
4383 |
+
"Mexico" => __("Mexico", WDFMInstance(self::PLUGIN)->prefix),
|
4384 |
+
"Micronesia" => __("Micronesia", WDFMInstance(self::PLUGIN)->prefix),
|
4385 |
+
"Moldova" => __("Moldova", WDFMInstance(self::PLUGIN)->prefix),
|
4386 |
+
"Monaco" => __("Monaco", WDFMInstance(self::PLUGIN)->prefix),
|
4387 |
+
"Mongolia" => __("Mongolia", WDFMInstance(self::PLUGIN)->prefix),
|
4388 |
+
"Morocco" => __("Morocco", WDFMInstance(self::PLUGIN)->prefix),
|
4389 |
+
"Mozambique" => __("Mozambique", WDFMInstance(self::PLUGIN)->prefix),
|
4390 |
+
"Myanmar" => __("Myanmar", WDFMInstance(self::PLUGIN)->prefix),
|
4391 |
+
"Namibia" => __("Namibia", WDFMInstance(self::PLUGIN)->prefix),
|
4392 |
+
"Nauru" => __("Nauru", WDFMInstance(self::PLUGIN)->prefix),
|
4393 |
+
"Nepal" => __("Nepal", WDFMInstance(self::PLUGIN)->prefix),
|
4394 |
+
"Netherlands" => __("Netherlands", WDFMInstance(self::PLUGIN)->prefix),
|
4395 |
+
"New Zealand" => __("New Zealand", WDFMInstance(self::PLUGIN)->prefix),
|
4396 |
+
"Nicaragua" => __("Nicaragua", WDFMInstance(self::PLUGIN)->prefix),
|
4397 |
+
"Niger" => __("Niger", WDFMInstance(self::PLUGIN)->prefix),
|
4398 |
+
"Nigeria" => __("Nigeria", WDFMInstance(self::PLUGIN)->prefix),
|
4399 |
+
"Norway" => __("Norway", WDFMInstance(self::PLUGIN)->prefix),
|
4400 |
+
"Oman" => __("Oman", WDFMInstance(self::PLUGIN)->prefix),
|
4401 |
+
"Pakistan" => __("Pakistan", WDFMInstance(self::PLUGIN)->prefix),
|
4402 |
+
"Palau" => __("Palau", WDFMInstance(self::PLUGIN)->prefix),
|
4403 |
+
"Panama" => __("Panama", WDFMInstance(self::PLUGIN)->prefix),
|
4404 |
+
"Papua New Guinea" => __("Papua New Guinea", WDFMInstance(self::PLUGIN)->prefix),
|
4405 |
+
"Paraguay" => __("Paraguay", WDFMInstance(self::PLUGIN)->prefix),
|
4406 |
+
"Peru" => __("Peru", WDFMInstance(self::PLUGIN)->prefix),
|
4407 |
+
"Philippines" => __("Philippines", WDFMInstance(self::PLUGIN)->prefix),
|
4408 |
+
"Poland" => __("Poland", WDFMInstance(self::PLUGIN)->prefix),
|
4409 |
+
"Portugal" => __("Portugal", WDFMInstance(self::PLUGIN)->prefix),
|
4410 |
+
"Puerto Rico" => __("Puerto Rico", WDFMInstance(self::PLUGIN)->prefix),
|
4411 |
+
"Qatar" => __("Qatar", WDFMInstance(self::PLUGIN)->prefix),
|
4412 |
+
"Romania" => __("Romania", WDFMInstance(self::PLUGIN)->prefix),
|
4413 |
+
"Russia" => __("Russia", WDFMInstance(self::PLUGIN)->prefix),
|
4414 |
+
"Rwanda" => __("Rwanda", WDFMInstance(self::PLUGIN)->prefix),
|
4415 |
+
"Saint Kitts and Nevis" => __("Saint Kitts and Nevis", WDFMInstance(self::PLUGIN)->prefix),
|
4416 |
+
"Saint Lucia" => __("Saint Lucia", WDFMInstance(self::PLUGIN)->prefix),
|
4417 |
+
"Saint Vincent" => __("Saint Vincent", WDFMInstance(self::PLUGIN)->prefix),
|
4418 |
+
"Samoa" => __("Samoa", WDFMInstance(self::PLUGIN)->prefix),
|
4419 |
+
"San Marino" => __("San Marino", WDFMInstance(self::PLUGIN)->prefix),
|
4420 |
+
"Sao Tome and Principe" => __("Sao Tome and Principe", WDFMInstance(self::PLUGIN)->prefix),
|
4421 |
+
"Saudi Arabia" => __("Saudi Arabia", WDFMInstance(self::PLUGIN)->prefix),
|
4422 |
+
"Senegal" => __("Senegal", WDFMInstance(self::PLUGIN)->prefix),
|
4423 |
+
"Serbia and Montenegro" => __("Serbia and Montenegro", WDFMInstance(self::PLUGIN)->prefix),
|
4424 |
+
"Seychelles" => __("Seychelles", WDFMInstance(self::PLUGIN)->prefix),
|
4425 |
+
"Sierra Leone" => __("Sierra Leone", WDFMInstance(self::PLUGIN)->prefix),
|
4426 |
+
"Singapore" => __("Singapore", WDFMInstance(self::PLUGIN)->prefix),
|
4427 |
+
"Slovakia" => __("Slovakia", WDFMInstance(self::PLUGIN)->prefix),
|
4428 |
+
"Slovenia" => __("Slovenia", WDFMInstance(self::PLUGIN)->prefix),
|
4429 |
+
"Solomon Islands" => __("Solomon Islands", WDFMInstance(self::PLUGIN)->prefix),
|
4430 |
+
"Somalia" => __("Somalia", WDFMInstance(self::PLUGIN)->prefix),
|
4431 |
+
"South Africa" => __("South Africa", WDFMInstance(self::PLUGIN)->prefix),
|
4432 |
+
"Spain" => __("Spain", WDFMInstance(self::PLUGIN)->prefix),
|
4433 |
+
"Sri Lanka" => __("Sri Lanka", WDFMInstance(self::PLUGIN)->prefix),
|
4434 |
+
"Sudan" => __("Sudan", WDFMInstance(self::PLUGIN)->prefix),
|
4435 |
+
"Suriname" => __("Suriname", WDFMInstance(self::PLUGIN)->prefix),
|
4436 |
+
"Swaziland" => __("Swaziland", WDFMInstance(self::PLUGIN)->prefix),
|
4437 |
+
"Sweden" => __("Sweden", WDFMInstance(self::PLUGIN)->prefix),
|
4438 |
+
"Switzerland" => __("Switzerland", WDFMInstance(self::PLUGIN)->prefix),
|
4439 |
+
"Syria" => __("Syria", WDFMInstance(self::PLUGIN)->prefix),
|
4440 |
+
"Taiwan" => __("Taiwan", WDFMInstance(self::PLUGIN)->prefix),
|
4441 |
+
"Tajikistan" => __("Tajikistan", WDFMInstance(self::PLUGIN)->prefix),
|
4442 |
+
"Tanzania" => __("Tanzania", WDFMInstance(self::PLUGIN)->prefix),
|
4443 |
+
"Thailand" => __("Thailand", WDFMInstance(self::PLUGIN)->prefix),
|
4444 |
+
"Togo" => __("Togo", WDFMInstance(self::PLUGIN)->prefix),
|
4445 |
+
"Tonga" => __("Tonga", WDFMInstance(self::PLUGIN)->prefix),
|
4446 |
+
"Trinidad and Tobago" => __("Trinidad and Tobago", WDFMInstance(self::PLUGIN)->prefix),
|
4447 |
+
"Tunisia" => __("Tunisia", WDFMInstance(self::PLUGIN)->prefix),
|
4448 |
+
"Turkey" => __("Turkey", WDFMInstance(self::PLUGIN)->prefix),
|
4449 |
+
"Turkmenistan" => __("Turkmenistan", WDFMInstance(self::PLUGIN)->prefix),
|
4450 |
+
"Tuvalu" => __("Tuvalu", WDFMInstance(self::PLUGIN)->prefix),
|
4451 |
+
"Uganda" => __("Uganda", WDFMInstance(self::PLUGIN)->prefix),
|
4452 |
+
"Ukraine" => __("Ukraine", WDFMInstance(self::PLUGIN)->prefix),
|
4453 |
+
"United Arab Emirates" => __("United Arab Emirates", WDFMInstance(self::PLUGIN)->prefix),
|
4454 |
+
"United Kingdom" => __("United Kingdom", WDFMInstance(self::PLUGIN)->prefix),
|
4455 |
+
"United States" => __("United States", WDFMInstance(self::PLUGIN)->prefix),
|
4456 |
+
"Uruguay" => __("Uruguay", WDFMInstance(self::PLUGIN)->prefix),
|
4457 |
+
"Uzbekistan" => __("Uzbekistan", WDFMInstance(self::PLUGIN)->prefix),
|
4458 |
+
"Vanuatu" => __("Vanuatu", WDFMInstance(self::PLUGIN)->prefix),
|
4459 |
+
"Vatican City" => __("Vatican City", WDFMInstance(self::PLUGIN)->prefix),
|
4460 |
+
"Venezuela" => __("Venezuela", WDFMInstance(self::PLUGIN)->prefix),
|
4461 |
+
"Vietnam" => __("Vietnam", WDFMInstance(self::PLUGIN)->prefix),
|
4462 |
+
"Wales" => __("Wales", WDFMInstance(self::PLUGIN)->prefix),
|
4463 |
+
"Yemen" => __("Yemen", WDFMInstance(self::PLUGIN)->prefix),
|
4464 |
+
"Zambia" => __("Zambia", WDFMInstance(self::PLUGIN)->prefix),
|
4465 |
+
"Zimbabwe" => __("Zimbabwe", WDFMInstance(self::PLUGIN)->prefix),
|
4466 |
);
|
4467 |
|
4468 |
return $countries;
|
4476 |
public static function get_states() {
|
4477 |
$states = array(
|
4478 |
"" => "",
|
4479 |
+
"Alabama" => __("Alabama", WDFMInstance(self::PLUGIN)->prefix),
|
4480 |
+
"Alaska" => __("Alaska", WDFMInstance(self::PLUGIN)->prefix),
|
4481 |
+
"Arizona" => __("Arizona", WDFMInstance(self::PLUGIN)->prefix),
|
4482 |
+
"Arkansas" => __("Arkansas", WDFMInstance(self::PLUGIN)->prefix),
|
4483 |
+
"California" => __("California", WDFMInstance(self::PLUGIN)->prefix),
|
4484 |
+
"Colorado" => __("Colorado", WDFMInstance(self::PLUGIN)->prefix),
|
4485 |
+
"Connecticut" => __("Connecticut", WDFMInstance(self::PLUGIN)->prefix),
|
4486 |
+
"Delaware" => __("Delaware", WDFMInstance(self::PLUGIN)->prefix),
|
4487 |
+
"District Of Columbia" => __("District Of Columbia", WDFMInstance(self::PLUGIN)->prefix),
|
4488 |
+
"Florida" => __("Florida", WDFMInstance(self::PLUGIN)->prefix),
|
4489 |
+
"Georgia" => __("Georgia", WDFMInstance(self::PLUGIN)->prefix),
|
4490 |
+
"Hawaii" => __("Hawaii", WDFMInstance(self::PLUGIN)->prefix),
|
4491 |
+
"Idaho" => __("Idaho", WDFMInstance(self::PLUGIN)->prefix),
|
4492 |
+
"Illinois" => __("Illinois", WDFMInstance(self::PLUGIN)->prefix),
|
4493 |
+
"Indiana" => __("Indiana", WDFMInstance(self::PLUGIN)->prefix),
|
4494 |
+
"Iowa" => __("Iowa", WDFMInstance(self::PLUGIN)->prefix),
|
4495 |
+
"Kansas" => __("Kansas", WDFMInstance(self::PLUGIN)->prefix),
|
4496 |
+
"Kentucky" => __("Kentucky", WDFMInstance(self::PLUGIN)->prefix),
|
4497 |
+
"Louisiana" => __("Louisiana", WDFMInstance(self::PLUGIN)->prefix),
|
4498 |
+
"Maine" => __("Maine", WDFMInstance(self::PLUGIN)->prefix),
|
4499 |
+
"Maryland" => __("Maryland", WDFMInstance(self::PLUGIN)->prefix),
|
4500 |
+
"Massachusetts" => __("Massachusetts", WDFMInstance(self::PLUGIN)->prefix),
|
4501 |
+
"Michigan" => __("Michigan", WDFMInstance(self::PLUGIN)->prefix),
|
4502 |
+
"Minnesota" => __("Minnesota", WDFMInstance(self::PLUGIN)->prefix),
|
4503 |
+
"Mississippi" => __("Mississippi", WDFMInstance(self::PLUGIN)->prefix),
|
4504 |
+
"Missouri" => __("Missouri", WDFMInstance(self::PLUGIN)->prefix),
|
4505 |
+
"Montana" => __("Montana", WDFMInstance(self::PLUGIN)->prefix),
|
4506 |
+
"Nebraska" => __("Nebraska", WDFMInstance(self::PLUGIN)->prefix),
|
4507 |
+
"Nevada" => __("Nevada", WDFMInstance(self::PLUGIN)->prefix),
|
4508 |
+
"New Hampshire" => __("New Hampshire", WDFMInstance(self::PLUGIN)->prefix),
|
4509 |
+
"New Jersey" => __("New Jersey", WDFMInstance(self::PLUGIN)->prefix),
|
4510 |
+
"New Mexico" => __("New Mexico", WDFMInstance(self::PLUGIN)->prefix),
|
4511 |
+
"New York" => __("New York", WDFMInstance(self::PLUGIN)->prefix),
|
4512 |
+
"North Carolina" => __("North Carolina", WDFMInstance(self::PLUGIN)->prefix),
|
4513 |
+
"North Dakota" => __("North Dakota", WDFMInstance(self::PLUGIN)->prefix),
|
4514 |
+
"Ohio" => __("Ohio", WDFMInstance(self::PLUGIN)->prefix),
|
4515 |
+
"Oklahoma" => __("Oklahoma", WDFMInstance(self::PLUGIN)->prefix),
|
4516 |
+
"Oregon" => __("Oregon", WDFMInstance(self::PLUGIN)->prefix),
|
4517 |
+
"Pennsylvania" => __("Pennsylvania", WDFMInstance(self::PLUGIN)->prefix),
|
4518 |
+
"Rhode Island" => __("Rhode Island", WDFMInstance(self::PLUGIN)->prefix),
|
4519 |
+
"South Carolina" => __("South Carolina", WDFMInstance(self::PLUGIN)->prefix),
|
4520 |
+
"South Dakota" => __("South Dakota", WDFMInstance(self::PLUGIN)->prefix),
|
4521 |
+
"Tennessee" => __("Tennessee", WDFMInstance(self::PLUGIN)->prefix),
|
4522 |
+
"Texas" => __("Texas", WDFMInstance(self::PLUGIN)->prefix),
|
4523 |
+
"Utah" => __("Utah", WDFMInstance(self::PLUGIN)->prefix),
|
4524 |
+
"Vermont" => __("Vermont", WDFMInstance(self::PLUGIN)->prefix),
|
4525 |
+
"Virginia" => __("Virginia", WDFMInstance(self::PLUGIN)->prefix),
|
4526 |
+
"Washington" => __("Washington", WDFMInstance(self::PLUGIN)->prefix),
|
4527 |
+
"West Virginia" => __("West Virginia", WDFMInstance(self::PLUGIN)->prefix),
|
4528 |
+
"Wisconsin" => __("Wisconsin", WDFMInstance(self::PLUGIN)->prefix),
|
4529 |
+
"Wyoming" => __("Wyoming", WDFMInstance(self::PLUGIN)->prefix),
|
4530 |
);
|
4531 |
|
4532 |
return $states;
|
4540 |
public static function localize_ui_datepicker() {
|
4541 |
return 'jQuery(document).ready(function(jQuery){
|
4542 |
jQuery.datepicker.setDefaults( {
|
4543 |
+
"closeText":"' . __('Done', WDFMInstance(self::PLUGIN)->prefix) . '",
|
4544 |
+
"prevText":"' . __('Prev', WDFMInstance(self::PLUGIN)->prefix) . '",
|
4545 |
+
"nextText":"' . __('Next', WDFMInstance(self::PLUGIN)->prefix) . '",
|
4546 |
+
"currentText":"' . __('Today', WDFMInstance(self::PLUGIN)->prefix) . '",
|
4547 |
+
"monthNames":["' . __('January', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('February', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('March', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('April', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('May', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('June', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('July', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('August', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('September', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('October', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('November', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('December', WDFMInstance(self::PLUGIN)->prefix) . '"],
|
4548 |
+
"monthNamesShort":["' . __('Jan', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Feb', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Mar', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Apr', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('May', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Jun', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Jul', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Aug', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Sep', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Oct', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Nov', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Dec', WDFMInstance(self::PLUGIN)->prefix) . '"],
|
4549 |
+
"dayNames":["' . __('Sunday', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Monday', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Tuesday', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Wednesday', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Thursday', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Friday', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Saturday', WDFMInstance(self::PLUGIN)->prefix) . '"],
|
4550 |
+
"dayNamesShort":["' . __('Sun', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Mon', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Tue', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Wed', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Thu', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Fri', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Sat', WDFMInstance(self::PLUGIN)->prefix) . '"],
|
4551 |
+
"dayNamesMin":["' . __('Su', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Mo', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Tu', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('We', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Th', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Fr', WDFMInstance(self::PLUGIN)->prefix) . '","' . __('Sa', WDFMInstance(self::PLUGIN)->prefix) . '"]
|
4552 |
});
|
4553 |
})';
|
4554 |
}
|
4672 |
|
4673 |
return $sent;
|
4674 |
}
|
4675 |
+
|
4676 |
public static $email_content_type;
|
4677 |
public static $email_charset;
|
4678 |
public static $email_from;
|
4680 |
public static function mail_content_type() {
|
4681 |
return self::$email_content_type;
|
4682 |
}
|
4683 |
+
|
4684 |
public static function mail_charset() {
|
4685 |
return self::$email_charset;
|
4686 |
}
|
4687 |
+
|
4688 |
public static function mail_from() {
|
4689 |
return self::$email_from;
|
4690 |
}
|
5018 |
public static function decodeQuotedPrintable( $string ) {
|
5019 |
return quoted_printable_decode($string);
|
5020 |
}
|
5021 |
+
|
5022 |
+
/**
|
5023 |
+
* Replace currencycode.
|
5024 |
+
*
|
5025 |
+
* @param string $key
|
5026 |
+
*
|
5027 |
+
* @return string
|
5028 |
+
*/
|
5029 |
+
public static function replace_currency_code( $key ) {
|
5030 |
+
$currency_code = array('USD', 'EUR', 'GBP', 'JPY', 'CAD', 'MXN', 'HKD', 'HUF', 'NOK', 'NZD', 'SGD', 'SEK', 'PLN', 'AUD', 'DKK', 'CHF', 'CZK', 'ILS', 'BRL', 'TWD', 'MYR', 'PHP', 'THB' );
|
5031 |
+
$currency_sign = array('$', '€', '£', '¥', 'C$', 'Mex$', 'HK$', 'Ft', 'kr', 'NZ$', 'S$', 'kr', 'zl', 'A$', 'kr', 'CHF', 'Kc', '₪', 'R$', 'NT$', 'RM', '₱', '฿' );
|
5032 |
+
$currency = $currency_sign[array_search($key, $currency_code)];
|
5033 |
+
|
5034 |
+
return $currency;
|
5035 |
+
}
|
5036 |
+
|
5037 |
+
/**
|
5038 |
+
* Create Email options placeholders.
|
5039 |
+
*
|
5040 |
+
* @param array $labels
|
5041 |
+
* @return array $data
|
5042 |
+
*/
|
5043 |
+
public static function create_email_options_placeholders( $labels = array() ) {
|
5044 |
+
$data = array();
|
5045 |
+
$form_inputs = array();
|
5046 |
+
$continue_types = array('type_submit_reset', 'type_editor', 'type_map', 'type_mark_map', 'type_captcha', 'type_recaptcha', 'type_button', 'type_send_copy');
|
5047 |
+
$inputs = array(
|
5048 |
+
array('value' => 'all', 'title' => __('All fields list', WDFMInstance(self::PLUGIN)->prefix)),
|
5049 |
+
);
|
5050 |
+
if ( !empty($labels) ) {
|
5051 |
+
foreach($labels as $key => $label) {
|
5052 |
+
if ( in_array($label['type'], $continue_types) ) {
|
5053 |
+
continue;
|
5054 |
+
}
|
5055 |
+
if ( $label['type'] == "type_file_upload" ) {
|
5056 |
+
$key = $key . '(link)';
|
5057 |
+
}
|
5058 |
+
$form_inputs[] = array('value' => $key, 'title' => $label['name'] );
|
5059 |
+
}
|
5060 |
+
}
|
5061 |
+
$data[__('Form fields', WDFMInstance(self::PLUGIN)->prefix)] = array_merge($inputs, $form_inputs);
|
5062 |
+
$data[__('Misc', WDFMInstance(self::PLUGIN)->prefix)] = array(
|
5063 |
+
array('value' => 'formtitle', 'title' => __('Form Title', WDFMInstance(self::PLUGIN)->prefix)),
|
5064 |
+
array('value' => 'subid', 'title' => __('Submission ID', WDFMInstance(self::PLUGIN)->prefix)),
|
5065 |
+
array('value' => 'ip', 'title' => __('IP', WDFMInstance(self::PLUGIN)->prefix)),
|
5066 |
+
array('value' => 'adminemail', 'title' => __('Admin Email', WDFMInstance(self::PLUGIN)->prefix)),
|
5067 |
+
array('value' => 'useremail', 'title' => __('User Email', WDFMInstance(self::PLUGIN)->prefix)),
|
5068 |
+
array('value' => 'username', 'title' => __('User Name', WDFMInstance(self::PLUGIN)->prefix)),
|
5069 |
+
array('value' => 'pageurl', 'title' => __('Page Url', WDFMInstance(self::PLUGIN)->prefix)),
|
5070 |
+
array('value' => 'verificationlink', 'title' => __('Verification Link', WDFMInstance(self::PLUGIN)->prefix)),
|
5071 |
+
);
|
5072 |
+
$data[__('Misc', WDFMInstance(self::PLUGIN)->prefix)] = apply_filters('fm_placeholders_misc', $data[__('Misc', WDFMInstance(self::PLUGIN)->prefix)]);
|
5073 |
+
return $data;
|
5074 |
+
}
|
5075 |
+
|
5076 |
+
/**
|
5077 |
+
* Get shortcode data.
|
5078 |
+
*
|
5079 |
+
* @return json $data
|
5080 |
+
*/
|
5081 |
+
public static function get_shortcode_data() {
|
5082 |
+
global $wpdb;
|
5083 |
+
$rows = $wpdb->get_results("SELECT `id`, `title` as name FROM `" . $wpdb->prefix . "formmaker`" . (!WDFMInstance(self::PLUGIN)->is_free ? '' : ' WHERE id' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option('contact_form_forms', '') != '' ? get_option('contact_form_forms') : 0) . ') ORDER BY `title`'));
|
5084 |
+
$data = array();
|
5085 |
+
$data['shortcode_prefix'] = WDFMInstance(self::PLUGIN)->is_free == 2 ? 'wd_contact_form' : 'Form';
|
5086 |
+
$data['inputs'][] = array(
|
5087 |
+
'type' => 'select',
|
5088 |
+
'id' => WDFMInstance(self::PLUGIN)->prefix . '_id',
|
5089 |
+
'name' => WDFMInstance(self::PLUGIN)->prefix . '_id',
|
5090 |
+
'shortcode_attibute_name' => 'id',
|
5091 |
+
'options' => $rows,
|
5092 |
+
);
|
5093 |
+
return json_encode($data);
|
5094 |
+
}
|
5095 |
+
|
5096 |
/**
|
5097 |
* Session start if not started.
|
5098 |
*/
|
frontend/controllers/form_maker.php
CHANGED
@@ -4,6 +4,11 @@
|
|
4 |
* Class FMControllerForm_maker
|
5 |
*/
|
6 |
class FMControllerForm_maker_fmc {
|
|
|
|
|
|
|
|
|
|
|
7 |
private $view;
|
8 |
private $model;
|
9 |
private $form_preview = false;
|
@@ -18,10 +23,10 @@ class FMControllerForm_maker_fmc {
|
|
18 |
$this->form_preview = true;
|
19 |
}
|
20 |
|
21 |
-
require_once
|
22 |
$this->model = new FMModelForm_maker_fmc();
|
23 |
|
24 |
-
require_once
|
25 |
$this->view = new FMViewForm_maker_fmc($this->model);
|
26 |
}
|
27 |
|
@@ -46,7 +51,7 @@ class FMControllerForm_maker_fmc {
|
|
46 |
* @return string|void
|
47 |
*/
|
48 |
public function display( $id, $type ) {
|
49 |
-
$fm_settings = get_option('fmc_settings');
|
50 |
if ( $type == 'embedded' ) {
|
51 |
$result = $this->model->showform($id, $type);
|
52 |
if ( !$result ) {
|
@@ -173,7 +178,7 @@ class FMControllerForm_maker_fmc {
|
|
173 |
}
|
174 |
$show_for_admin = current_user_can('administrator') && $form->show_for_admin ? 'true' : 'false';
|
175 |
|
176 |
-
if ( $this->form_preview && ($id ==
|
177 |
$display_on_this = TRUE;
|
178 |
}
|
179 |
|
4 |
* Class FMControllerForm_maker
|
5 |
*/
|
6 |
class FMControllerForm_maker_fmc {
|
7 |
+
/**
|
8 |
+
* PLUGIN = 2 points to Contact Form Maker
|
9 |
+
*/
|
10 |
+
const PLUGIN = 2;
|
11 |
+
|
12 |
private $view;
|
13 |
private $model;
|
14 |
private $form_preview = false;
|
23 |
$this->form_preview = true;
|
24 |
}
|
25 |
|
26 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/frontend/models/form_maker.php";
|
27 |
$this->model = new FMModelForm_maker_fmc();
|
28 |
|
29 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/frontend/views/form_maker.php";
|
30 |
$this->view = new FMViewForm_maker_fmc($this->model);
|
31 |
}
|
32 |
|
51 |
* @return string|void
|
52 |
*/
|
53 |
public function display( $id, $type ) {
|
54 |
+
$fm_settings = get_option(WDFMInstance(self::PLUGIN)->is_free == 2 ? 'fmc_settings' : 'fm_settings');
|
55 |
if ( $type == 'embedded' ) {
|
56 |
$result = $this->model->showform($id, $type);
|
57 |
if ( !$result ) {
|
178 |
}
|
179 |
$show_for_admin = current_user_can('administrator') && $form->show_for_admin ? 'true' : 'false';
|
180 |
|
181 |
+
if ( $this->form_preview && ($id == WDW_FM_Library(self::PLUGIN)->get('wdform_id', 0)) ) {
|
182 |
$display_on_this = TRUE;
|
183 |
}
|
184 |
|
frontend/controllers/verify_email.php
CHANGED
@@ -4,6 +4,11 @@
|
|
4 |
* Class FMControllerVerify_email_fmc
|
5 |
*/
|
6 |
class FMControllerVerify_email_fmc {
|
|
|
|
|
|
|
|
|
|
|
7 |
private $view;
|
8 |
private $model;
|
9 |
|
@@ -11,10 +16,10 @@ class FMControllerVerify_email_fmc {
|
|
11 |
* FMControllerVerify_email constructor.
|
12 |
*/
|
13 |
public function __construct() {
|
14 |
-
require_once
|
15 |
$this->model = new FMModelVerify_email_fmc();
|
16 |
|
17 |
-
require_once
|
18 |
$this->view = new FMViewVerify_email_fmc();
|
19 |
}
|
20 |
|
@@ -23,8 +28,8 @@ class FMControllerVerify_email_fmc {
|
|
23 |
}
|
24 |
|
25 |
public function display() {
|
26 |
-
$gid = (int)
|
27 |
-
$hashInfo =
|
28 |
$hashInfo = explode("@", $hashInfo);
|
29 |
$md5 = $hashInfo[0];
|
30 |
$recipient = isset($hashInfo[1]) ? $hashInfo[1] : '';
|
4 |
* Class FMControllerVerify_email_fmc
|
5 |
*/
|
6 |
class FMControllerVerify_email_fmc {
|
7 |
+
/**
|
8 |
+
* PLUGIN = 2 points to Contact Form Maker
|
9 |
+
*/
|
10 |
+
const PLUGIN = 2;
|
11 |
+
|
12 |
private $view;
|
13 |
private $model;
|
14 |
|
16 |
* FMControllerVerify_email constructor.
|
17 |
*/
|
18 |
public function __construct() {
|
19 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/frontend/models/verify_email.php";
|
20 |
$this->model = new FMModelVerify_email_fmc();
|
21 |
|
22 |
+
require_once WDFMInstance(self::PLUGIN)->plugin_dir . "/frontend/views/verify_email.php";
|
23 |
$this->view = new FMViewVerify_email_fmc();
|
24 |
}
|
25 |
|
28 |
}
|
29 |
|
30 |
public function display() {
|
31 |
+
$gid = (int) WDW_FM_Library(self::PLUGIN)->get('gid', 0);
|
32 |
+
$hashInfo = WDW_FM_Library(self::PLUGIN)->get('h', 0);
|
33 |
$hashInfo = explode("@", $hashInfo);
|
34 |
$md5 = $hashInfo[0];
|
35 |
$recipient = isset($hashInfo[1]) ? $hashInfo[1] : '';
|
frontend/models/form_maker.php
CHANGED
@@ -4,84 +4,88 @@
|
|
4 |
* Class FMModelForm_maker_fmc
|
5 |
*/
|
6 |
class FMModelForm_maker_fmc {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
7 |
|
8 |
-
public $fm_css_content;
|
9 |
/**
|
10 |
-
* @param
|
11 |
* @param string $type
|
12 |
*
|
13 |
* @return array
|
14 |
*/
|
15 |
public function showform( $id, $type = 'embedded' ) {
|
16 |
global $wpdb;
|
17 |
-
$row = $wpdb->get_row($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'formmaker WHERE id="%d"' . (!
|
18 |
|
19 |
if ( !$row ) {
|
20 |
-
echo
|
21 |
return FALSE;
|
22 |
}
|
23 |
|
24 |
if ( $row->type != $type ) {
|
25 |
-
echo
|
26 |
return FALSE;
|
27 |
}
|
28 |
|
29 |
-
$form_preview = (
|
30 |
if ( !$form_preview && !$row->published ) {
|
31 |
// If the form has been unpublished.
|
32 |
-
echo
|
33 |
return FALSE;
|
34 |
}
|
35 |
-
$theme_id =
|
36 |
|
37 |
if ( $theme_id == '' ) {
|
38 |
$theme_id = $row->theme;
|
39 |
}
|
40 |
-
$form_theme = $wpdb->get_row($wpdb->prepare('SELECT * FROM ' . $wpdb->prefix . 'formmaker_themes WHERE id="%d"', $theme_id));
|
41 |
if ( !$form_theme ) {
|
42 |
-
$form_theme = $wpdb->get_row('SELECT * FROM ' . $wpdb->prefix . 'formmaker_themes');
|
43 |
if ( !$form_theme ) {
|
44 |
return FALSE;
|
45 |
}
|
46 |
}
|
47 |
-
$params_decoded = json_decode(html_entity_decode($form_theme->css), TRUE);
|
48 |
if ( $params_decoded != NULL ) {
|
49 |
$old = $form_theme->version == 1;
|
50 |
$form_theme = $params_decoded;
|
51 |
-
}
|
52 |
-
else {
|
53 |
$old = true;
|
54 |
$form_theme = array( "CUPCSS" => $form_theme->css );
|
55 |
}
|
56 |
-
$cssver = isset($form_theme['version']) ? $form_theme['version'] : 1;
|
57 |
-
$this->create_css($theme_id, $form_theme, $old);
|
58 |
-
|
59 |
$wp_upload_dir = wp_upload_dir();
|
60 |
-
$frontend_dir ='/form-maker-frontend/';
|
61 |
-
$fm_style_dir = $wp_upload_dir['basedir'] . $frontend_dir . 'css/fm-style-' . $theme_id . '.css';
|
62 |
-
$fm_style_url = $front_urls['upload_url'] . $frontend_dir . 'css/fm-style-' . $theme_id . '.css';
|
63 |
-
if (
|
64 |
if ( function_exists('wp_add_inline_style') ) {
|
65 |
-
wp_add_inline_style('
|
66 |
-
}
|
67 |
-
else {
|
68 |
echo '<style>' . $this->fm_css_content . '</style>';
|
69 |
}
|
70 |
-
}
|
71 |
-
|
72 |
-
|
73 |
-
wp_enqueue_style('fm-style-' . $theme_id);
|
74 |
}
|
75 |
|
76 |
$label_id = array();
|
77 |
$label_type = array();
|
78 |
-
$label_all = explode('#****#', $row->label_order);
|
79 |
-
$label_all = array_slice($label_all, 0, count($label_all) - 1);
|
80 |
foreach ( $label_all as $key => $label_each ) {
|
81 |
-
$label_id_each = explode('#**id**#', $label_each);
|
82 |
-
array_push($label_id, $label_id_each[0]);
|
83 |
-
$label_order_each = explode('#**label**#', $label_id_each[1]);
|
84 |
-
array_push($label_type, $label_order_each[1]);
|
85 |
}
|
86 |
|
87 |
return array(
|
@@ -98,7 +102,7 @@ class FMModelForm_maker_fmc {
|
|
98 |
* @param $key
|
99 |
*/
|
100 |
public static function set_empty_values_transparent( &$value, $key ) {
|
101 |
-
if ( strpos($key, 'Color') > -1 ) {
|
102 |
/*
|
103 |
* New themes colorpicker conflict with others.
|
104 |
* Remove comments if no '#' is beeing saved with colors.
|
@@ -121,16 +125,16 @@ class FMModelForm_maker_fmc {
|
|
121 |
public function create_css( $theme_id, $form_theme, $old = TRUE, $force_rewrite = FALSE ) {
|
122 |
$wp_upload_dir = wp_upload_dir();
|
123 |
$frontend_dir = '/form-maker-frontend/';
|
124 |
-
if ( !is_dir($wp_upload_dir['basedir'] . $frontend_dir) ) {
|
125 |
-
mkdir($wp_upload_dir['basedir'] . $frontend_dir);
|
126 |
-
file_put_contents($wp_upload_dir['basedir'] . $frontend_dir . 'index.html',
|
127 |
}
|
128 |
-
if ( !is_dir($wp_upload_dir['basedir'] . $frontend_dir . 'css') ) {
|
129 |
-
mkdir($wp_upload_dir['basedir'] . $frontend_dir . 'css');
|
130 |
-
file_put_contents($wp_upload_dir['basedir'] . $frontend_dir . 'css/index.html',
|
131 |
}
|
132 |
-
$frontend_css = $wp_upload_dir['basedir'] . $frontend_dir . 'css/fm-style-' . $theme_id . '.css';
|
133 |
-
if ( $theme_id && !$force_rewrite && file_exists($frontend_css) ) {
|
134 |
return;
|
135 |
}
|
136 |
$prefixes = array(
|
@@ -159,449 +163,437 @@ class FMModelForm_maker_fmc {
|
|
159 |
$border_types = array( 'top', 'left', 'right', 'bottom' );
|
160 |
$borders = array();
|
161 |
foreach ( $prefixes as $prefix ) {
|
162 |
-
$borders[$prefix] = array();
|
163 |
foreach ( $border_types as $border_type ) {
|
164 |
-
if ( isset($form_theme[$prefix . 'Border' . ucfirst($border_type)]) ) {
|
165 |
-
array_push($borders[$prefix], $form_theme[$prefix . 'Border' . ucfirst($border_type)]);
|
166 |
}
|
167 |
}
|
168 |
}
|
169 |
clearstatcache();
|
170 |
$css_content = '';
|
171 |
if ( !$old ) {
|
172 |
-
$css_content = '.fm-form-container.fm-theme' . $theme_id . ' {'.
|
173 |
-
(
|
174 |
-
'}';
|
175 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form {'.
|
176 |
-
( !empty($form_theme['AGPMargin']) ? 'margin:'. $form_theme['AGPMargin'] .';' : '' ).
|
177 |
-
( !empty($form_theme['AGPPadding']) ? 'padding:'. $form_theme['AGPPadding'] .' !important;' : '' ).
|
178 |
-
( (isset($form_theme['AGPBorderRadius']) && $form_theme['AGPBorderRadius'] !== '') ? 'border-radius:'. $form_theme['AGPBorderRadius'] .'px;' : '' ).
|
179 |
-
( !empty($form_theme['AGPBoxShadow']) ? 'box-shadow:'. $form_theme['AGPBoxShadow'] .';' : '' ).
|
180 |
'}';
|
181 |
-
|
182 |
-
|
183 |
-
|
184 |
-
|
185 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
186 |
'}';
|
187 |
break;
|
188 |
-
}
|
189 |
-
|
190 |
-
|
191 |
-
(
|
192 |
-
(
|
193 |
-
( !empty($form_theme['AGPBorderColor']) ? 'border-' . $border . '-color:' . $form_theme['AGPBorderColor'] . ' !important;' : '').
|
194 |
'}';
|
195 |
}
|
196 |
}
|
197 |
}
|
198 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header-bg {'.
|
199 |
-
'display:'. (
|
200 |
-
(
|
201 |
-
(
|
202 |
// 'vertical-align: top;'.
|
203 |
'}';
|
204 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header {'.
|
205 |
-
(
|
206 |
-
(
|
207 |
-
(
|
208 |
-
(
|
209 |
-
(
|
210 |
'}';
|
211 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .image_left_right.fm-header {'.
|
212 |
'padding: 0 !important;' .
|
213 |
'}';
|
214 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .image_left_right > div {'.
|
215 |
-
(
|
216 |
'}';
|
217 |
-
if ( !empty($borders['HP']) ) {
|
218 |
-
foreach ( $borders['HP'] as $border ) {
|
219 |
-
if ( !empty($form_theme['HPBorderType']) && (
|
220 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header {'.
|
221 |
-
'border-' . $border . ':' . $form_theme['HPBorderType'] . ' !important;'.
|
222 |
'}';
|
223 |
break;
|
224 |
-
}
|
225 |
-
|
226 |
-
|
227 |
-
(
|
228 |
-
(
|
229 |
-
( !empty($form_theme['HPBorderColor']) ? 'border-' . $border . '-color:' . $form_theme['HPBorderColor'] . ' !important;' : '').
|
230 |
'}';
|
231 |
}
|
232 |
}
|
233 |
}
|
234 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form.header_left_right .wdform-page-and-images {'.
|
235 |
-
(
|
236 |
'}';
|
237 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form.header_left_right .fm-header {'.
|
238 |
-
(
|
239 |
'}';
|
240 |
-
$css_content .= '.fm-topbar .fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header {'.
|
241 |
-
(
|
242 |
'}';
|
243 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header-title {'.
|
244 |
-
(
|
245 |
-
(
|
246 |
'}';
|
247 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header-description {'.
|
248 |
-
(
|
249 |
-
(
|
250 |
'}';
|
251 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-scrollbox {'.
|
252 |
-
(
|
253 |
'}';
|
254 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div {'.
|
255 |
-
(
|
256 |
-
(
|
257 |
-
(
|
258 |
-
(
|
259 |
-
(
|
260 |
-
(
|
261 |
'}';
|
262 |
-
if ( !empty($borders['MBP']) ) {
|
263 |
-
foreach ( $borders['MBP'] as $border ) {
|
264 |
-
if ( !empty($form_theme['MBPBorderType']) && ($form_theme['MBPBorderType'] == 'inherit' || $form_theme['MBPBorderType'] == 'initial') ) {
|
265 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div {'.
|
266 |
-
'border-' . $border . ':' . $form_theme['MBPBorderType'] . ' !important;'.
|
267 |
'}';
|
268 |
break;
|
269 |
-
}
|
270 |
-
|
271 |
-
|
272 |
-
(
|
273 |
-
(
|
274 |
-
( !empty($form_theme['MBPBorderColor']) ? 'border-' . $border . '-color:' . $form_theme['MBPBorderColor'] . ' !important;' : '').
|
275 |
'}';
|
276 |
}
|
277 |
}
|
278 |
}
|
279 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div:hover {'.
|
280 |
-
(
|
281 |
-
(
|
282 |
'}';
|
283 |
-
if ( $borders['MBHP'] ) {
|
284 |
-
foreach ( $borders['MBHP'] as $border ) {
|
285 |
-
if ( !empty($form_theme['MBHPBorderType']) && ($form_theme['MBHPBorderType'] == 'inherit' || $form_theme['MBHPBorderType'] == 'initial') ) {
|
286 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div:hover {'.
|
287 |
-
'border-' . $border . ':' . $form_theme['MBHPBorderType'] . ' !important;'.
|
288 |
';';
|
289 |
break;
|
290 |
-
}
|
291 |
-
|
292 |
-
|
293 |
-
(
|
294 |
-
(
|
295 |
-
( !empty($form_theme['MBHPBorderColor']) ? 'border-' . $border . '-color:' . $form_theme['MBHPBorderColor'] . ' !important;' : '').
|
296 |
'}';
|
297 |
}
|
298 |
}
|
299 |
}
|
300 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images {'.
|
301 |
-
(
|
302 |
-
(
|
303 |
-
(
|
304 |
-
(
|
305 |
-
(
|
306 |
-
(
|
307 |
-
(
|
308 |
'}';
|
309 |
-
$css_content .= '.fm-topbar .fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images {'.
|
310 |
-
(
|
311 |
'}';
|
312 |
-
if ( $borders['GP'] ) {
|
313 |
-
foreach ( $borders['GP'] as $border ) {
|
314 |
-
if ( !empty($form_theme['GPBorderType']) && (
|
315 |
$css_content .= '
|
316 |
.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images,
|
317 |
-
.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text {'.
|
318 |
-
'border-' . $border .':' . $form_theme['GPBorderType'] . ' !important;'.
|
319 |
'}';
|
320 |
break;
|
321 |
-
}
|
322 |
-
else {
|
323 |
$css_content .= '
|
324 |
.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images,
|
325 |
-
.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text {'.
|
326 |
-
(
|
327 |
-
(
|
328 |
-
(
|
329 |
'}';
|
330 |
}
|
331 |
}
|
332 |
}
|
333 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .mini_label {'.
|
334 |
-
(
|
335 |
-
(
|
336 |
-
(
|
337 |
-
(
|
338 |
-
(
|
339 |
'}';
|
340 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images label {'.
|
341 |
-
(
|
342 |
-
(
|
343 |
'}';
|
344 |
-
if ( !empty($form_theme['GPAlign']) && $form_theme['GPAlign'] == 'center' ) {
|
345 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images {'.
|
346 |
-
'margin:0 auto;'.
|
347 |
'}';
|
348 |
-
}
|
349 |
-
|
350 |
-
|
351 |
-
( !empty($form_theme['GPAlign']) ? 'float:' . $form_theme['GPAlign'] . ';' : '').
|
352 |
'}';
|
353 |
}
|
354 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform_section {'.
|
355 |
-
(
|
356 |
-
(
|
357 |
-
'background: transparent;'.
|
358 |
'}';
|
359 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . '.fm-form .wdform_column {'.
|
360 |
-
(
|
361 |
-
(
|
362 |
'}';
|
363 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .ui-slider {'.
|
364 |
-
(
|
365 |
'}';
|
366 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-scrollbox .fm-scrollbox-form {'.
|
367 |
-
(
|
368 |
'}';
|
369 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-popover .fm-popover-content {'.
|
370 |
-
(
|
371 |
-
(
|
372 |
'}';
|
373 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages.wdform_page_navigation {'.
|
374 |
-
(
|
375 |
'}';
|
376 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform_footer {'.
|
377 |
-
(
|
378 |
-
(
|
379 |
-
(
|
380 |
-
(
|
381 |
-
(
|
382 |
-
(
|
383 |
'}';
|
384 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_active {'.
|
385 |
-
(
|
386 |
-
(
|
387 |
-
(
|
388 |
-
(
|
389 |
-
(
|
390 |
-
(
|
391 |
-
(
|
392 |
-
(
|
393 |
-
(
|
394 |
-
(
|
395 |
'}';
|
396 |
-
if ( $borders['PSAP'] ) {
|
397 |
-
foreach ( $borders['PSAP'] as $border ) {
|
398 |
-
if ( !empty($form_theme['PSAPBorderType']) && ($form_theme['PSAPBorderType'] == 'inherit' || $form_theme['PSAPBorderType'] == 'initial') ) {
|
399 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_active {'.
|
400 |
-
'border:' . $form_theme['PSAPBorderType'] . ' !important;'.
|
401 |
'}';
|
402 |
break;
|
403 |
-
}
|
404 |
-
|
405 |
-
|
406 |
-
(
|
407 |
-
(
|
408 |
-
( !empty($form_theme['PSAPBorderColor']) ? 'border-' . $border . '-color:' . $form_theme['PSAPBorderColor'] . ' !important;' : '').
|
409 |
'}';
|
410 |
}
|
411 |
}
|
412 |
}
|
413 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_deactive {'.
|
414 |
-
(
|
415 |
-
(
|
416 |
-
(
|
417 |
-
(
|
418 |
-
(
|
419 |
-
(
|
420 |
-
(
|
421 |
-
(
|
422 |
-
(
|
423 |
-
(
|
424 |
'}';
|
425 |
-
if ( $borders['PSDP'] ) {
|
426 |
-
foreach ( $borders['PSDP'] as $border ) {
|
427 |
-
if ( !empty($form_theme['PSDPBorderType']) && (
|
428 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_deactive {'.
|
429 |
-
'border:' . $form_theme['PSDPBorderType'] . ' !important;'.
|
430 |
'}';
|
431 |
break;
|
432 |
-
}
|
433 |
-
|
434 |
-
|
435 |
-
(
|
436 |
-
(
|
437 |
-
( !empty($form_theme['PSDPBorderColor']) ? 'border-' . $border . '-color:' . $form_theme['PSDPBorderColor'] . ' !important;' : '').
|
438 |
'}';
|
439 |
}
|
440 |
}
|
441 |
}
|
442 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_active {'.
|
443 |
-
(
|
444 |
-
(
|
445 |
-
(
|
446 |
-
(
|
447 |
-
(
|
448 |
-
(
|
449 |
-
(
|
450 |
-
(
|
451 |
-
(
|
452 |
-
(
|
453 |
'}';
|
454 |
-
if ( $borders['PSAP'] ) {
|
455 |
-
foreach ( $borders['PSAP'] as $border ) {
|
456 |
-
if ( !empty($form_theme['PSAPBorderType']) && ($form_theme['PSAPBorderType'] == 'inherit' || $form_theme['PSAPBorderType'] == 'initial') ) {
|
457 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_active {'.
|
458 |
-
'border:' . $form_theme['PSAPBorderType'] . ' !important;'.
|
459 |
'}';
|
460 |
break;
|
461 |
-
}
|
462 |
-
|
463 |
-
|
464 |
-
(
|
465 |
-
(
|
466 |
-
( !empty($form_theme['PSAPBorderColor']) ? 'border-' . $border . '-color:' . $form_theme['PSAPBorderColor'] . ' !important;' : '').
|
467 |
'}';
|
468 |
}
|
469 |
}
|
470 |
}
|
471 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_deactive {'.
|
472 |
-
(
|
473 |
-
(
|
474 |
-
(
|
475 |
-
(
|
476 |
-
(
|
477 |
-
(
|
478 |
-
(
|
479 |
-
(
|
480 |
-
(
|
481 |
-
(
|
482 |
'}';
|
483 |
-
if ( $borders['PSDP'] ) {
|
484 |
-
foreach ( $borders['PSDP'] as $border ) {
|
485 |
-
if ( !empty($form_theme['PSDPBorderType']) && ($form_theme['PSDPBorderType'] == 'inherit' || $form_theme['PSDPBorderType'] == 'initial') ) {
|
486 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_deactive {'.
|
487 |
-
'border:' . $form_theme['PSDPBorderType'] . ' !important;'.
|
488 |
'}';
|
489 |
break;
|
490 |
-
}
|
491 |
-
|
492 |
-
|
493 |
-
(
|
494 |
-
(
|
495 |
-
( !empty($form_theme['PSDPBorderColor']) ? 'border-' . $border . '-color:' . $form_theme['PSDPBorderColor'] . ' !important;' : '').
|
496 |
'}';
|
497 |
}
|
498 |
}
|
499 |
}
|
500 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-action-buttons {'.
|
501 |
-
(
|
502 |
-
(
|
503 |
-
(
|
504 |
'}';
|
505 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form,
|
506 |
-
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form {'.
|
507 |
-
(
|
508 |
-
(
|
509 |
-
(
|
510 |
-
(
|
511 |
-
(
|
512 |
'}';
|
513 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form {'.
|
514 |
-
(
|
515 |
-
(
|
516 |
-
(
|
517 |
-
(
|
518 |
'}';
|
519 |
-
$for_mini = !empty($form_theme['CBPLeft']) ? 'left' : 'right';
|
520 |
-
$cbp_for_mini = ($form_theme['CBP' . ucfirst($for_mini)]) ? $form_theme['CBP' . ucfirst($for_mini)] : 0;
|
521 |
-
$cbpfontsize = !empty($form_theme['CBPFontSize']) ? (int)
|
522 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .minimize-form {'.
|
523 |
-
(
|
524 |
-
(
|
525 |
-
$for_mini . ': ' . (2 * (int)$cbp_for_mini + $cbpfontsize + 3) . 'px;'.
|
526 |
'}';
|
527 |
-
if ( $borders['CBP'] ) {
|
528 |
-
foreach ( $borders['CBP'] as $border ) {
|
529 |
-
if ( !empty($form_theme['CBPBorderType']) && ($form_theme['CBPBorderType'] == 'inherit' || $form_theme['CBPBorderType'] == 'initial') ) {
|
530 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form,
|
531 |
-
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form {'.
|
532 |
-
'border-' . $border . ':' . $form_theme['CBPBorderType'] . ' !important;'.
|
533 |
'}';
|
534 |
break;
|
535 |
-
}
|
536 |
-
else {
|
537 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form,
|
538 |
-
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form {'.
|
539 |
-
(
|
540 |
-
(
|
541 |
-
(
|
542 |
'}';
|
543 |
}
|
544 |
}
|
545 |
}
|
546 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form:hover,
|
547 |
-
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form:hover {'.
|
548 |
-
(
|
549 |
-
(
|
550 |
-
'border:none;'.
|
551 |
'}';
|
552 |
-
if ( $borders['CBHP'] ) {
|
553 |
-
foreach ( $borders['CBHP'] as $border ) {
|
554 |
-
if ( !empty($form_theme['CBHPBorderType']) && (
|
555 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form:hover,
|
556 |
-
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form:hover {'.
|
557 |
-
'border-' . $border .':' . $form_theme['CBHPBorderType'] . ' !important;'.
|
558 |
'}';
|
559 |
break;
|
560 |
-
}
|
561 |
-
else {
|
562 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form:hover,
|
563 |
-
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form:hover {'.
|
564 |
-
(
|
565 |
-
(
|
566 |
-
(
|
567 |
'}';
|
568 |
}
|
569 |
}
|
570 |
}
|
571 |
-
$user_agent = $_SERVER['HTTP_USER_AGENT'];
|
572 |
-
if ( stripos($user_agent, 'Safari') !== FALSE && stripos($user_agent, 'Chrome') === FALSE ) {
|
573 |
$css_content .= '.fm-popover-container:before {
|
574 |
position:absolute;
|
575 |
}';
|
576 |
}
|
577 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-required {'.
|
578 |
-
(
|
579 |
'}';
|
580 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form input(not:active) {'.
|
581 |
-
(
|
582 |
-
(
|
583 |
'}';
|
584 |
|
585 |
-
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .file-picker {'.
|
586 |
-
|
587 |
-
(
|
588 |
-
(
|
589 |
-
( !empty($form_theme['OPFPos2']) ? 'background-position-y:' . $form_theme['OPFPos2'] . ';' : '').
|
4 |
* Class FMModelForm_maker_fmc
|
5 |
*/
|
6 |
class FMModelForm_maker_fmc {
|
7 |
+
/**
|
8 |
+
* PLUGIN = 2 points to Contact Form Maker
|
9 |
+
*/
|
10 |
+
const PLUGIN = 2;
|
11 |
+
|
12 |
+
public $fm_css_content;
|
13 |
+
|
14 |
+
public $custom_fields = array();
|
15 |
|
|
|
16 |
/**
|
17 |
+
* @param int $id
|
18 |
* @param string $type
|
19 |
*
|
20 |
* @return array
|
21 |
*/
|
22 |
public function showform( $id, $type = 'embedded' ) {
|
23 |
global $wpdb;
|
24 |
+
$row = $wpdb->get_row( $wpdb->prepare( 'SELECT * FROM ' . $wpdb->prefix . 'formmaker WHERE id="%d"' . (!WDFMInstance(self::PLUGIN)->is_free ? '' : ' AND id' . (WDFMInstance(self::PLUGIN)->is_free == 1 ? ' NOT ' : ' ') . 'IN (' . (get_option( 'contact_form_forms', '' ) != '' ? get_option( 'contact_form_forms' ) : 0) . ')'), $id ) );
|
25 |
|
26 |
if ( !$row ) {
|
27 |
+
echo WDW_FM_Library(self::PLUGIN)->message( __( 'Something went wrong when trying to display this form.', WDFMInstance(self::PLUGIN)->prefix ), 'fm-notice-error' );
|
28 |
return FALSE;
|
29 |
}
|
30 |
|
31 |
if ( $row->type != $type ) {
|
32 |
+
echo WDW_FM_Library(self::PLUGIN)->message( __( 'The form you are trying to view does not have Embedded display type.', WDFMInstance(self::PLUGIN)->prefix ), 'fm-notice-error' );
|
33 |
return FALSE;
|
34 |
}
|
35 |
|
36 |
+
$form_preview = (WDW_FM_Library(self::PLUGIN)->get( 'wdform_id', '' ) == $id) ? TRUE : FALSE;
|
37 |
if ( !$form_preview && !$row->published ) {
|
38 |
// If the form has been unpublished.
|
39 |
+
echo WDW_FM_Library(self::PLUGIN)->message( __( 'The form you are trying to view has been unpublished.', WDFMInstance(self::PLUGIN)->prefix ), 'fm-notice-error' );
|
40 |
return FALSE;
|
41 |
}
|
42 |
+
$theme_id = WDW_FM_Library(self::PLUGIN)->get( 'test_theme', '' );
|
43 |
|
44 |
if ( $theme_id == '' ) {
|
45 |
$theme_id = $row->theme;
|
46 |
}
|
47 |
+
$form_theme = $wpdb->get_row( $wpdb->prepare( 'SELECT * FROM ' . $wpdb->prefix . 'formmaker_themes WHERE id="%d"', $theme_id ) );
|
48 |
if ( !$form_theme ) {
|
49 |
+
$form_theme = $wpdb->get_row( 'SELECT * FROM ' . $wpdb->prefix . 'formmaker_themes' );
|
50 |
if ( !$form_theme ) {
|
51 |
return FALSE;
|
52 |
}
|
53 |
}
|
54 |
+
$params_decoded = json_decode( html_entity_decode( $form_theme->css ), TRUE );
|
55 |
if ( $params_decoded != NULL ) {
|
56 |
$old = $form_theme->version == 1;
|
57 |
$form_theme = $params_decoded;
|
58 |
+
} else {
|
|
|
59 |
$old = true;
|
60 |
$form_theme = array( "CUPCSS" => $form_theme->css );
|
61 |
}
|
62 |
+
$cssver = isset( $form_theme[ 'version' ] ) ? $form_theme[ 'version' ] : 1;
|
63 |
+
$this->create_css( $theme_id, $form_theme, $old );
|
64 |
+
$front_urls = WDFMInstance(self::PLUGIN)->front_urls;
|
65 |
$wp_upload_dir = wp_upload_dir();
|
66 |
+
$frontend_dir = '/form-maker-frontend/';
|
67 |
+
$fm_style_dir = $wp_upload_dir[ 'basedir' ] . $frontend_dir . 'css/fm-style-' . $theme_id . '.css';
|
68 |
+
$fm_style_url = $front_urls[ 'upload_url' ] . $frontend_dir . 'css/fm-style-' . $theme_id . '.css';
|
69 |
+
if (!file_exists($fm_style_dir)) {
|
70 |
if ( function_exists('wp_add_inline_style') ) {
|
71 |
+
wp_add_inline_style(WDFMInstance(self::PLUGIN)->handle_prefix . 'frontend', $this->fm_css_content);
|
72 |
+
} else {
|
|
|
73 |
echo '<style>' . $this->fm_css_content . '</style>';
|
74 |
}
|
75 |
+
} else {
|
76 |
+
wp_register_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style-' . $theme_id, $fm_style_url, array(), $cssver);
|
77 |
+
wp_enqueue_style(WDFMInstance(self::PLUGIN)->handle_prefix . '-style-' . $theme_id);
|
|
|
78 |
}
|
79 |
|
80 |
$label_id = array();
|
81 |
$label_type = array();
|
82 |
+
$label_all = explode( '#****#', $row->label_order );
|
83 |
+
$label_all = array_slice( $label_all, 0, count( $label_all ) - 1 );
|
84 |
foreach ( $label_all as $key => $label_each ) {
|
85 |
+
$label_id_each = explode( '#**id**#', $label_each );
|
86 |
+
array_push( $label_id, $label_id_each[ 0 ] );
|
87 |
+
$label_order_each = explode( '#**label**#', $label_id_each[ 1 ] );
|
88 |
+
array_push( $label_type, $label_order_each[ 1 ] );
|
89 |
}
|
90 |
|
91 |
return array(
|
102 |
* @param $key
|
103 |
*/
|
104 |
public static function set_empty_values_transparent( &$value, $key ) {
|
105 |
+
if ( strpos( $key, 'Color' ) > -1 ) {
|
106 |
/*
|
107 |
* New themes colorpicker conflict with others.
|
108 |
* Remove comments if no '#' is beeing saved with colors.
|
125 |
public function create_css( $theme_id, $form_theme, $old = TRUE, $force_rewrite = FALSE ) {
|
126 |
$wp_upload_dir = wp_upload_dir();
|
127 |
$frontend_dir = '/form-maker-frontend/';
|
128 |
+
if ( !is_dir( $wp_upload_dir[ 'basedir' ] . $frontend_dir ) ) {
|
129 |
+
mkdir( $wp_upload_dir[ 'basedir' ] . $frontend_dir );
|
130 |
+
file_put_contents( $wp_upload_dir[ 'basedir' ] . $frontend_dir . 'index.html', WDW_FM_Library(self::PLUGIN)->forbidden_template() );
|
131 |
}
|
132 |
+
if ( !is_dir( $wp_upload_dir[ 'basedir' ] . $frontend_dir . 'css' ) ) {
|
133 |
+
mkdir( $wp_upload_dir[ 'basedir' ] . $frontend_dir . 'css' );
|
134 |
+
file_put_contents( $wp_upload_dir[ 'basedir' ] . $frontend_dir . 'css/index.html', WDW_FM_Library(self::PLUGIN)->forbidden_template() );
|
135 |
}
|
136 |
+
$frontend_css = $wp_upload_dir[ 'basedir' ] . $frontend_dir . 'css/fm-style-' . $theme_id . '.css';
|
137 |
+
if ( $theme_id && !$force_rewrite && file_exists( $frontend_css ) ) {
|
138 |
return;
|
139 |
}
|
140 |
$prefixes = array(
|
163 |
$border_types = array( 'top', 'left', 'right', 'bottom' );
|
164 |
$borders = array();
|
165 |
foreach ( $prefixes as $prefix ) {
|
166 |
+
$borders[ $prefix ] = array();
|
167 |
foreach ( $border_types as $border_type ) {
|
168 |
+
if ( isset( $form_theme[ $prefix . 'Border' . ucfirst( $border_type ) ] ) ) {
|
169 |
+
array_push( $borders[ $prefix ], $form_theme[ $prefix . 'Border' . ucfirst( $border_type ) ] );
|
170 |
}
|
171 |
}
|
172 |
}
|
173 |
clearstatcache();
|
174 |
$css_content = '';
|
175 |
if ( !$old ) {
|
176 |
+
$css_content = '.fm-form-container.fm-theme' . $theme_id . ' {' .
|
177 |
+
(!empty( $form_theme[ 'AGPWidth' ] ) ? 'width:' . $form_theme[ 'AGPWidth' ] . '%;' : '') .
|
|
|
|
|
|
|
|
|
|
|
|
|
178 |
'}';
|
179 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form {' .
|
180 |
+
(!empty( $form_theme[ 'AGPMargin' ] ) ? 'margin:' . $form_theme[ 'AGPMargin' ] . ';' : '') .
|
181 |
+
(!empty( $form_theme[ 'AGPPadding' ] ) ? 'padding:' . $form_theme[ 'AGPPadding' ] . ' !important;' : '') .
|
182 |
+
((isset( $form_theme[ 'AGPBorderRadius' ] ) && $form_theme[ 'AGPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'AGPBorderRadius' ] . 'px;' : '') .
|
183 |
+
(!empty( $form_theme[ 'AGPBoxShadow' ] ) ? 'box-shadow:' . $form_theme[ 'AGPBoxShadow' ] . ';' : '') .
|
184 |
+
'}';
|
185 |
+
if ( !empty( $borders[ 'AGP' ] ) ) {
|
186 |
+
foreach ( $borders[ 'AGP' ] as $border ) {
|
187 |
+
if ( !empty( $form_theme[ 'AGPBorderType' ] ) && ($form_theme[ 'AGPBorderType' ] == 'inherit' || $form_theme[ 'AGPBorderType' ] == 'initial') ) {
|
188 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form {' .
|
189 |
+
'border-' . $border . ': ' . $form_theme[ 'AGPBorderType' ] . ' !important;' .
|
190 |
'}';
|
191 |
break;
|
192 |
+
} else {
|
193 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form {' .
|
194 |
+
((isset( $form_theme[ 'AGPBorderWidth' ] ) && $form_theme[ 'AGPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'AGPBorderWidth' ] . 'px !important;' : '') .
|
195 |
+
(!empty( $form_theme[ 'AGPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'AGPBorderType' ] . ' !important;' : '') .
|
196 |
+
(!empty( $form_theme[ 'AGPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'AGPBorderColor' ] . ' !important;' : '') .
|
|
|
197 |
'}';
|
198 |
}
|
199 |
}
|
200 |
}
|
201 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header-bg {' .
|
202 |
+
'display:' . ((!empty( $form_theme[ 'HPAlign' ] ) && ($form_theme[ 'HPAlign' ] == 'left' || $form_theme[ 'HPAlign' ] == 'right')) ? 'table-cell;' : 'block;') .
|
203 |
+
(!empty( $form_theme[ 'HPWidth' ] ) ? 'width:' . $form_theme[ 'HPWidth' ] . '%;' : '') .
|
204 |
+
(!empty( $form_theme[ 'HPBGColor' ] ) ? 'background-color:' . $form_theme[ 'HPBGColor' ] . ';' : '') .
|
205 |
// 'vertical-align: top;'.
|
206 |
'}';
|
207 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header {' .
|
208 |
+
(!empty( $form_theme[ 'HPWidth' ] ) ? 'width:' . $form_theme[ 'HPWidth' ] . '%;' : '') .
|
209 |
+
(!empty( $form_theme[ 'HPMargin' ] ) ? 'margin:' . $form_theme[ 'HPMargin' ] . ';' : '') .
|
210 |
+
(!empty( $form_theme[ 'HPPadding' ] ) ? 'padding:' . $form_theme[ 'HPPadding' ] . '!important;' : '') .
|
211 |
+
((isset( $form_theme[ 'HPBorderRadius' ] ) && $form_theme[ 'HPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'HPBorderRadius' ] . 'px;' : '') .
|
212 |
+
(!empty( $form_theme[ 'HPTextAlign' ] ) ? 'text-align:' . $form_theme[ 'HPTextAlign' ] . ';' : '') .
|
213 |
'}';
|
214 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .image_left_right.fm-header {' .
|
215 |
'padding: 0 !important;' .
|
216 |
'}';
|
217 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .image_left_right > div {' .
|
218 |
+
(!empty( $form_theme[ 'HPPadding' ] ) ? 'padding:' . $form_theme[ 'HPPadding' ] . '!important;' : '') .
|
219 |
'}';
|
220 |
+
if ( !empty( $borders[ 'HP' ] ) ) {
|
221 |
+
foreach ( $borders[ 'HP' ] as $border ) {
|
222 |
+
if ( !empty( $form_theme[ 'HPBorderType' ] ) && ($form_theme[ 'HPBorderType' ] == 'inherit' || $form_theme[ 'HPBorderType' ] == 'initial') ) {
|
223 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header {' .
|
224 |
+
'border-' . $border . ':' . $form_theme[ 'HPBorderType' ] . ' !important;' .
|
225 |
'}';
|
226 |
break;
|
227 |
+
} else {
|
228 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header {' .
|
229 |
+
((isset( $form_theme[ 'HPBorderWidth' ] ) && $form_theme[ 'HPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'HPBorderWidth' ] . 'px !important;' : '') .
|
230 |
+
(!empty( $form_theme[ 'HPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'HPBorderType' ] . ' !important;' : '') .
|
231 |
+
(!empty( $form_theme[ 'HPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'HPBorderColor' ] . ' !important;' : '') .
|
|
|
232 |
'}';
|
233 |
}
|
234 |
}
|
235 |
}
|
236 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form.header_left_right .wdform-page-and-images {' .
|
237 |
+
(!empty( $form_theme[ 'GPWidth' ] ) ? 'width:' . $form_theme[ 'GPWidth' ] . '%;' : '') .
|
238 |
'}';
|
239 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form.header_left_right .fm-header {' .
|
240 |
+
(!empty( $form_theme[ 'HPWidth' ] ) ? 'width:' . $form_theme[ 'HPWidth' ] . '%;' : '') .
|
241 |
'}';
|
242 |
+
$css_content .= '.fm-topbar .fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header {' .
|
243 |
+
(!empty( $form_theme[ 'HTPWidth' ] ) ? 'width:' . $form_theme[ 'HTPWidth' ] . '% !important;' : '') .
|
244 |
'}';
|
245 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header-title {' .
|
246 |
+
(!empty( $form_theme[ 'HTPFontSize' ] ) ? 'font-size:' . $form_theme[ 'HTPFontSize' ] . 'px;' : '') .
|
247 |
+
(!empty( $form_theme[ 'HTPColor' ] ) ? 'color:' . $form_theme[ 'HTPColor' ] . ';' : '') .
|
248 |
'}';
|
249 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .fm-header-description {' .
|
250 |
+
(!empty( $form_theme[ 'HDPFontSize' ] ) ? 'font-size:' . $form_theme[ 'HDPFontSize' ] . 'px;' : '') .
|
251 |
+
(!empty( $form_theme[ 'HDPColor' ] ) ? 'color:' . $form_theme[ 'HDPColor' ] . ';' : '') .
|
252 |
'}';
|
253 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-scrollbox {' .
|
254 |
+
(!empty( $form_theme[ 'AGPSPWidth' ] ) ? 'width:' . $form_theme[ 'AGPSPWidth' ] . '%;' : '') .
|
255 |
'}';
|
256 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div {' .
|
257 |
+
(!empty( $form_theme[ 'MBPPadding' ] ) ? 'padding:' . $form_theme[ 'MBPPadding' ] . ';' : '') .
|
258 |
+
(!empty( $form_theme[ 'MBPMargin' ] ) ? 'margin:' . $form_theme[ 'MBPMargin' ] . ';' : '') .
|
259 |
+
(!empty( $form_theme[ 'MBPTextAlign' ] ) ? 'text-align:' . $form_theme[ 'MBPTextAlign' ] . ';' : '') .
|
260 |
+
(!empty( $form_theme[ 'MBPFontSize' ] ) ? 'font-size:' . $form_theme[ 'MBPFontSize' ] . 'px;' : '') .
|
261 |
+
(!empty( $form_theme[ 'MBPFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'MBPFontWeight' ] . ';' : '') .
|
262 |
+
((isset( $form_theme[ 'MBPBorderRadius' ] ) && $form_theme[ 'MBPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'MBPBorderRadius' ] . 'px;' : '') .
|
263 |
'}';
|
264 |
+
if ( !empty( $borders[ 'MBP' ] ) ) {
|
265 |
+
foreach ( $borders[ 'MBP' ] as $border ) {
|
266 |
+
if ( !empty( $form_theme[ 'MBPBorderType' ] ) && ($form_theme[ 'MBPBorderType' ] == 'inherit' || $form_theme[ 'MBPBorderType' ] == 'initial') ) {
|
267 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div {' .
|
268 |
+
'border-' . $border . ':' . $form_theme[ 'MBPBorderType' ] . ' !important;' .
|
269 |
'}';
|
270 |
break;
|
271 |
+
} else {
|
272 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div {' .
|
273 |
+
((isset( $form_theme[ 'MBPBorderWidth' ] ) && $form_theme[ 'MBPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'MBPBorderWidth' ] . 'px !important;' : '') .
|
274 |
+
(!empty( $form_theme[ 'MBPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'MBPBorderType' ] . ' !important;' : '') .
|
275 |
+
(!empty( $form_theme[ 'MBPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'MBPBorderColor' ] . ' !important;' : '') .
|
|
|
276 |
'}';
|
277 |
}
|
278 |
}
|
279 |
}
|
280 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div:hover {' .
|
281 |
+
(!empty( $form_theme[ 'MBHPBGColor' ] ) ? 'background-color:' . $form_theme[ 'MBHPBGColor' ] . ';' : '') .
|
282 |
+
(!empty( $form_theme[ 'MBHPColor' ] ) ? 'color:' . $form_theme[ 'MBHPColor' ] . ';' : '') .
|
283 |
'}';
|
284 |
+
if ( $borders[ 'MBHP' ] ) {
|
285 |
+
foreach ( $borders[ 'MBHP' ] as $border ) {
|
286 |
+
if ( !empty( $form_theme[ 'MBHPBorderType' ] ) && ($form_theme[ 'MBHPBorderType' ] == 'inherit' || $form_theme[ 'MBHPBorderType' ] == 'initial') ) {
|
287 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div:hover {' .
|
288 |
+
'border-' . $border . ':' . $form_theme[ 'MBHPBorderType' ] . ' !important;' .
|
289 |
';';
|
290 |
break;
|
291 |
+
} else {
|
292 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text div:hover { ' .
|
293 |
+
((isset( $form_theme[ 'MBHPBorderWidth' ] ) && $form_theme[ 'MBHPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'MBHPBorderWidth' ] . 'px !important;' : '') .
|
294 |
+
(!empty( $form_theme[ 'MBHPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'MBHPBorderType' ] . ' !important;' : '') .
|
295 |
+
(!empty( $form_theme[ 'MBHPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'MBHPBorderColor' ] . ' !important;' : '') .
|
|
|
296 |
'}';
|
297 |
}
|
298 |
}
|
299 |
}
|
300 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images {' .
|
301 |
+
(!empty( $form_theme[ 'GPWidth' ] ) ? 'width:' . $form_theme[ 'GPWidth' ] . '%;' : '') .
|
302 |
+
(!empty( $form_theme[ 'GPMargin' ] ) ? 'margin:' . $form_theme[ 'GPMargin' ] . ';' : '') .
|
303 |
+
(!empty( $form_theme[ 'GPPadding' ] ) ? 'padding:' . $form_theme[ 'GPPadding' ] . ';' : '') .
|
304 |
+
((isset( $form_theme[ 'GPBorderRadius' ] ) && $form_theme[ 'GPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'GPBorderRadius' ] . 'px;' : '') .
|
305 |
+
(!empty( $form_theme[ 'GPFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'GPFontWeight' ] . ';' : '') .
|
306 |
+
(!empty( $form_theme[ 'GPFontSize' ] ) ? 'font-size:' . $form_theme[ 'GPFontSize' ] . 'px;' : '') .
|
307 |
+
(!empty( $form_theme[ 'GPColor' ] ) ? 'color:' . $form_theme[ 'GPColor' ] . ';' : '') .
|
308 |
'}';
|
309 |
+
$css_content .= '.fm-topbar .fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images {' .
|
310 |
+
(!empty( $form_theme[ 'GTPWidth' ] ) ? 'width:' . $form_theme[ 'GTPWidth' ] . '% !important;' : '') .
|
311 |
'}';
|
312 |
+
if ( $borders[ 'GP' ] ) {
|
313 |
+
foreach ( $borders[ 'GP' ] as $border ) {
|
314 |
+
if ( !empty( $form_theme[ 'GPBorderType' ] ) && ($form_theme[ 'GPBorderType' ] == 'inherit' || $form_theme[ 'GPBorderType' ] == 'initial') ) {
|
315 |
$css_content .= '
|
316 |
.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images,
|
317 |
+
.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text {' .
|
318 |
+
'border-' . $border . ':' . $form_theme[ 'GPBorderType' ] . ' !important;' .
|
319 |
'}';
|
320 |
break;
|
321 |
+
} else {
|
|
|
322 |
$css_content .= '
|
323 |
.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images,
|
324 |
+
.fm-form-container.fm-theme' . $theme_id . ' .fm-minimize-text {' .
|
325 |
+
((isset( $form_theme[ 'GPBorderWidth' ] ) && $form_theme[ 'GPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'GPBorderWidth' ] . 'px !important;' : '') .
|
326 |
+
(!empty( $form_theme[ 'GPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'GPBorderType' ] . ' !important;' : '') .
|
327 |
+
(!empty( $form_theme[ 'GPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'GPBorderColor' ] . ' !important;' : '') .
|
328 |
'}';
|
329 |
}
|
330 |
}
|
331 |
}
|
332 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .mini_label {' .
|
333 |
+
(!empty( $form_theme[ 'GPMLMargin' ] ) ? 'margin:' . $form_theme[ 'GPMLMargin' ] . ';' : '') .
|
334 |
+
(!empty( $form_theme[ 'GPMLPadding' ] ) ? 'padding:' . $form_theme[ 'GPMLPadding' ] . ' !important;' : '') .
|
335 |
+
(!empty( $form_theme[ 'GPMLFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'GPMLFontWeight' ] . ';' : '') .
|
336 |
+
(!empty( $form_theme[ 'GPMLFontSize' ] ) ? 'font-size:' . $form_theme[ 'GPMLFontSize' ] . 'px !important;' : '') .
|
337 |
+
(!empty( $form_theme[ 'GPMLColor' ] ) ? 'color:' . $form_theme[ 'GPMLColor' ] . ';' : '') .
|
338 |
'}';
|
339 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images label {' .
|
340 |
+
(!empty( $form_theme[ 'GPFontSize' ] ) ? 'font-size:' . $form_theme[ 'GPFontSize' ] . 'px;' : '') .
|
341 |
+
(!empty( $form_theme[ 'GPColor' ] ) ? 'color:' . $form_theme[ 'GPColor' ] . ';' : '') .
|
342 |
'}';
|
343 |
+
if ( !empty( $form_theme[ 'GPAlign' ] ) && $form_theme[ 'GPAlign' ] == 'center' ) {
|
344 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images {' .
|
345 |
+
'margin:0 auto;' .
|
346 |
'}';
|
347 |
+
} else {
|
348 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-page-and-images {' .
|
349 |
+
(!empty( $form_theme[ 'GPAlign' ] ) ? 'float:' . $form_theme[ 'GPAlign' ] . ';' : '') .
|
|
|
350 |
'}';
|
351 |
}
|
352 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform_section {' .
|
353 |
+
(!empty( $form_theme[ 'SEPMargin' ] ) ? 'margin:' . $form_theme[ 'SEPMargin' ] . ';' : '') .
|
354 |
+
(!empty( $form_theme[ 'SEPPadding' ] ) ? 'padding:' . $form_theme[ 'SEPPadding' ] . ';' : '') .
|
355 |
+
'background: transparent;' .
|
356 |
'}';
|
357 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . '.fm-form .wdform_column {' .
|
358 |
+
(!empty( $form_theme[ 'COPMargin' ] ) ? 'margin:' . $form_theme[ 'COPMargin' ] . ';' : '') .
|
359 |
+
(!empty( $form_theme[ 'COPPadding' ] ) ? 'padding:' . $form_theme[ 'COPPadding' ] . ';' : '') .
|
360 |
'}';
|
361 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .ui-slider {' .
|
362 |
+
(!empty( $form_theme[ 'IPBGColor' ] ) ? 'background:' . $form_theme[ 'IPBGColor' ] . ' !important;' : '') .
|
363 |
'}';
|
364 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-scrollbox .fm-scrollbox-form {' .
|
365 |
+
(!empty( $form_theme[ 'AGPMargin' ] ) ? 'margin:' . $form_theme[ 'AGPMargin' ] . ';' : '') .
|
366 |
'}';
|
367 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-popover .fm-popover-content {' .
|
368 |
+
(!empty( $form_theme[ 'AGPMargin' ] ) ? 'margin:' . $form_theme[ 'AGPMargin' ] . ';' : '') .
|
369 |
+
(!empty( $form_theme[ 'AGPWidth' ] ) ? 'width:' . $form_theme[ 'AGPWidth' ] . '%;' : '') .
|
370 |
'}';
|
371 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages.wdform_page_navigation {' .
|
372 |
+
(!empty( $form_theme[ 'AGPMargin' ] ) ? 'margin:' . $form_theme[ 'AGPMargin' ] . '%;' : '') .
|
373 |
'}';
|
374 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform_footer {' .
|
375 |
+
(!empty( $form_theme[ 'FPWidth' ] ) ? 'width:' . $form_theme[ 'FPWidth' ] . '%;' : '') .
|
376 |
+
(!empty( $form_theme[ 'FPMargin' ] ) ? 'margin:' . $form_theme[ 'FPMargin' ] . ';' : '') .
|
377 |
+
(!empty( $form_theme[ 'FPPadding' ] ) ? 'padding:' . $form_theme[ 'FPPadding' ] . ';' : '') .
|
378 |
+
(!empty( $form_theme[ 'GPFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'GPFontWeight' ] . ';' : '') .
|
379 |
+
(!empty( $form_theme[ 'GPFontSize' ] ) ? 'font-size:' . $form_theme[ 'GPFontSize' ] . 'px;' : '') .
|
380 |
+
(!empty( $form_theme[ 'GPColor' ] ) ? 'color:' . $form_theme[ 'GPColor' ] . ';' : '') .
|
381 |
'}';
|
382 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_active {' .
|
383 |
+
(!empty( $form_theme[ 'PSAPMargin' ] ) ? 'margin:' . $form_theme[ 'PSAPMargin' ] . ';' : '') .
|
384 |
+
(!empty( $form_theme[ 'PSAPPadding' ] ) ? 'padding:' . $form_theme[ 'PSAPPadding' ] . ';' : '') .
|
385 |
+
(!empty( $form_theme[ 'PSAPWidth' ] ) ? 'width:' . $form_theme[ 'PSAPWidth' ] . 'px;' : '') .
|
386 |
+
(!empty( $form_theme[ 'PSAPHeight' ] ) ? 'height:' . $form_theme[ 'PSAPHeight' ] . 'px;' : '') .
|
387 |
+
(!empty( $form_theme[ 'PSAPBGColor' ] ) ? 'background-color:' . $form_theme[ 'PSAPBGColor' ] . ';' : '') .
|
388 |
+
(!empty( $form_theme[ 'PSAPFontSize' ] ) ? 'font-size:' . $form_theme[ 'PSAPFontSize' ] . 'px;' : '') .
|
389 |
+
(!empty( $form_theme[ 'PSAPFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'PSAPFontWeight' ] . ';' : '') .
|
390 |
+
(!empty( $form_theme[ 'PSAPColor' ] ) ? 'color:' . $form_theme[ 'PSAPColor' ] . ';' : '') .
|
391 |
+
(!empty( $form_theme[ 'PSAPLineHeight' ] ) ? 'line-height:' . $form_theme[ 'PSAPLineHeight' ] . 'px;' : '') .
|
392 |
+
((isset( $form_theme[ 'PSAPBorderRadius' ] ) && $form_theme[ 'PSAPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'PSAPBorderRadius' ] . 'px;' : '') .
|
393 |
'}';
|
394 |
+
if ( $borders[ 'PSAP' ] ) {
|
395 |
+
foreach ( $borders[ 'PSAP' ] as $border ) {
|
396 |
+
if ( !empty( $form_theme[ 'PSAPBorderType' ] ) && ($form_theme[ 'PSAPBorderType' ] == 'inherit' || $form_theme[ 'PSAPBorderType' ] == 'initial') ) {
|
397 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_active {' .
|
398 |
+
'border:' . $form_theme[ 'PSAPBorderType' ] . ' !important;' .
|
399 |
'}';
|
400 |
break;
|
401 |
+
} else {
|
402 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_active {' .
|
403 |
+
((isset( $form_theme[ 'PSAPBorderWidth' ] ) && $form_theme[ 'PSAPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'PSAPBorderWidth' ] . 'px !important;' : '') .
|
404 |
+
(!empty( $form_theme[ 'PSAPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'PSAPBorderType' ] . ' !important;' : '') .
|
405 |
+
(!empty( $form_theme[ 'PSAPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'PSAPBorderColor' ] . ' !important;' : '') .
|
|
|
406 |
'}';
|
407 |
}
|
408 |
}
|
409 |
}
|
410 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_deactive {' .
|
411 |
+
(!empty( $form_theme[ 'PSDPBGColor' ] ) ? 'background-color:' . $form_theme[ 'PSDPBGColor' ] . ';' : '') .
|
412 |
+
(!empty( $form_theme[ 'PSAPWidth' ] ) ? 'width:' . $form_theme[ 'PSAPWidth' ] . 'px;' : '') .
|
413 |
+
(!empty( $form_theme[ 'PSDPHeight' ] ) ? 'height:' . $form_theme[ 'PSDPHeight' ] . 'px;' : '') .
|
414 |
+
(!empty( $form_theme[ 'PSDPMargin' ] ) ? 'margin:' . $form_theme[ 'PSDPMargin' ] . ';' : '') .
|
415 |
+
(!empty( $form_theme[ 'PSDPPadding' ] ) ? 'padding:' . $form_theme[ 'PSDPPadding' ] . ';' : '') .
|
416 |
+
(!empty( $form_theme[ 'PSDPLineHeight' ] ) ? 'line-height:' . $form_theme[ 'PSDPLineHeight' ] . 'px;' : '') .
|
417 |
+
((isset( $form_theme[ 'PSAPBorderRadius' ] ) && $form_theme[ 'PSAPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'PSAPBorderRadius' ] . 'px;' : '') .
|
418 |
+
(!empty( $form_theme[ 'PSDPFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'PSDPFontWeight' ] . ';' : '') .
|
419 |
+
(!empty( $form_theme[ 'PSDPFontSize' ] ) ? 'font-size:' . $form_theme[ 'PSDPFontSize' ] . 'px;' : '') .
|
420 |
+
(!empty( $form_theme[ 'PSDPColor' ] ) ? 'color:' . $form_theme[ 'PSDPColor' ] . ';' : '') .
|
421 |
'}';
|
422 |
+
if ( $borders[ 'PSDP' ] ) {
|
423 |
+
foreach ( $borders[ 'PSDP' ] as $border ) {
|
424 |
+
if ( !empty( $form_theme[ 'PSDPBorderType' ] ) && ($form_theme[ 'PSDPBorderType' ] == 'inherit' || $form_theme[ 'PSDPBorderType' ] == 'initial') ) {
|
425 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_deactive {' .
|
426 |
+
'border:' . $form_theme[ 'PSDPBorderType' ] . ' !important;' .
|
427 |
'}';
|
428 |
break;
|
429 |
+
} else {
|
430 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_deactive {' .
|
431 |
+
((isset( $form_theme[ 'PSDPBorderWidth' ] ) && $form_theme[ 'PSDPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'PSDPBorderWidth' ] . 'px !important;' : '') .
|
432 |
+
(!empty( $form_theme[ 'PSDPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'PSDPBorderType' ] . ' !important;' : '') .
|
433 |
+
(!empty( $form_theme[ 'PSDPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'PSDPBorderColor' ] . ' !important;' : '') .
|
|
|
434 |
'}';
|
435 |
}
|
436 |
}
|
437 |
}
|
438 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_active {' .
|
439 |
+
(!empty( $form_theme[ 'PSAPWidth' ] ) ? 'width:' . $form_theme[ 'PSAPWidth' ] . 'px;' : '') .
|
440 |
+
(!empty( $form_theme[ 'PSAPHeight' ] ) ? 'height:' . $form_theme[ 'PSAPHeight' ] . 'px;' : '') .
|
441 |
+
(!empty( $form_theme[ 'PSAPMargin' ] ) ? 'margin:' . $form_theme[ 'PSAPMargin' ] . ';' : '') .
|
442 |
+
(!empty( $form_theme[ 'PSAPPadding' ] ) ? 'padding:' . $form_theme[ 'PSAPPadding' ] . ';' : '') .
|
443 |
+
(!empty( $form_theme[ 'PSAPBGColor' ] ) ? 'background-color:' . $form_theme[ 'PSAPBGColor' ] . ';' : '') .
|
444 |
+
(!empty( $form_theme[ 'PSAPFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'PSAPFontWeight' ] . ';' : '') .
|
445 |
+
(!empty( $form_theme[ 'PSAPFontSize' ] ) ? 'font-size:' . $form_theme[ 'PSAPFontSize' ] . 'px;' : '') .
|
446 |
+
(!empty( $form_theme[ 'PSAPColor' ] ) ? 'color:' . $form_theme[ 'PSAPColor' ] . ';' : '') .
|
447 |
+
(!empty( $form_theme[ 'PSAPLineHeight' ] ) ? 'line-height:' . $form_theme[ 'PSAPLineHeight' ] . 'px;' : '') .
|
448 |
+
((isset( $form_theme[ 'PSAPBorderRadius' ] ) && $form_theme[ 'PSAPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'PSAPBorderRadius' ] . 'px;' : '') .
|
449 |
'}';
|
450 |
+
if ( $borders[ 'PSAP' ] ) {
|
451 |
+
foreach ( $borders[ 'PSAP' ] as $border ) {
|
452 |
+
if ( !empty( $form_theme[ 'PSAPBorderType' ] ) && ($form_theme[ 'PSAPBorderType' ] == 'inherit' || $form_theme[ 'PSAPBorderType' ] == 'initial') ) {
|
453 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_active {' .
|
454 |
+
'border:' . $form_theme[ 'PSAPBorderType' ] . ' !important;' .
|
455 |
'}';
|
456 |
break;
|
457 |
+
} else {
|
458 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_active {' .
|
459 |
+
((isset( $form_theme[ 'PSAPBorderWidth' ] ) && $form_theme[ 'PSAPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'PSAPBorderWidth' ] . 'px !important;' : '') .
|
460 |
+
(!empty( $form_theme[ 'PSAPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'PSAPBorderType' ] . ' !important;' : '') .
|
461 |
+
(!empty( $form_theme[ 'PSAPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'PSAPBorderColor' ] . ' !important;' : '') .
|
|
|
462 |
'}';
|
463 |
}
|
464 |
}
|
465 |
}
|
466 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_deactive {' .
|
467 |
+
(!empty( $form_theme[ 'PPAPWidth' ] ) ? 'width:' . $form_theme[ 'PPAPWidth' ] . ';' : '') .
|
468 |
+
(!empty( $form_theme[ 'PSDPHeight' ] ) ? 'height:' . $form_theme[ 'PSDPHeight' ] . 'px;' : '') .
|
469 |
+
(!empty( $form_theme[ 'PSDPMargin' ] ) ? 'margin:' . $form_theme[ 'PSDPMargin' ] . ';' : '') .
|
470 |
+
(!empty( $form_theme[ 'PSDPPadding' ] ) ? 'padding:' . $form_theme[ 'PSDPPadding' ] . ';' : '') .
|
471 |
+
(!empty( $form_theme[ 'PSDPBGColor' ] ) ? 'background-color:' . $form_theme[ 'PSDPBGColor' ] . ';' : '') .
|
472 |
+
(!empty( $form_theme[ 'PSDPFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'PSDPFontWeight' ] . ';' : '') .
|
473 |
+
(!empty( $form_theme[ 'PSDPFontSize' ] ) ? 'font-size:' . $form_theme[ 'PSDPFontSize' ] . 'px;' : '') .
|
474 |
+
(!empty( $form_theme[ 'PSDPColor' ] ) ? 'color:' . $form_theme[ 'PSDPColor' ] . ';' : '') .
|
475 |
+
(!empty( $form_theme[ 'PSDPLineHeight' ] ) ? 'line-height:' . $form_theme[ 'PSDPLineHeight' ] . 'px;' : '') .
|
476 |
+
((isset( $form_theme[ 'PSDPBorderRadius' ] ) && $form_theme[ 'PSDPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'PSDPBorderRadius' ] . 'px;' : '') .
|
477 |
'}';
|
478 |
+
if ( $borders[ 'PSDP' ] ) {
|
479 |
+
foreach ( $borders[ 'PSDP' ] as $border ) {
|
480 |
+
if ( !empty( $form_theme[ 'PSDPBorderType' ] ) && ($form_theme[ 'PSDPBorderType' ] == 'inherit' || $form_theme[ 'PSDPBorderType' ] == 'initial') ) {
|
481 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_deactive {' .
|
482 |
+
'border:' . $form_theme[ 'PSDPBorderType' ] . ' !important;' .
|
483 |
'}';
|
484 |
break;
|
485 |
+
} else {
|
486 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-pages .page_percentage_deactive {' .
|
487 |
+
((isset( $form_theme[ 'PSDPBorderWidth' ] ) && $form_theme[ 'PSDPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'PSDPBorderWidth' ] . 'px !important;' : '') .
|
488 |
+
(!empty( $form_theme[ 'PSDPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'PSDPBorderType' ] . ' !important;' : '') .
|
489 |
+
(!empty( $form_theme[ 'PSDPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'PSDPBorderColor' ] . ' !important;' : '') .
|
|
|
490 |
'}';
|
491 |
}
|
492 |
}
|
493 |
}
|
494 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-action-buttons {' .
|
495 |
+
(!empty( $form_theme[ 'CBPFontWeight' ] ) ? 'font-weight:' . $form_theme[ 'CBPFontWeight' ] . ';' : '') .
|
496 |
+
(!empty( $form_theme[ 'CBPFontSize' ] ) ? 'font-size:' . $form_theme[ 'CBPFontSize' ] . 'px;' : '') .
|
497 |
+
(!empty( $form_theme[ 'CBPColor' ] ) ? 'color:' . $form_theme[ 'CBPColor' ] . ';' : '') .
|
498 |
'}';
|
499 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form,
|
500 |
+
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form {' .
|
501 |
+
(!empty( $form_theme[ 'CBPMargin' ] ) ? 'margin:' . $form_theme[ 'CBPMargin' ] . ';' : '') .
|
502 |
+
(!empty( $form_theme[ 'CBPPadding' ] ) ? 'padding:' . $form_theme[ 'CBPPadding' ] . ';' : '') .
|
503 |
+
(!empty( $form_theme[ 'CBPPosition' ] ) ? 'position:' . $form_theme[ 'CBPPosition' ] . ';' : '') .
|
504 |
+
(!empty( $form_theme[ 'CBPBGColor' ] ) ? 'background-color:' . $form_theme[ 'CBPBGColor' ] . ';' : '') .
|
505 |
+
((isset( $form_theme[ 'CBPBorderRadius' ] ) && $form_theme[ 'CBPBorderRadius' ] !== '') ? 'border-radius:' . $form_theme[ 'CBPBorderRadius' ] . 'px;' : '') .
|
506 |
'}';
|
507 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form {' .
|
508 |
+
(!empty( $form_theme[ 'CBPTop' ] ) ? 'top:' . $form_theme[ 'CBPTop' ] . ';' : '') .
|
509 |
+
(!empty( $form_theme[ 'CBPRight' ] ) ? 'right:' . $form_theme[ 'CBPRight' ] . ';' : '') .
|
510 |
+
(!empty( $form_theme[ 'CBPBottom' ] ) ? 'bottom:' . $form_theme[ 'CBPBottom' ] . ';' : '') .
|
511 |
+
(!empty( $form_theme[ 'CBPLeft' ] ) ? 'left:' . $form_theme[ 'CBPLeft' ] . ';' : '') .
|
512 |
'}';
|
513 |
+
$for_mini = !empty( $form_theme[ 'CBPLeft' ] ) ? 'left' : 'right';
|
514 |
+
$cbp_for_mini = ($form_theme[ 'CBP' . ucfirst( $for_mini ) ]) ? $form_theme[ 'CBP' . ucfirst( $for_mini ) ] : 0;
|
515 |
+
$cbpfontsize = !empty( $form_theme[ 'CBPFontSize' ] ) ? (int)$form_theme[ 'CBPFontSize' ] : 0;
|
516 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .minimize-form {' .
|
517 |
+
(!empty( $form_theme[ 'CBPTop' ] ) ? 'top:' . $form_theme[ 'CBPTop' ] . ';' : '') .
|
518 |
+
(!empty( $form_theme[ 'CBPBottom' ] ) ? 'bottom:' . $form_theme[ 'CBPBottom' ] . ';' : '') .
|
519 |
+
$for_mini . ': ' . (2 * (int)$cbp_for_mini + $cbpfontsize + 3) . 'px;' .
|
520 |
'}';
|
521 |
+
if ( $borders[ 'CBP' ] ) {
|
522 |
+
foreach ( $borders[ 'CBP' ] as $border ) {
|
523 |
+
if ( !empty( $form_theme[ 'CBPBorderType' ] ) && ($form_theme[ 'CBPBorderType' ] == 'inherit' || $form_theme[ 'CBPBorderType' ] == 'initial') ) {
|
524 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form,
|
525 |
+
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form {' .
|
526 |
+
'border-' . $border . ':' . $form_theme[ 'CBPBorderType' ] . ' !important;' .
|
527 |
'}';
|
528 |
break;
|
529 |
+
} else {
|
|
|
530 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form,
|
531 |
+
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form {' .
|
532 |
+
((isset( $form_theme[ 'CBPBorderWidth' ] ) && $form_theme[ 'CBPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'CBPBorderWidth' ] . 'px !important;' : '') .
|
533 |
+
(!empty( $form_theme[ 'CBPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'CBPBorderType' ] . ' !important;' : '') .
|
534 |
+
(!empty( $form_theme[ 'CBPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'CBPBorderColor' ] . ' !important;' : '') .
|
535 |
'}';
|
536 |
}
|
537 |
}
|
538 |
}
|
539 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form:hover,
|
540 |
+
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form:hover {' .
|
541 |
+
(!empty( $form_theme[ 'CBHPBGColor' ] ) ? 'background:' . $form_theme[ 'CBHPBGColor' ] . ';' : '') .
|
542 |
+
(!empty( $form_theme[ 'CBHPColor' ] ) ? 'color:' . $form_theme[ 'CBHPColor' ] . ';' : '') .
|
543 |
+
'border:none;' .
|
544 |
'}';
|
545 |
+
if ( $borders[ 'CBHP' ] ) {
|
546 |
+
foreach ( $borders[ 'CBHP' ] as $border ) {
|
547 |
+
if ( !empty( $form_theme[ 'CBHPBorderType' ] ) && ($form_theme[ 'CBHPBorderType' ] == 'inherit' || $form_theme[ 'CBHPBorderType' ] == 'initial') ) {
|
548 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form:hover,
|
549 |
+
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form:hover {' .
|
550 |
+
'border-' . $border . ':' . $form_theme[ 'CBHPBorderType' ] . ' !important;' .
|
551 |
'}';
|
552 |
break;
|
553 |
+
} else {
|
|
|
554 |
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .closing-form:hover,
|
555 |
+
.fm-form-container.fm-theme' . $theme_id . ' .minimize-form:hover {' .
|
556 |
+
((isset( $form_theme[ 'CBHPBorderWidth' ] ) && $form_theme[ 'CBHPBorderWidth' ] !== '') ? 'border-' . $border . ':' . $form_theme[ 'CBHPBorderWidth' ] . 'px !important;' : '') .
|
557 |
+
(!empty( $form_theme[ 'CBHPBorderType' ] ) ? 'border-' . $border . '-style:' . $form_theme[ 'CBHPBorderType' ] . ' !important;' : '') .
|
558 |
+
(!empty( $form_theme[ 'CBHPBorderColor' ] ) ? 'border-' . $border . '-color:' . $form_theme[ 'CBHPBorderColor' ] . ' !important;' : '') .
|
559 |
'}';
|
560 |
}
|
561 |
}
|
562 |
}
|
563 |
+
$user_agent = $_SERVER[ 'HTTP_USER_AGENT' ];
|
564 |
+
if ( stripos( $user_agent, 'Safari' ) !== FALSE && stripos( $user_agent, 'Chrome' ) === FALSE ) {
|
565 |
$css_content .= '.fm-popover-container:before {
|
566 |
position:absolute;
|
567 |
}';
|
568 |
}
|
569 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .wdform-required {' .
|
570 |
+
(!empty( $form_theme[ 'OPRColor' ] ) ? 'color:' . $form_theme[ 'OPRColor' ] . ';' : '') .
|
571 |
'}';
|
572 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form input(not:active) {' .
|
573 |
+
(!empty( $form_theme[ 'OPFontStyle' ] ) ? 'font-style:' . $form_theme[ 'OPFontStyle' ] . ';' : '') .
|
574 |
+
(!empty( $form_theme[ 'OPDeInputColor' ] ) ? 'color:' . $form_theme[ 'OPDeInputColor' ] . ' !important;' : '') .
|
575 |
'}';
|
576 |
|
577 |
+
$css_content .= '.fm-form-container.fm-theme' . $theme_id . ' .fm-form .file-picker {' .
|
578 |
+
(!empty( $form_theme[ 'OPFBgUrl' ] ) ? 'display: inline-block; width: 22px; height: 22px; background: url("' . WDFMInstance(self::PLUGIN)->plugin_url . '/' . $form_theme[ 'OPFBgUrl' ] . '");' : '') .
|
579 |
+
(!empty( $form_theme[ 'OPFBGRepeat' ] ) ? 'background-repeat:' . $form_theme[ 'OPFBGRepeat' ] . ';' : '') .
|
580 |
+
(!empty( $form_theme[ '
|
|