PluginProbe
Bit Form – Contact Form, Payment Forms, Multi Step Forms, Calculator & Custom Form Builder / 2.15.3
Bit Form – Contact Form, Payment Forms, Multi Step Forms, Calculator & Custom Form Builder v2.15.3
3.3.1 V-3.3.0 3.2.2 3.2.1 3.2.0 3.1.4 3.1.3 3.1.2 3.1.1 3.1.0 V3.0.3 V3.0.2 -3.0.1 V_3.0.0 1.1.1 1.1.8 1.2 1.3 1.4 1.4.18 1.5.2 1.9 2.0 2.10.0 2.10.1 All 138 releases
← All changes | includes/Core/Util/FormDuplicateHelper.php +4 -4 2.10.22.15.3 View file →
@@ -24,9 +24,9 @@
24 24 $formData = (object)[];
25 25 $formData->form_id = $newFormId;
26 26 $formData->fields = (object) $data['form_content']['fields'];
27 27 $formData->layout = $data['form_content']['layout'];
28 - $formData->nestedLayout = $data['form_content']['nestedLayout'];
28 + $formData->nestedLayouts = $data['form_content']['nestedLayout'];
29 29 $formData->form_name = $formName;
30 30 $formData->formInfo = isset($data['form_content']['formInfo']) ? $data['form_content']['formInfo'] : (object)[];
31 31
32 32 if (isset($data['formSettings'])) {
@@ -49,9 +49,9 @@
49 49 $formData->formSettings = (object)$formSettings;
50 50 }
51 51
52 52 if (isset($formSettings['pdfTem'])) {
53 - $pdfTem = !is_string($formSettings['pdfTem']) ? json_encode($formSettings['pdfTem']) : $formSettings['pdfTem'];
53 + $pdfTem = !is_string($formSettings['pdfTem']) ? wp_json_encode($formSettings['pdfTem']) : $formSettings['pdfTem'];
54 54 $formSettings['pdfTem'] = json_decode(\preg_replace('/(\${bf?)(\d+)([- \d]+\})/', '${1}' . $newFormId . '$3', $pdfTem));
55 55 $formData->formSettings = (object)$formSettings;
56 56 }
57 57 }
@@ -95,15 +95,15 @@
95 95 }
96 96
97 97 $formData->customCode = (object) [];
98 98 if (isset($data['customCode']->customCss)) {
99 - $customCss = !is_string($data['customCode']->customCss) ? \json_encode($data['customCode']->customCss) : $data['customCode']->customCss;
99 + $customCss = !is_string($data['customCode']->customCss) ? wp_json_encode($data['customCode']->customCss) : $data['customCode']->customCss;
100 100 $customCss = \preg_replace('/(\${bf?)(\d+)([- \d]+\})/', '${1}' . $newFormId . '$3', $customCss);
101 101 $formData->customCode->customCss = \preg_replace('/(\"bf?)(\d+)([- \d]+\")/', '${1}' . $newFormId . '$3', $customCss);
102 102 }
103 103
104 104 if (isset($data['customCode']->customJs)) {
105 - $customJs = !is_string($data['customCode']->customJs) ? \json_encode($data['customCode']->customJs) : $data['customCode']->customJs;
105 + $customJs = !is_string($data['customCode']->customJs) ? wp_json_encode($data['customCode']->customJs) : $data['customCode']->customJs;
106 106 $customJs = \preg_replace('/(\${bf?)(\d+)([- \d]+\})/', '${1}' . $newFormId . '$3', $customJs);
107 107 $formData->customCode->customJs = \preg_replace('/(\"bf?)(\d+)([- \d]+\")/', '${1}' . $newFormId . '$3', $customJs);
108 108 }
109 109 return $formData;