Version Description
- New feature for editing submissions
- New feature for adding submissions from admin area
Download this release
Release Info
Developer | codepeople |
Plugin | Contact Form Email |
Version | 1.2.86 |
Comparing to | |
See all releases |
Code changes from version 1.2.85 to 1.2.86
- README.txt +7 -2
- cp-admin-int-add-booking.inc.php +46 -0
- cp-admin-int-edit-booking.inc.php +46 -0
- cp-admin-int-list.inc.php +8 -2
- cp-admin-int-message-list.inc.php +5 -0
- cp-main-class.inc.php +121 -11
- cp-public-int.inc.php +8 -2
- form-to-email.php +1 -1
- js/fbuilderf.jquery.js +32 -165
README.txt
CHANGED
@@ -456,6 +456,10 @@ When you click a field already added into the contact form builder area, you can
|
|
456 |
|
457 |
== Changelog ==
|
458 |
|
|
|
|
|
|
|
|
|
459 |
= 1.2.85 =
|
460 |
* Fixed conflict with Yoast SEO
|
461 |
|
@@ -1014,5 +1018,6 @@ When you click a field already added into the contact form builder area, you can
|
|
1014 |
|
1015 |
== Upgrade Notice ==
|
1016 |
|
1017 |
-
= 1.2.
|
1018 |
-
*
|
|
456 |
|
457 |
== Changelog ==
|
458 |
|
459 |
+
= 1.2.86 =
|
460 |
+
* New feature for editing submissions
|
461 |
+
* New feature for adding submissions from admin area
|
462 |
+
|
463 |
= 1.2.85 =
|
464 |
* Fixed conflict with Yoast SEO
|
465 |
|
1018 |
|
1019 |
== Upgrade Notice ==
|
1020 |
|
1021 |
+
= 1.2.86 =
|
1022 |
+
* New feature for editing submissions
|
1023 |
+
* New feature for adding submissions from admin area
|
cp-admin-int-add-booking.inc.php
ADDED
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
$this->item = intval($_GET["cal"]);
|
4 |
+
|
5 |
+
$current_user = wp_get_current_user();
|
6 |
+
$current_user_access = current_user_can('edit_pages');
|
7 |
+
|
8 |
+
if ( !is_admin() || (!$current_user_access && !@in_array($current_user->ID, unserialize($this->get_option("cp_user_access","")))))
|
9 |
+
{
|
10 |
+
echo 'Direct access not allowed.';
|
11 |
+
exit;
|
12 |
+
}
|
13 |
+
|
14 |
+
$message = '';
|
15 |
+
|
16 |
+
if ( 'POST' == $_SERVER['REQUEST_METHOD'] && isset( $_POST[$this->prefix.'_pform_process'] ) )
|
17 |
+
$message = 'Message added. It appears now in the <a href="?page='.$this->menu_parameter.'&cal='.$this->item.'&list=1">messages list</a>.';
|
18 |
+
|
19 |
+
$nonce = wp_create_nonce( 'cfte_actions_admin' );
|
20 |
+
|
21 |
+
|
22 |
+
if ($message) echo "<div id='setting-error-settings_updated' class='updated settings-error'><p><strong>".$message."</strong></p></div>";
|
23 |
+
|
24 |
+
?>
|
25 |
+
<style>
|
26 |
+
.clear{clear:both;}
|
27 |
+
.ahb-first-button{margin-right:10px !important;}
|
28 |
+
.ahb-buttons-container{margin:1em 1em 1em 0;}
|
29 |
+
.ahb-return-link{float:right;}
|
30 |
+
</style>
|
31 |
+
<div class="wrap">
|
32 |
+
|
33 |
+
<h1><?php _e('Add Message','contact-form-to-email'); ?></h1>
|
34 |
+
|
35 |
+
<div class="ahb-buttons-container">
|
36 |
+
<a href="<?php print esc_attr(admin_url('admin.php?page='.$this->menu_parameter));?>" class="ahb-return-link">←<?php _e('Return to the forms list','contact-form-to-email'); ?></a>
|
37 |
+
<div class="clear"></div>
|
38 |
+
</div>
|
39 |
+
|
40 |
+
<p><?php _e('This page is for adding messages from the administration area. The captcha and payment process are disabled in order to allow the website manager easily adding bookings.','contact-form-to-email'); ?></p>
|
41 |
+
|
42 |
+
<?php echo $this->filter_content(array('id' => $this->item)); ?>
|
43 |
+
|
44 |
+
</div>
|
45 |
+
|
46 |
+
|
cp-admin-int-edit-booking.inc.php
ADDED
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
$this->item = intval($_GET["cal"]);
|
4 |
+
|
5 |
+
$current_user = wp_get_current_user();
|
6 |
+
$current_user_access = current_user_can('edit_pages');
|
7 |
+
|
8 |
+
if ( !is_admin() || (!$current_user_access && !@in_array($current_user->ID, unserialize($this->get_option("cp_user_access","")))))
|
9 |
+
{
|
10 |
+
echo 'Direct access not allowed.';
|
11 |
+
exit;
|
12 |
+
}
|
13 |
+
|
14 |
+
$message = '';
|
15 |
+
|
16 |
+
if ( 'POST' == $_SERVER['REQUEST_METHOD'] && isset( $_POST[$this->prefix.'_pform_process'] ) )
|
17 |
+
$message = 'Message updated. Can be checked in the <a href="?page='.$this->menu_parameter.'&cal='.$this->item.'&list=1">messages list</a>.';
|
18 |
+
|
19 |
+
$nonce = wp_create_nonce( 'cfte_actions_admin' );
|
20 |
+
|
21 |
+
|
22 |
+
if ($message) echo "<div id='setting-error-settings_updated' class='updated settings-error'><p><strong>".$message."</strong></p></div>";
|
23 |
+
|
24 |
+
?>
|
25 |
+
<style>
|
26 |
+
.clear{clear:both;}
|
27 |
+
.ahb-first-button{margin-right:10px !important;}
|
28 |
+
.ahb-buttons-container{margin:1em 1em 1em 0;}
|
29 |
+
.ahb-return-link{float:right;}
|
30 |
+
</style>
|
31 |
+
<div class="wrap" id="ahbadminedititem">
|
32 |
+
|
33 |
+
<h1><?php _e('Edit Message','contact-form-to-email'); ?></h1>
|
34 |
+
|
35 |
+
<div class="ahb-buttons-container">
|
36 |
+
<a href="<?php print esc_attr(admin_url('admin.php?page='.$this->menu_parameter));?>" class="ahb-return-link">←<?php _e('Return to the forms list','contact-form-to-email'); ?></a>
|
37 |
+
<div class="clear"></div>
|
38 |
+
</div>
|
39 |
+
|
40 |
+
<p><?php _e('This page is for editing messages from the administration area. The captcha and payment process are disabled in order to allow the website manager easily editing bookings.','contact-form-to-email'); ?></p>
|
41 |
+
|
42 |
+
<?php echo $this->filter_content(array('id' => $this->item, 'prefill' => $_GET["edititem"])); ?>
|
43 |
+
|
44 |
+
</div>
|
45 |
+
|
46 |
+
|
cp-admin-int-list.inc.php
CHANGED
@@ -191,7 +191,12 @@ $nonce = wp_create_nonce( 'cfte_update_actions_plist' );
|
|
191 |
{
|
192 |
document.location = 'admin.php?page=<?php echo $this->menu_parameter; ?>&pwizard=1&cal='+id+'&r='+Math.random();
|
193 |
}
|
194 |
-
|
|
|
|
|
|
|
|
|
|
|
195 |
function cp_viewMessages(id)
|
196 |
{
|
197 |
document.location = 'admin.php?page=<?php echo $this->menu_parameter; ?>&cal='+id+'&list=1&r='+Math.random();
|
@@ -249,7 +254,8 @@ $nonce = wp_create_nonce( 'cfte_update_actions_plist' );
|
|
249 |
<input style="margin-bottom:3px" class="button" type="button" name="calupdate_<?php echo $item->id; ?>" value="Rename" onclick="cp_updateItem(<?php echo $item->id; ?>);" />
|
250 |
<input style="margin-bottom:3px" class="button-primary button" type="button" name="calmanage_<?php echo $item->id; ?>" value="Edit & Settings" onclick="cp_manageSettings(<?php echo $item->id; ?>);" />
|
251 |
<input style="margin-bottom:3px" class="button-primary button" type="button" name="calpublish_<?php echo $item->id; ?>" value="<?php _e('Publish','cpappb'); ?>" onclick="cp_publish(<?php echo $item->id; ?>);" />
|
252 |
-
<input style="margin-bottom:3px" class="button" type="button" name="calmessages_<?php echo $item->id; ?>" value="Messages" onclick="cp_viewMessages(<?php echo $item->id; ?>);" />
|
|
|
253 |
<input style="margin-bottom:3px" class="button" type="button" name="calreport_<?php echo $item->id; ?>" value="Stats" onclick="cp_viewReport(<?php echo $item->id; ?>);" />
|
254 |
<input style="margin-bottom:3px" class="button" type="button" name="calclone_<?php echo $item->id; ?>" value="Clone" onclick="cp_cloneItem(<?php echo $item->id; ?>);" />
|
255 |
<input style="margin-bottom:3px" class="button" type="button" name="caldelete_<?php echo $item->id; ?>" value="Delete" onclick="cp_deleteItem(<?php echo $item->id; ?>);" />
|
191 |
{
|
192 |
document.location = 'admin.php?page=<?php echo $this->menu_parameter; ?>&pwizard=1&cal='+id+'&r='+Math.random();
|
193 |
}
|
194 |
+
|
195 |
+
function cp_addbk(id)
|
196 |
+
{
|
197 |
+
document.location = 'admin.php?page=<?php echo $this->menu_parameter; ?>&addbk=1&cal='+id+'&r='+Math.random();
|
198 |
+
}
|
199 |
+
|
200 |
function cp_viewMessages(id)
|
201 |
{
|
202 |
document.location = 'admin.php?page=<?php echo $this->menu_parameter; ?>&cal='+id+'&list=1&r='+Math.random();
|
254 |
<input style="margin-bottom:3px" class="button" type="button" name="calupdate_<?php echo $item->id; ?>" value="Rename" onclick="cp_updateItem(<?php echo $item->id; ?>);" />
|
255 |
<input style="margin-bottom:3px" class="button-primary button" type="button" name="calmanage_<?php echo $item->id; ?>" value="Edit & Settings" onclick="cp_manageSettings(<?php echo $item->id; ?>);" />
|
256 |
<input style="margin-bottom:3px" class="button-primary button" type="button" name="calpublish_<?php echo $item->id; ?>" value="<?php _e('Publish','cpappb'); ?>" onclick="cp_publish(<?php echo $item->id; ?>);" />
|
257 |
+
<input style="margin-bottom:3px" class="button" type="button" name="calmessages_<?php echo $item->id; ?>" value="Messages" onclick="cp_viewMessages(<?php echo $item->id; ?>);" />
|
258 |
+
<input style="margin-bottom:5px;" class="button" type="button" name="caladdbk_<?php echo $item->id; ?>" value="<?php _e('Add Message','appointment-hour-booking'); ?>" onclick="cp_addbk(<?php echo $item->id; ?>);" />
|
259 |
<input style="margin-bottom:3px" class="button" type="button" name="calreport_<?php echo $item->id; ?>" value="Stats" onclick="cp_viewReport(<?php echo $item->id; ?>);" />
|
260 |
<input style="margin-bottom:3px" class="button" type="button" name="calclone_<?php echo $item->id; ?>" value="Clone" onclick="cp_cloneItem(<?php echo $item->id; ?>);" />
|
261 |
<input style="margin-bottom:3px" class="button" type="button" name="caldelete_<?php echo $item->id; ?>" value="Delete" onclick="cp_deleteItem(<?php echo $item->id; ?>);" />
|
cp-admin-int-message-list.inc.php
CHANGED
@@ -104,6 +104,10 @@ $nonce = wp_create_nonce( 'cfte_message_actions_plist' );
|
|
104 |
|
105 |
?>
|
106 |
<script type="text/javascript">
|
|
|
|
|
|
|
|
|
107 |
function cp_deleteMessageItem(id)
|
108 |
{
|
109 |
if (confirm('Are you sure that you want to delete this item?'))
|
@@ -222,6 +226,7 @@ echo paginate_links( array(
|
|
222 |
echo str_replace("\n","<br />",str_replace('<','<',$data));
|
223 |
?></td>
|
224 |
<td class="cpnopr">
|
|
|
225 |
<input class="button" type="button" name="caldelete_<?php echo $events[$i]->id; ?>" value="Delete" onclick="cp_deleteMessageItem(<?php echo $events[$i]->id; ?>);" />
|
226 |
</td>
|
227 |
</tr>
|
104 |
|
105 |
?>
|
106 |
<script type="text/javascript">
|
107 |
+
function cp_editItem(id)
|
108 |
+
{
|
109 |
+
document.location = 'admin.php?page=<?php echo $this->menu_parameter; ?>&cal=<?php echo $_GET["cal"]; ?>&edititem='+id+'&r='+Math.random( );
|
110 |
+
}
|
111 |
function cp_deleteMessageItem(id)
|
112 |
{
|
113 |
if (confirm('Are you sure that you want to delete this item?'))
|
226 |
echo str_replace("\n","<br />",str_replace('<','<',$data));
|
227 |
?></td>
|
228 |
<td class="cpnopr">
|
229 |
+
<input class="button" type="button" name="caltoggle_<?php echo $events[$i]->id; ?>" value="Edit" onclick="cp_editItem(<?php echo $events[$i]->id; ?>);" />
|
230 |
<input class="button" type="button" name="caldelete_<?php echo $events[$i]->id; ?>" value="Delete" onclick="cp_deleteMessageItem(<?php echo $events[$i]->id; ?>);" />
|
231 |
</td>
|
232 |
</tr>
|
cp-main-class.inc.php
CHANGED
@@ -195,18 +195,19 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
195 |
global $wpdb;
|
196 |
extract( shortcode_atts( array(
|
197 |
'id' => '',
|
|
|
198 |
), $atts ) );
|
199 |
if ($id != '')
|
200 |
$this->item = intval($id);
|
201 |
ob_start();
|
202 |
-
$this->insert_public_item();
|
203 |
$buffered_contents = ob_get_contents();
|
204 |
ob_end_clean();
|
205 |
return $buffered_contents;
|
206 |
}
|
207 |
|
208 |
|
209 |
-
function insert_public_item() {
|
210 |
global $wpdb;
|
211 |
|
212 |
$page_label = $this->get_option('vs_text_page', 'Page');
|
@@ -261,7 +262,7 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
261 |
function <?php echo $this->prefix; ?>_pform_doValidate<?php echo '_'.$this->print_counter; ?>(form)
|
262 |
{
|
263 |
document.<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>.cp_ref_page.value = document.location;
|
264 |
-
$dexQuery = jQuery.noConflict();<?php if ($this->get_option('cv_enable_captcha', CP_CFEMAIL_DEFAULT_cv_enable_captcha) != 'false') { ?>
|
265 |
if (document.<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>.hdcaptcha_<?php echo $this->prefix; ?>_post.value == '') { setTimeout( "<?php echo $this->prefix; ?>_cerror<?php echo '_'.$this->print_counter; ?>()", 100); return false; }
|
266 |
var result = $dexQuery.ajax({ type: "GET", url: "<?php echo $this->get_site_url(); ?>/?ps=<?php echo '_'.$this->print_counter; ?>&<?php echo $this->prefix; ?>_pform_process=2&inAdmin=1&ps=<?php echo '_'.$this->print_counter; ?>&hdcaptcha_<?php echo $this->prefix; ?>_post="+document.<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>.hdcaptcha_<?php echo $this->prefix; ?>_post.value, async: false }).responseText;
|
267 |
if (result.indexOf("captchafailed") != -1) {
|
@@ -352,6 +353,85 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
352 |
$button_label = $this->get_option('vs_text_submitbtn', 'Submit');
|
353 |
$button_label = ($button_label==''?'Submit':$button_label);
|
354 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
355 |
if (!defined('CP_AUTH_INCLUDE')) define('CP_AUTH_INCLUDE',true);
|
356 |
@include dirname( __FILE__ ) . '/cp-public-int.inc.php';
|
357 |
if (!CP_CFEMAIL_DEFER_SCRIPTS_LOADING)
|
@@ -425,6 +505,10 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
425 |
@include_once dirname( __FILE__ ) . '/cp_admin_int_edition.inc.php';
|
426 |
else if ($this->get_param("list") == '1')
|
427 |
@include_once dirname( __FILE__ ) . '/cp-admin-int-message-list.inc.php';
|
|
|
|
|
|
|
|
|
428 |
else if ($this->get_param("report") == '1')
|
429 |
@include_once dirname( __FILE__ ) . '/cp-admin-int-report.inc.php';
|
430 |
else if ($this->get_param("pwizard") == '1')
|
@@ -506,7 +590,7 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
506 |
|
507 |
|
508 |
function insert_adminScripts($hook) {
|
509 |
-
if ($this->get_param("page") == $this->menu_parameter)
|
510 |
{
|
511 |
wp_deregister_script('query-stringify');
|
512 |
wp_register_script('query-stringify', plugins_url('/js/jQuery.stringify.js', __FILE__));
|
@@ -629,7 +713,7 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
629 |
if (function_exists('session_start')) @session_start();
|
630 |
if (isset($_GET["ps"])) $sequence = $_GET["ps"]; else if (isset($_POST["cp_pform_psequence"])) $sequence = $_POST["cp_pform_psequence"];
|
631 |
if (
|
632 |
-
($this->get_option('cv_enable_captcha', CP_CFEMAIL_DEFAULT_cv_enable_captcha) != 'false') &&
|
633 |
( (strtolower($this->get_param('hdcaptcha_'.$this->prefix.'_post')) != strtolower($_SESSION['rand_code'.$sequence])) ||
|
634 |
($_SESSION['rand_code'.$sequence] == '')
|
635 |
)
|
@@ -679,7 +763,8 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
679 |
//---------------------------
|
680 |
$buffer = "";
|
681 |
$params = array();
|
682 |
-
$
|
|
|
683 |
foreach ($_POST as $item => $value)
|
684 |
if (isset($fields[str_replace($sequence,'',$item)]))
|
685 |
{
|
@@ -710,25 +795,46 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
710 |
//---------------------------
|
711 |
$wpdb->query("ALTER TABLE ".$wpdb->prefix.$this->table_messages." CHANGE `ipaddr` `ipaddr` VARCHAR(250)");
|
712 |
$to = $this->get_option('cu_user_email_field', CP_CFEMAIL_DEFAULT_cu_user_email_field);
|
713 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
714 |
'time' => current_time('mysql'),
|
715 |
'ipaddr' => ($saveipaddr?$this->getRealUserIP():'-'),
|
716 |
'notifyto' => (@$_POST[$to.$sequence]?$_POST[$to.$sequence]:''),
|
717 |
'posted_data' => serialize($params),
|
718 |
'data' =>$buffer_A
|
719 |
) );
|
720 |
-
if (!$rows_affected)
|
721 |
{
|
722 |
echo 'Error saving data! Please try again.';
|
723 |
echo '<br /><br />If the error persists please be sure you are using the latest version and in that case contact support service at https://form2email.dwbooster.com/contact-us?debug=db';
|
724 |
exit;
|
725 |
}
|
726 |
|
727 |
-
|
728 |
-
|
|
|
|
|
|
|
|
|
|
|
729 |
|
730 |
$this->ready_to_go_reservation($item_number, "", $params);
|
731 |
|
|
|
|
|
|
|
732 |
if ($_POST[ $this->prefix."_pform_status"] == '1')
|
733 |
echo 'OK';
|
734 |
else
|
@@ -805,6 +911,10 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
805 |
else
|
806 |
$from_1 = $from;
|
807 |
|
|
|
|
|
|
|
|
|
808 |
if ($this->get_option('fp_enableemail', 'true') != 'false')
|
809 |
{
|
810 |
foreach ($to as $item)
|
@@ -1102,7 +1212,7 @@ class CP_ContactFormToEmail extends CP_CFTEMAIL_BaseClass {
|
|
1102 |
for ($i=0; $i < count($form_data[0]); $i++)
|
1103 |
{
|
1104 |
$form_data[0][$i]->title = __($form_data[0][$i]->title,'contact-form-to-email');
|
1105 |
-
|
1106 |
$form_data[0][$i]->userhelp = __($form_data[0][$i]->userhelp,'contact-form-to-email');
|
1107 |
if ($form_data[0][$i]->ftype == 'fCommentArea')
|
1108 |
$form_data[0][$i]->userhelp = __($form_data[0][$i]->userhelp,'contact-form-to-email');
|
195 |
global $wpdb;
|
196 |
extract( shortcode_atts( array(
|
197 |
'id' => '',
|
198 |
+
'prefill' => '',
|
199 |
), $atts ) );
|
200 |
if ($id != '')
|
201 |
$this->item = intval($id);
|
202 |
ob_start();
|
203 |
+
$this->insert_public_item($prefill);
|
204 |
$buffered_contents = ob_get_contents();
|
205 |
ob_end_clean();
|
206 |
return $buffered_contents;
|
207 |
}
|
208 |
|
209 |
|
210 |
+
function insert_public_item($prefill = '') {
|
211 |
global $wpdb;
|
212 |
|
213 |
$page_label = $this->get_option('vs_text_page', 'Page');
|
262 |
function <?php echo $this->prefix; ?>_pform_doValidate<?php echo '_'.$this->print_counter; ?>(form)
|
263 |
{
|
264 |
document.<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>.cp_ref_page.value = document.location;
|
265 |
+
$dexQuery = jQuery.noConflict();<?php if (!is_admin() && $this->get_option('cv_enable_captcha', CP_CFEMAIL_DEFAULT_cv_enable_captcha) != 'false') { ?>
|
266 |
if (document.<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>.hdcaptcha_<?php echo $this->prefix; ?>_post.value == '') { setTimeout( "<?php echo $this->prefix; ?>_cerror<?php echo '_'.$this->print_counter; ?>()", 100); return false; }
|
267 |
var result = $dexQuery.ajax({ type: "GET", url: "<?php echo $this->get_site_url(); ?>/?ps=<?php echo '_'.$this->print_counter; ?>&<?php echo $this->prefix; ?>_pform_process=2&inAdmin=1&ps=<?php echo '_'.$this->print_counter; ?>&hdcaptcha_<?php echo $this->prefix; ?>_post="+document.<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>.hdcaptcha_<?php echo $this->prefix; ?>_post.value, async: false }).responseText;
|
268 |
if (result.indexOf("captchafailed") != -1) {
|
353 |
$button_label = $this->get_option('vs_text_submitbtn', 'Submit');
|
354 |
$button_label = ($button_label==''?'Submit':$button_label);
|
355 |
|
356 |
+
// START:: code to load form settings
|
357 |
+
$raw_form_str = str_replace("\r"," ",str_replace("\n"," ",$this->cleanJSON($this->translate_json($this->get_option('form_structure', CP_CFEMAIL_DEFAULT_form_structure)))));
|
358 |
+
|
359 |
+
$form_data = json_decode( $raw_form_str );
|
360 |
+
if( is_null( $form_data ) ){
|
361 |
+
$json = new JSON;
|
362 |
+
$form_data = $json->unserialize( $raw_form_str );
|
363 |
+
}
|
364 |
+
|
365 |
+
$preload_params = array();
|
366 |
+
if ($prefill)
|
367 |
+
{
|
368 |
+
$event_query = "SELECT * FROM ".$wpdb->prefix.$this->table_messages." WHERE id=".intval($prefill);
|
369 |
+
$event = $wpdb->get_results( $event_query );
|
370 |
+
if (count($event))
|
371 |
+
$preload_params = unserialize($event[0]->posted_data);
|
372 |
+
$preload_params["itemnumber"] = $prefill;
|
373 |
+
}
|
374 |
+
|
375 |
+
if( !is_null( $form_data ) )
|
376 |
+
{
|
377 |
+
if( !empty( $form_data[ 0 ] ) )
|
378 |
+
{
|
379 |
+
foreach( $form_data[ 0 ] as $key => $object )
|
380 |
+
{
|
381 |
+
if( isset( $object->isDataSource ) && $object->isDataSource && function_exists( 'mcrypt_encrypt' ) )
|
382 |
+
{
|
383 |
+
$connection = new stdClass();
|
384 |
+
$connection->connection = base64_encode( mcrypt_encrypt( MCRYPT_RIJNDAEL_256, $this->get_option('form_structure', CP_CONTACTFORMPP_DEFAULT_form_structure,$id), serialize( $object->list->database->databaseData ), MCRYPT_MODE_ECB ) );
|
385 |
+
$connection->form = $id;
|
386 |
+
|
387 |
+
$object->list->database->databaseData = $connection;
|
388 |
+
$form_data[ 0 ][ $key ] = $object;
|
389 |
+
$raw_form_str = json_encode( $form_data );
|
390 |
+
}
|
391 |
+
else if ($object->ftype == 'fcheck' || $object->ftype == 'fradio' || $object->ftype == 'fdropdown')
|
392 |
+
{
|
393 |
+
for($ki=0; $ki<count($object->choicesVal); $ki++)
|
394 |
+
$object->choicesVal[$ki] = $object->choicesVal[$ki];
|
395 |
+
$form_data[ 0 ][ $key ] = $object;
|
396 |
+
$raw_form_str = json_encode( $form_data );
|
397 |
+
}
|
398 |
+
if (count($preload_params))
|
399 |
+
{
|
400 |
+
if ($object->ftype == 'fdate')
|
401 |
+
$object->defaultDate = $preload_params[$object->name];
|
402 |
+
else if ($object->ftype == 'fradio' || $object->ftype == 'fdropdown')
|
403 |
+
{
|
404 |
+
for($ki=0; $ki<count($object->choicesVal); $ki++)
|
405 |
+
if ($object->choices[$ki] == $preload_params[$object->name])
|
406 |
+
$object->choiceSelected = $object->choices[$ki];
|
407 |
+
}
|
408 |
+
else if ($object->ftype == 'fcheck' && is_array($preload_params[$object->name]))
|
409 |
+
{
|
410 |
+
for($ki=0; $ki<count($object->choices); $ki++)
|
411 |
+
if (in_array($object->choices[$ki], $preload_params[$object->name]))
|
412 |
+
$object->choiceSelected[$ki] = true;
|
413 |
+
}
|
414 |
+
else if ($object->ftype == 'fPhone')
|
415 |
+
$object->predefined = str_replace("-", " ", $preload_params[$object->name]);
|
416 |
+
else if (property_exists($object, 'predefined'))
|
417 |
+
$object->predefined = $preload_params[$object->name];
|
418 |
+
|
419 |
+
if (property_exists($object, 'predefinedClick')) // remove placeholders
|
420 |
+
$object->predefinedClick = 0;
|
421 |
+
|
422 |
+
|
423 |
+
$form_data[ 0 ][ $key ] = $object;
|
424 |
+
$raw_form_str = json_encode( $form_data );
|
425 |
+
}
|
426 |
+
}
|
427 |
+
}
|
428 |
+
|
429 |
+
}
|
430 |
+
|
431 |
+
$raw_form_str = str_replace('"','"',esc_attr($raw_form_str));
|
432 |
+
// END:: code to load form settings
|
433 |
+
|
434 |
+
|
435 |
if (!defined('CP_AUTH_INCLUDE')) define('CP_AUTH_INCLUDE',true);
|
436 |
@include dirname( __FILE__ ) . '/cp-public-int.inc.php';
|
437 |
if (!CP_CFEMAIL_DEFER_SCRIPTS_LOADING)
|
505 |
@include_once dirname( __FILE__ ) . '/cp_admin_int_edition.inc.php';
|
506 |
else if ($this->get_param("list") == '1')
|
507 |
@include_once dirname( __FILE__ ) . '/cp-admin-int-message-list.inc.php';
|
508 |
+
else if ($this->get_param("edititem"))
|
509 |
+
@include_once dirname( __FILE__ ) . '/cp-admin-int-edit-booking.inc.php';
|
510 |
+
else if ($this->get_param("addbk") == '1')
|
511 |
+
@include_once dirname( __FILE__ ) . '/cp-admin-int-add-booking.inc.php';
|
512 |
else if ($this->get_param("report") == '1')
|
513 |
@include_once dirname( __FILE__ ) . '/cp-admin-int-report.inc.php';
|
514 |
else if ($this->get_param("pwizard") == '1')
|
590 |
|
591 |
|
592 |
function insert_adminScripts($hook) {
|
593 |
+
if ($this->get_param("page") == $this->menu_parameter && $this->get_param("addbk") != '1' && !$this->get_param("edititem"))
|
594 |
{
|
595 |
wp_deregister_script('query-stringify');
|
596 |
wp_register_script('query-stringify', plugins_url('/js/jQuery.stringify.js', __FILE__));
|
713 |
if (function_exists('session_start')) @session_start();
|
714 |
if (isset($_GET["ps"])) $sequence = $_GET["ps"]; else if (isset($_POST["cp_pform_psequence"])) $sequence = $_POST["cp_pform_psequence"];
|
715 |
if (
|
716 |
+
(!is_admin() && $this->get_option('cv_enable_captcha', CP_CFEMAIL_DEFAULT_cv_enable_captcha) != 'false') &&
|
717 |
( (strtolower($this->get_param('hdcaptcha_'.$this->prefix.'_post')) != strtolower($_SESSION['rand_code'.$sequence])) ||
|
718 |
($_SESSION['rand_code'.$sequence] == '')
|
719 |
)
|
763 |
//---------------------------
|
764 |
$buffer = "";
|
765 |
$params = array();
|
766 |
+
if (!(isset($_POST["edititem"]) && $_POST["edititem"]))
|
767 |
+
$params["referrer"] = $_POST["refpage".$sequence];
|
768 |
foreach ($_POST as $item => $value)
|
769 |
if (isset($fields[str_replace($sequence,'',$item)]))
|
770 |
{
|
795 |
//---------------------------
|
796 |
$wpdb->query("ALTER TABLE ".$wpdb->prefix.$this->table_messages." CHANGE `ipaddr` `ipaddr` VARCHAR(250)");
|
797 |
$to = $this->get_option('cu_user_email_field', CP_CFEMAIL_DEFAULT_cu_user_email_field);
|
798 |
+
if (isset($_POST["edititem"]) && $_POST["edititem"])
|
799 |
+
{
|
800 |
+
$rows_affected = $wpdb->update( $wpdb->prefix.$this->table_messages, array(
|
801 |
+
'notifyto' => (@$_POST[$to.$sequence]?$_POST[$to.$sequence]:''),
|
802 |
+
'posted_data' => serialize($params),
|
803 |
+
'data' =>$buffer_A
|
804 |
+
),
|
805 |
+
array (
|
806 |
+
'id' => intval($_POST["edititem"])
|
807 |
+
)
|
808 |
+
);
|
809 |
+
}
|
810 |
+
else
|
811 |
+
$rows_affected = $wpdb->insert( $wpdb->prefix.$this->table_messages, array( 'formid' => $this->item,
|
812 |
'time' => current_time('mysql'),
|
813 |
'ipaddr' => ($saveipaddr?$this->getRealUserIP():'-'),
|
814 |
'notifyto' => (@$_POST[$to.$sequence]?$_POST[$to.$sequence]:''),
|
815 |
'posted_data' => serialize($params),
|
816 |
'data' =>$buffer_A
|
817 |
) );
|
818 |
+
if (!$rows_affected && !isset($_POST["edititem"]))
|
819 |
{
|
820 |
echo 'Error saving data! Please try again.';
|
821 |
echo '<br /><br />If the error persists please be sure you are using the latest version and in that case contact support service at https://form2email.dwbooster.com/contact-us?debug=db';
|
822 |
exit;
|
823 |
}
|
824 |
|
825 |
+
if (isset($_POST["edititem"]) && $_POST["edititem"])
|
826 |
+
$item_number = $_POST["edititem"];
|
827 |
+
else
|
828 |
+
{
|
829 |
+
$myrows = $wpdb->get_results( "SELECT MAX(id) as max_id FROM ".$wpdb->prefix.$this->table_messages );
|
830 |
+
$item_number = $myrows[0]->max_id;
|
831 |
+
}
|
832 |
|
833 |
$this->ready_to_go_reservation($item_number, "", $params);
|
834 |
|
835 |
+
if (is_admin())
|
836 |
+
return;
|
837 |
+
|
838 |
if ($_POST[ $this->prefix."_pform_status"] == '1')
|
839 |
echo 'OK';
|
840 |
else
|
911 |
else
|
912 |
$from_1 = $from;
|
913 |
|
914 |
+
// if is_admin and not required emails end function here
|
915 |
+
if (is_admin() && !isset($_POST["sendemails_admin"]))
|
916 |
+
return;
|
917 |
+
|
918 |
if ($this->get_option('fp_enableemail', 'true') != 'false')
|
919 |
{
|
920 |
foreach ($to as $item)
|
1212 |
for ($i=0; $i < count($form_data[0]); $i++)
|
1213 |
{
|
1214 |
$form_data[0][$i]->title = __($form_data[0][$i]->title,'contact-form-to-email');
|
1215 |
+
@$form_data[0][$i]->userhelpTooltip = __($form_data[0][$i]->userhelpTooltip,'contact-form-to-email');
|
1216 |
$form_data[0][$i]->userhelp = __($form_data[0][$i]->userhelp,'contact-form-to-email');
|
1217 |
if ($form_data[0][$i]->ftype == 'fCommentArea')
|
1218 |
$form_data[0][$i]->userhelp = __($form_data[0][$i]->userhelp,'contact-form-to-email');
|
cp-public-int.inc.php
CHANGED
@@ -7,7 +7,13 @@
|
|
7 |
if ($custom_scripts != '')
|
8 |
echo '<script type="text/javascript">'.$custom_scripts.'</script>';
|
9 |
?>
|
10 |
-
<form class="cpp_form" name="<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>" id="<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>" action="<?php $this->get_site_url(); ?>" method="post" enctype="multipart/form-data" onsubmit="return <?php echo $this->prefix; ?>_pform_doValidate<?php echo '_'.$this->print_counter; ?>(this);"><input type="hidden" name="cp_pform_psequence" value="<?php echo '_'.$this->print_counter; ?>" /><input type="hidden" name="<?php echo $this->prefix; ?>_pform_process" value="1" /><input type="hidden" name="<?php echo $this->prefix; ?>_id" value="<?php echo $this->item; ?>" /><input type="hidden" name="cp_ref_page" value="<?php esc_attr($this->get_site_url()); ?>" /><input type="hidden" name="form_structure<?php echo '_'.$this->print_counter; ?>" id="form_structure<?php echo '_'.$this->print_counter; ?>" size="180" value="<?php echo
|
|
|
|
|
|
|
|
|
|
|
|
|
11 |
<div id="fbuilder">
|
12 |
<div id="fbuilder<?php echo '_'.$this->print_counter; ?>">
|
13 |
<div id="formheader<?php echo '_'.$this->print_counter; ?>"></div>
|
@@ -15,7 +21,7 @@
|
|
15 |
</div>
|
16 |
</div>
|
17 |
<div id="cpcaptchalayer<?php echo '_'.$this->print_counter; ?>" class="cpcaptchalayer">
|
18 |
-
<?php if ($this->get_option('cv_enable_captcha', CP_CFEMAIL_DEFAULT_cv_enable_captcha) != 'false') { ?>
|
19 |
<?php _e("Security Code",'contact-form-to-email'); ?>:<br />
|
20 |
<img src="<?php echo $this->get_site_url().'/?'.$this->prefix.'_captcha=captcha&ps=_'.$this->print_counter.'&inAdmin=1&width='.$this->get_option('cv_width', CP_CFEMAIL_DEFAULT_cv_width).'&height='.$this->get_option('cv_height', CP_CFEMAIL_DEFAULT_cv_height).'&letter_count='.$this->get_option('cv_chars', CP_CFEMAIL_DEFAULT_cv_chars).'&min_size='.$this->get_option('cv_min_font_size', CP_CFEMAIL_DEFAULT_cv_min_font_size).'&max_size='.$this->get_option('cv_max_font_size', CP_CFEMAIL_DEFAULT_cv_max_font_size).'&noise='.$this->get_option('cv_noise', CP_CFEMAIL_DEFAULT_cv_noise).'&noiselength='.$this->get_option('cv_noise_length', CP_CFEMAIL_DEFAULT_cv_noise_length).'&bcolor='.$this->get_option('cv_background', CP_CFEMAIL_DEFAULT_cv_background).'&border='.$this->get_option('cv_border', CP_CFEMAIL_DEFAULT_cv_border).'&font='.$this->get_option('cv_font', CP_CFEMAIL_DEFAULT_cv_font); ?>" id="captchaimg<?php echo '_'.$this->print_counter; ?>" alt="security code" border="0" class="skip-lazy" />
|
21 |
<br /><?php _e("Please enter the security code",'contact-form-to-email'); ?>:<br />
|
7 |
if ($custom_scripts != '')
|
8 |
echo '<script type="text/javascript">'.$custom_scripts.'</script>';
|
9 |
?>
|
10 |
+
<form class="cpp_form" name="<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>" id="<?php echo $this->prefix; ?>_pform<?php echo '_'.$this->print_counter; ?>" action="<?php $this->get_site_url(); ?>" method="post" enctype="multipart/form-data" onsubmit="return <?php echo $this->prefix; ?>_pform_doValidate<?php echo '_'.$this->print_counter; ?>(this);"><input type="hidden" name="cp_pform_psequence" value="<?php echo '_'.$this->print_counter; ?>" /><input type="hidden" name="<?php echo $this->prefix; ?>_pform_process" value="1" /><input type="hidden" name="<?php echo $this->prefix; ?>_id" value="<?php echo $this->item; ?>" /><input type="hidden" name="cp_ref_page" value="<?php esc_attr($this->get_site_url()); ?>" /><input type="hidden" name="form_structure<?php echo '_'.$this->print_counter; ?>" id="form_structure<?php echo '_'.$this->print_counter; ?>" size="180" value="<?php echo $raw_form_str; ?>" /><input type="hidden" name="refpage<?php echo '_'.$this->print_counter; ?>" id="refpage<?php echo '_'.$this->print_counter; ?>" value=""><input type="hidden" name="<?php echo $this->prefix; ?>_pform_status" value="0" /><?php if (count($preload_params)) { ?><input type="hidden" name="edititem" value="<?php echo $preload_params["itemnumber"]; ?>" /><?php } ?>
|
11 |
+
<?php if (is_admin() && !defined('APHOURBK_ELEMENTOR_EDIT_MODE') && @$_GET["action"] != 'edit') {?>
|
12 |
+
<fieldset style="border: 1px solid black; -webkit-border-radius: 8px; -moz-border-radius: 8px; border-radius: 8px; padding:15px;">
|
13 |
+
<legend>Administrator options</legend>
|
14 |
+
<input type="checkbox" name="sendemails_admin" value="1" vt="1" /> Send notification emails for this booking<br /><br />
|
15 |
+
</fieldset>
|
16 |
+
<?php } ?>
|
17 |
<div id="fbuilder">
|
18 |
<div id="fbuilder<?php echo '_'.$this->print_counter; ?>">
|
19 |
<div id="formheader<?php echo '_'.$this->print_counter; ?>"></div>
|
21 |
</div>
|
22 |
</div>
|
23 |
<div id="cpcaptchalayer<?php echo '_'.$this->print_counter; ?>" class="cpcaptchalayer">
|
24 |
+
<?php if (!is_admin() && $this->get_option('cv_enable_captcha', CP_CFEMAIL_DEFAULT_cv_enable_captcha) != 'false') { ?>
|
25 |
<?php _e("Security Code",'contact-form-to-email'); ?>:<br />
|
26 |
<img src="<?php echo $this->get_site_url().'/?'.$this->prefix.'_captcha=captcha&ps=_'.$this->print_counter.'&inAdmin=1&width='.$this->get_option('cv_width', CP_CFEMAIL_DEFAULT_cv_width).'&height='.$this->get_option('cv_height', CP_CFEMAIL_DEFAULT_cv_height).'&letter_count='.$this->get_option('cv_chars', CP_CFEMAIL_DEFAULT_cv_chars).'&min_size='.$this->get_option('cv_min_font_size', CP_CFEMAIL_DEFAULT_cv_min_font_size).'&max_size='.$this->get_option('cv_max_font_size', CP_CFEMAIL_DEFAULT_cv_max_font_size).'&noise='.$this->get_option('cv_noise', CP_CFEMAIL_DEFAULT_cv_noise).'&noiselength='.$this->get_option('cv_noise_length', CP_CFEMAIL_DEFAULT_cv_noise_length).'&bcolor='.$this->get_option('cv_background', CP_CFEMAIL_DEFAULT_cv_background).'&border='.$this->get_option('cv_border', CP_CFEMAIL_DEFAULT_cv_border).'&font='.$this->get_option('cv_font', CP_CFEMAIL_DEFAULT_cv_font); ?>" id="captchaimg<?php echo '_'.$this->print_counter; ?>" alt="security code" border="0" class="skip-lazy" />
|
27 |
<br /><?php _e("Please enter the security code",'contact-form-to-email'); ?>:<br />
|
form-to-email.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Contact Form Email
|
4 |
Plugin URI: https://form2email.dwbooster.com/download
|
5 |
Description: Contact form that sends the data to email and also to a database list and CSV file.
|
6 |
-
Version: 1.2.
|
7 |
Author: CodePeople
|
8 |
Author URI: https://form2email.dwbooster.com
|
9 |
Text Domain: contact-form-to-email
|
3 |
Plugin Name: Contact Form Email
|
4 |
Plugin URI: https://form2email.dwbooster.com/download
|
5 |
Description: Contact form that sends the data to email and also to a database list and CSV file.
|
6 |
+
Version: 1.2.86
|
7 |
Author: CodePeople
|
8 |
Author URI: https://form2email.dwbooster.com
|
9 |
Text Domain: contact-form-to-email
|
js/fbuilderf.jquery.js
CHANGED
@@ -40,15 +40,15 @@ jQuery(window).on('load', function(){
|
|
40 |
}
|
41 |
if (!opt.pub)
|
42 |
{
|
43 |
-
for (var i=0;i<opt.typeList.length;i++)
|
44 |
{
|
45 |
if (opt.typeList[i].id=="category")
|
46 |
$("#tabs-1").append('<div style="clear:both;"></div><br /><div class="category-description">'+opt.typeList[i].name+'</div><hr />');
|
47 |
else
|
48 |
$("#tabs-1").append('<div class="button width40 '+(((i>5 && i!=20) || (i%2==1))?"n":"itemForm")+'" id="'+opt.typeList[i].id+'">'+opt.typeList[i].name+'</div>');
|
49 |
-
}
|
50 |
$("#tabs-1").append('<div class="clearer"></div>');
|
51 |
-
}
|
52 |
if (!opt.pub) $( ".button").button();
|
53 |
var items = new Array();
|
54 |
var itemSelected = -2;
|
@@ -587,7 +587,7 @@ jQuery(window).on('load', function(){
|
|
587 |
try {
|
588 |
$( "#fbuilder"+opt.identifier ).tooltip({show: false,hide:false,tooltipClass:"uh-tooltip",position: { my: "left top", at: "left bottom", collision: "none" },items: "[uh]",content: function (){return $(this).attr("uh");} });
|
589 |
} catch(e){}
|
590 |
-
|
591 |
}
|
592 |
for (var i=0;i<items.length;i++)
|
593 |
items[i].after_show();
|
@@ -814,7 +814,7 @@ jQuery(window).on('load', function(){
|
|
814 |
'</span></label></div>'+
|
815 |
dlg+
|
816 |
'</div><div class="clearer"></div></div>';
|
817 |
-
|
818 |
},
|
819 |
after_show:function()
|
820 |
{
|
@@ -848,13 +848,13 @@ jQuery(window).on('load', function(){
|
|
848 |
maxlength:"",
|
849 |
equalTo:"",
|
850 |
display:function(){
|
851 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"
|
852 |
},
|
853 |
show:function(){
|
854 |
-
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'"
|
855 |
},
|
856 |
showSpecialDataInstance: function() {
|
857 |
-
return '
|
858 |
}
|
859 |
});
|
860 |
var femail=function(){};
|
@@ -890,19 +890,16 @@ jQuery(window).on('load', function(){
|
|
890 |
dformat:"digits",
|
891 |
formats:new Array("digits","number"),
|
892 |
display:function(){
|
893 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"
|
894 |
},
|
895 |
show:function(){
|
896 |
-
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'"
|
897 |
},
|
898 |
-
showFormatIntance: function() {
|
899 |
-
|
900 |
-
for (var i=0;i<this.formats.length;i++)
|
901 |
-
str += '<option value="'+this.formats[i]+'" '+((this.formats[i]==this.dformat)?"selected":"")+'>'+this.formats[i]+'</option>';
|
902 |
-
return '<div><label>Number Format</label><br /><select name="sFormat" id="sFormat">'+str+'</select></div>';
|
903 |
},
|
904 |
showRangeIntance: function() {
|
905 |
-
return '
|
906 |
}
|
907 |
});
|
908 |
var fdate=function(){};
|
@@ -927,18 +924,10 @@ jQuery(window).on('load', function(){
|
|
927 |
return '';
|
928 |
},
|
929 |
showFormatIntance: function() {
|
930 |
-
|
931 |
-
for (var i=0;i<this.formats.length;i++)
|
932 |
-
str += '<option value="'+this.formats[i]+'" '+((this.formats[i]==this.dformat)?"selected":"")+'>'+this.formats[i]+'</option>';
|
933 |
-
return '<div><label>Date Format</label><br /><select name="sFormat" id="sFormat">'+str+'</select></div>';
|
934 |
},
|
935 |
showSpecialDataInstance: function() {
|
936 |
-
|
937 |
-
str += '<div><label>Default date [<a class="helpfbuilder" text="You can put one of the following type of values into this field:\n\nEmpty: Leave empty for current date.\n\nDate: A Fixed date with the same date format indicated in the "Date Format" drop-down field.\n\nNumber: A number of days from today. For example 2 represents two days from today and -1 represents yesterday.\n\nString: A smart text indicating a relative date. Relative dates must contain value (number) and period pairs; valid periods are "y" for years, "m" for months, "w" for weeks, and "d" for days. For example, "+1m +7d" represents one month and seven days from today.">help?</a>]</label><br /><input class="medium" name="sDefaultDate" id="sDefaultDate" value="'+this.defaultDate+'" /></div>';
|
938 |
-
str += '<div><label>Min date [<a class="helpfbuilder" text="You can put one of the following type of values into this field:\n\nEmpty: No min Date.\n\nDate: A Fixed date with the same date format indicated in the "Date Format" drop-down field.\n\nNumber: A number of days from today. For example 2 represents two days from today and -1 represents yesterday.\n\nString: A smart text indicating a relative date. Relative dates must contain value (number) and period pairs; valid periods are "y" for years, "m" for months, "w" for weeks, and "d" for days. For example, "+1m +7d" represents one month and seven days from today.">help?</a>]</label><br /><input class="medium" name="sMinDate" id="sMinDate" value="'+this.minDate+'" /></div>';
|
939 |
-
str += '<div><label>Max date [<a class="helpfbuilder" text="You can put one of the following type of values into this field:\n\nEmpty: No max Date.\n\nDate: A Fixed date with the same date format indicated in the "Date Format" drop-down field.\n\nNumber: A number of days from today. For example 2 represents two days from today and -1 represents yesterday.\n\nString: A smart text indicating a relative date. Relative dates must contain value (number) and period pairs; valid periods are "y" for years, "m" for months, "w" for weeks, and "d" for days. For example, "+1m +7d" represents one month and seven days from today.">help?</a>]</label><br /><input class="medium" name="sMaxDate" id="sMaxDate" value="'+this.maxDate+'" /></div>';
|
940 |
-
str += '<div><input type="checkbox" name="sShowDropdown" id="sShowDropdown" '+((this.showDropdown)?"checked":"")+'/><label>Show Dropdown Year and Month</label><div id="divdropdownRange" style="display:'+((this.showDropdown)?"":"none")+'">Year Range [<a class="helpfbuilder" text="The range of years displayed in the year drop-down: either relative to today\'s year ("-nn:+nn"), absolute ("nnnn:nnnn"), or combinations of these formats ("nnnn:-nn")">help?</a>]: <input type="text" name="sDropdownRange" id="sDropdownRange" value="'+htmlEncode(this.dropdownRange)+'"/></div></div>';
|
941 |
-
return str;
|
942 |
}
|
943 |
});
|
944 |
var ftextarea=function(){};
|
@@ -968,10 +957,10 @@ jQuery(window).on('load', function(){
|
|
968 |
required:false,
|
969 |
size:"medium",
|
970 |
display:function(){
|
971 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"
|
972 |
},
|
973 |
show:function(){
|
974 |
-
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'"
|
975 |
}
|
976 |
});
|
977 |
var fSectionBreak=function(){};
|
@@ -980,10 +969,10 @@ jQuery(window).on('load', function(){
|
|
980 |
ftype:"fSectionBreak",
|
981 |
userhelp:"A description of the section goes here.",
|
982 |
display:function(){
|
983 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"
|
984 |
},
|
985 |
show:function(){
|
986 |
-
return '<div class="fields '+this.csslayout+' section_breaks" id="field'+opt.identifier+'-'+this.index+'"
|
987 |
}
|
988 |
});
|
989 |
var fPageBreak=function(){};
|
@@ -991,10 +980,10 @@ jQuery(window).on('load', function(){
|
|
991 |
title:"Page Break",
|
992 |
ftype:"fPageBreak",
|
993 |
display:function(){
|
994 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"
|
995 |
},
|
996 |
show:function(){
|
997 |
-
return '<div class="fields '+this.csslayout+' section_breaks" id="field'+opt.identifier+'-'+this.index+'"
|
998 |
}
|
999 |
});
|
1000 |
var fPhone=function(){};
|
@@ -1005,31 +994,13 @@ jQuery(window).on('load', function(){
|
|
1005 |
dformat:"### ### ####",
|
1006 |
predefined:"888 888 8888",
|
1007 |
display:function(){
|
1008 |
-
|
1009 |
-
var tmp = this.dformat.split(' ');
|
1010 |
-
var tmpv = this.predefined.split(' ');
|
1011 |
-
for (var i=0;i<tmpv.length;i++)
|
1012 |
-
if ($.trim(tmpv[i])=="")
|
1013 |
-
tmpv.splice(i,1);
|
1014 |
-
for (var i=0;i<tmp.length;i++)
|
1015 |
-
if ($.trim(tmp[i])!="")
|
1016 |
-
str += '<div class="uh_phone" ><input type="text" class="field disabled" style="width:'+(15*$.trim(tmp[i]).length)+'px" value="'+((tmpv[i])?tmpv[i]:"")+'" maxlength="'+$.trim(tmp[i]).length+'" /><div class="l">'+$.trim(tmp[i])+'</div></div>';
|
1017 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"><div class="arrow ui-icon ui-icon-play "></div><div class="remove ui-icon ui-icon-trash "></div><label>'+this.title+''+((this.required)?"*":"")+'</label><div class="dfield">'+str+'<span class="uh">'+this.userhelp+'</span></div><div class="clearer"></div></div>';
|
1018 |
},
|
1019 |
show:function(){
|
1020 |
-
|
1021 |
-
var tmp = this.dformat.split(' ');
|
1022 |
-
var tmpv = this.predefined.split(' ');
|
1023 |
-
for (var i=0;i<tmpv.length;i++)
|
1024 |
-
if ($.trim(tmpv[i])=="")
|
1025 |
-
tmpv.splice(i,1);
|
1026 |
-
for (var i=0;i<tmp.length;i++)
|
1027 |
-
if ($.trim(tmp[i])!="")
|
1028 |
-
str += '<div class="uh_phone" ><input type="text" id="'+this.name+'_'+i+'" name="'+this.name+'_'+i+'" class="field digits '+((this.required)?" required":"")+'" style="width:'+(15*$.trim(tmp[i]).length)+'px" value="'+((tmpv[i])?tmpv[i]:"")+'" maxlength="'+$.trim(tmp[i]).length+'" minlength="'+$.trim(tmp[i]).length+'"/><div class="l">'+$.trim(tmp[i])+'</div></div>';
|
1029 |
-
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'"><label>'+this.title+''+((this.required)?"*":"")+'</label><div class="dfield"><input type="hidden" id="'+this.name+'" name="'+this.name+'" class="field " />'+str+'<span class="uh">'+this.userhelp+'</span></div><div class="clearer"></div></div>';
|
1030 |
},
|
1031 |
showFormatIntance: function() {
|
1032 |
-
return '<div
|
1033 |
}
|
1034 |
});
|
1035 |
var fCommentArea=function(){};
|
@@ -1038,10 +1009,10 @@ jQuery(window).on('load', function(){
|
|
1038 |
ftype:"fCommentArea",
|
1039 |
userhelp:"A description of the section goes here.",
|
1040 |
display:function(){
|
1041 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"
|
1042 |
},
|
1043 |
show:function(){
|
1044 |
-
return '<div class="fields '+this.csslayout+' comment_area" id="field'+opt.identifier+'-'+this.index+'"
|
1045 |
}
|
1046 |
});
|
1047 |
var fcheck=function(){};
|
@@ -1052,65 +1023,15 @@ jQuery(window).on('load', function(){
|
|
1052 |
required:false,
|
1053 |
showDep:false,
|
1054 |
init:function(){
|
1055 |
-
this.choices = new Array("First Choice","Second Choice","Third Choice");
|
1056 |
-
this.choicesVal = new Array("First Choice","Second Choice","Third Choice");
|
1057 |
-
this.choiceSelected = new Array(false,false,false);
|
1058 |
-
this.choicesDep = new Array(new Array(),new Array(),new Array());
|
1059 |
},
|
1060 |
display:function(){
|
1061 |
-
|
1062 |
-
var str = "";
|
1063 |
-
for (var i=0;i<this.choices.length;i++)
|
1064 |
-
str += '<div class="'+this.layout+'"><input class="field" disabled="true" type="checkbox" '+((this.choiceSelected[i])?"checked":"")+'/> '+this.choices[i]+'</div>';
|
1065 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"><div class="arrow ui-icon ui-icon-play "></div><div class="remove ui-icon ui-icon-trash "></div><label>'+this.title+''+((this.required)?"*":"")+'</label><div class="dfield">'+str+'<span class="uh">'+this.userhelp+'</span></div><div class="clearer"></div></div>';
|
1066 |
},
|
1067 |
show:function(){
|
1068 |
-
|
1069 |
-
var str = "";
|
1070 |
-
if (!(typeof(this.choicesDep) != "undefined" && this.choicesDep !== null))
|
1071 |
-
{
|
1072 |
-
this.choicesDep = new Array();
|
1073 |
-
for (var i=0;i<this.choices.length;i++)
|
1074 |
-
this.choicesDep[i] = new Array();
|
1075 |
-
}
|
1076 |
-
for (var i=0;i<this.choices.length;i++)
|
1077 |
-
{
|
1078 |
-
var classDep = "",attrDep = "";
|
1079 |
-
var d = this.choicesDep;
|
1080 |
-
if (d[i].length>0)
|
1081 |
-
{
|
1082 |
-
classDep = " depItem";
|
1083 |
-
for (var j=0;j<d[i].length;j++)
|
1084 |
-
{
|
1085 |
-
attrDep += ","+d[i][j];
|
1086 |
-
}
|
1087 |
-
}
|
1088 |
-
str += '<div class="'+this.layout+'"><input name="'+this.name+'[]" '+((classDep!="")?"dep=\""+attrDep+"\"":"")+' id="'+this.name+'" class="field depItem group '+((this.required)?" required":"")+'" value="'+htmlEncode(this.choicesVal[i])+'" type="checkbox" '+((this.choiceSelected[i])?"checked":"")+'/> <span>'+this.choices[i]+'</span></div>';
|
1089 |
-
}
|
1090 |
-
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'"><label>'+this.title+''+((this.required)?"*":"")+'</label><div class="dfield">'+str+'<span class="uh">'+this.userhelp+'</span></div><div class="clearer"></div></div>';
|
1091 |
},
|
1092 |
showChoiceIntance: function() {
|
1093 |
-
|
1094 |
-
var l = this.choices;
|
1095 |
-
var lv = this.choicesVal;
|
1096 |
-
var v = this.choiceSelected;
|
1097 |
-
if (!(typeof(this.choicesDep) != "undefined" && this.choicesDep !== null))
|
1098 |
-
{
|
1099 |
-
this.choicesDep = new Array();
|
1100 |
-
for (var i=0;i<l.length;i++)
|
1101 |
-
this.choicesDep[i] = new Array();
|
1102 |
-
}
|
1103 |
-
var d = this.choicesDep;
|
1104 |
-
var str = "";
|
1105 |
-
for (var i=0;i<l.length;i++)
|
1106 |
-
{
|
1107 |
-
str += '<div class="choicesEdit"><input class="choice_check" i="'+i+'" type="checkbox" '+((this.choiceSelected[i])?"checked":"")+'/><input class="choice_text" i="'+i+'" type="text" name="sChoice'+this.name+'" id="sChoice'+this.name+'" value="'+htmlEncode(l[i])+'"/><input class="choice_value" i="'+i+'" type="text" name="sChoice'+this.name+'V'+i+'" id="sChoice'+this.name+'V'+i+'" value="'+htmlEncode(lv[i])+'"/><a class="choice_add ui-icon ui-icon-circle-plus" i="'+i+'" title="Add another choice."></a><a class="choice_remove ui-icon ui-icon-circle-minus" i="'+i+'" title="Delete this choice."></a></div>';
|
1108 |
-
for (var j=0;j<d[i].length;j++)
|
1109 |
-
str += '<div class="choicesEditDep">If selected show: <select class="dependencies" i="'+i+'" j="'+j+'" dname="'+this.name+'" dvalue="'+d[i][j]+'" ></select><a class="choice_addDep ui-icon ui-icon-circle-plus" i="'+i+'" j="'+j+'" title="Add another dependency."></a><a class="choice_removeDep ui-icon ui-icon-circle-minus" i="'+i+'" j="'+j+'" title="Delete this dependency."></a></div>';
|
1110 |
-
if (d[i].length==0)
|
1111 |
-
str += '<div class="choicesEditDep">If selected show: <select class="dependencies" i="'+i+'" j="'+d[i].length+'" dname="'+this.name+'" dvalue="" ></select><a class="choice_addDep ui-icon ui-icon-circle-plus" i="'+i+'" j="'+d[i].length+'" title="Add another dependency."></a><a class="choice_removeDep ui-icon ui-icon-circle-minus" i="'+i+'" j="'+d[i].length+'" title="Delete this dependency."></a></div>';
|
1112 |
-
}
|
1113 |
-
return '<div class="choicesSet '+((this.showDep)?"show":"hide")+'"><label>Choices</label> <a class="helpfbuilder dep" text="Dependencies are used to show/hide other fields depending of the option selected in this field.">help?</a> <a href="" class="showHideDependencies">'+((this.showDep)?"Hide":"Show")+' Dependencies</a><div><div class="t">Text</div><div class="t">Value</div><div class="clearer"></div></div>'+str+'</div>';
|
1114 |
}
|
1115 |
});
|
1116 |
var fradio=function(){};
|
@@ -1122,15 +1043,8 @@ jQuery(window).on('load', function(){
|
|
1122 |
choiceSelected:null,
|
1123 |
showDep:false,
|
1124 |
init:function(){
|
1125 |
-
this.choices = new Array("First Choice","Second Choice","Third Choice");
|
1126 |
-
this.choicesVal = new Array("First Choice","Second Choice","Third Choice");
|
1127 |
-
this.choicesDep = new Array(new Array(),new Array(),new Array());
|
1128 |
},
|
1129 |
display:function(){
|
1130 |
-
this.choicesVal = ((typeof(this.choicesVal) != "undefined" && this.choicesVal !== null)?this.choicesVal:this.choices.slice(0));
|
1131 |
-
var str = "";
|
1132 |
-
for (var i=0;i<this.choices.length;i++)
|
1133 |
-
str += '<div class="'+this.layout+'"><input class="field" disabled="true" type="radio" i="'+i+'" '+((this.choicesVal[i]==this.choiceSelected)?"checked":"")+'/> '+this.choices[i]+'</div>';
|
1134 |
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"><div class="arrow ui-icon ui-icon-play "></div><div class="remove ui-icon ui-icon-trash "></div><label>'+this.title+''+((this.required)?"*":"")+'</label><div class="dfield">'+str+'<span class="uh">'+this.userhelp+'</span></div><div class="clearer"></div></div>';
|
1135 |
},
|
1136 |
show:function(){
|
@@ -1191,63 +1105,16 @@ jQuery(window).on('load', function(){
|
|
1191 |
choiceSelected:"",
|
1192 |
showDep:false,
|
1193 |
init:function(){
|
1194 |
-
this.choices = new Array("First Choice","Second Choice","Third Choice");
|
1195 |
-
this.choicesVal = new Array("First Choice","Second Choice","Third Choice");
|
1196 |
-
this.choicesDep = new Array(new Array(),new Array(),new Array());
|
1197 |
},
|
1198 |
display:function(){
|
1199 |
this.choicesVal = ((typeof(this.choicesVal) != "undefined" && this.choicesVal !== null)?this.choicesVal:this.choices.slice(0));
|
1200 |
-
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"
|
1201 |
},
|
1202 |
show:function(){
|
1203 |
-
|
1204 |
-
var l = this.choices;
|
1205 |
-
var v = this.choiceSelected;
|
1206 |
-
var str = "";
|
1207 |
-
if (!(typeof(this.choicesDep) != "undefined" && this.choicesDep !== null))
|
1208 |
-
{
|
1209 |
-
this.choicesDep = new Array();
|
1210 |
-
for (var i=0;i<this.choices.length;i++)
|
1211 |
-
this.choicesDep[i] = new Array();
|
1212 |
-
}
|
1213 |
-
for (var i=0;i<this.choices.length;i++)
|
1214 |
-
{
|
1215 |
-
var classDep = "",attrDep = "";
|
1216 |
-
var d = this.choicesDep;
|
1217 |
-
if (d[i].length>0)
|
1218 |
-
{
|
1219 |
-
classDep = " depItem";
|
1220 |
-
for (var j=0;j<d[i].length;j++)
|
1221 |
-
{
|
1222 |
-
attrDep += ","+d[i][j];
|
1223 |
-
}
|
1224 |
-
}
|
1225 |
-
str += '<option '+((classDep!="")?"dep=\""+attrDep+"\"":"")+' '+((this.choiceSelected==this.choicesVal[i])?"selected":"")+' class="depItem" value="'+htmlEncode(this.choicesVal[i])+'">'+l[i]+'</option>';
|
1226 |
-
}
|
1227 |
-
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'"><label>'+this.title+''+((this.required)?"*":"")+'</label><div class="dfield"><select id="'+this.name+'" name="'+this.name+'" class="field depItemSel '+this.size+((this.required)?" required":"")+'" >'+str+'</select><span class="uh">'+this.userhelp+'</span></div><div class="clearer"></div><div class="clearer"></div></div>';
|
1228 |
},
|
1229 |
showChoiceIntance: function() {
|
1230 |
-
|
1231 |
-
var l = this.choices;
|
1232 |
-
var lv = this.choicesVal;
|
1233 |
-
var v = this.choiceSelected;
|
1234 |
-
if (!(typeof(this.choicesDep) != "undefined" && this.choicesDep !== null))
|
1235 |
-
{
|
1236 |
-
this.choicesDep = new Array();
|
1237 |
-
for (var i=0;i<l.length;i++)
|
1238 |
-
this.choicesDep[i] = new Array();
|
1239 |
-
}
|
1240 |
-
var d = this.choicesDep;
|
1241 |
-
var str = "";
|
1242 |
-
for (var i=0;i<l.length;i++)
|
1243 |
-
{
|
1244 |
-
str += '<div class="choicesEdit"><input class="choice_select" i="'+i+'" type="radio" '+((this.choiceSelected==lv[i])?"checked":"")+' name="choice_select" /><input class="choice_text" i="'+i+'" type="text" name="sChoice'+this.name+'" id="sChoice'+this.name+'" value="'+htmlEncode(l[i])+'"/><input class="choice_value" i="'+i+'" type="text" name="sChoice'+this.name+'V'+i+'" id="sChoice'+this.name+'V'+i+'" value="'+htmlEncode(lv[i])+'"/><a class="choice_add ui-icon ui-icon-circle-plus" i="'+i+'" title="Add another choice."></a><a class="choice_remove ui-icon ui-icon-circle-minus" i="'+i+'" title="Delete this choice."></a></div>';
|
1245 |
-
for (var j=0;j<d[i].length;j++)
|
1246 |
-
str += '<div class="choicesEditDep">If selected show: <select class="dependencies" i="'+i+'" j="'+j+'" dname="'+this.name+'" dvalue="'+d[i][j]+'" ></select><a class="choice_addDep ui-icon ui-icon-circle-plus" i="'+i+'" j="'+j+'" title="Add another dependency."></a><a class="choice_removeDep ui-icon ui-icon-circle-minus" i="'+i+'" j="'+j+'" title="Delete this dependency."></a></div>';
|
1247 |
-
if (d[i].length==0)
|
1248 |
-
str += '<div class="choicesEditDep">If selected show: <select class="dependencies" i="'+i+'" j="'+d[i].length+'" dname="'+this.name+'" dvalue="" ></select><a class="choice_addDep ui-icon ui-icon-circle-plus" i="'+i+'" j="'+d[i].length+'" title="Add another dependency."></a><a class="choice_removeDep ui-icon ui-icon-circle-minus" i="'+i+'" j="'+d[i].length+'" title="Delete this dependency."></a></div>';
|
1249 |
-
}
|
1250 |
-
return '<div class="choicesSet '+((this.showDep)?"show":"hide")+'"><label>Choices</label> <a class="helpfbuilder dep" text="Dependencies are used to show/hide other fields depending of the option selected in this field.">help?</a> <a href="" class="showHideDependencies">'+((this.showDep)?"Hide":"Show")+' Dependencies</a><div><div class="t">Text</div><div class="t">Value</div><div class="clearer"></div></div>'+str+'</div>';
|
1251 |
}
|
1252 |
});
|
1253 |
if (!opt.pub)
|
40 |
}
|
41 |
if (!opt.pub)
|
42 |
{
|
43 |
+
for (var i=0;i<opt.typeList.length;i++)
|
44 |
{
|
45 |
if (opt.typeList[i].id=="category")
|
46 |
$("#tabs-1").append('<div style="clear:both;"></div><br /><div class="category-description">'+opt.typeList[i].name+'</div><hr />');
|
47 |
else
|
48 |
$("#tabs-1").append('<div class="button width40 '+(((i>5 && i!=20) || (i%2==1))?"n":"itemForm")+'" id="'+opt.typeList[i].id+'">'+opt.typeList[i].name+'</div>');
|
49 |
+
}
|
50 |
$("#tabs-1").append('<div class="clearer"></div>');
|
51 |
+
}
|
52 |
if (!opt.pub) $( ".button").button();
|
53 |
var items = new Array();
|
54 |
var itemSelected = -2;
|
587 |
try {
|
588 |
$( "#fbuilder"+opt.identifier ).tooltip({show: false,hide:false,tooltipClass:"uh-tooltip",position: { my: "left top", at: "left bottom", collision: "none" },items: "[uh]",content: function (){return $(this).attr("uh");} });
|
589 |
} catch(e){}
|
590 |
+
|
591 |
}
|
592 |
for (var i=0;i<items.length;i++)
|
593 |
items[i].after_show();
|
814 |
'</span></label></div>'+
|
815 |
dlg+
|
816 |
'</div><div class="clearer"></div></div>';
|
817 |
+
|
818 |
},
|
819 |
after_show:function()
|
820 |
{
|
848 |
maxlength:"",
|
849 |
equalTo:"",
|
850 |
display:function(){
|
851 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
852 |
},
|
853 |
show:function(){
|
854 |
+
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
855 |
},
|
856 |
showSpecialDataInstance: function() {
|
857 |
+
return 'Not available in free version';
|
858 |
}
|
859 |
});
|
860 |
var femail=function(){};
|
890 |
dformat:"digits",
|
891 |
formats:new Array("digits","number"),
|
892 |
display:function(){
|
893 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
894 |
},
|
895 |
show:function(){
|
896 |
+
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
897 |
},
|
898 |
+
showFormatIntance: function() {;
|
899 |
+
return '<div>Not available in free version</div>';
|
|
|
|
|
|
|
900 |
},
|
901 |
showRangeIntance: function() {
|
902 |
+
return 'Not available in free version';
|
903 |
}
|
904 |
});
|
905 |
var fdate=function(){};
|
924 |
return '';
|
925 |
},
|
926 |
showFormatIntance: function() {
|
927 |
+
return '<div>Not available in free version</div>';
|
|
|
|
|
|
|
928 |
},
|
929 |
showSpecialDataInstance: function() {
|
930 |
+
return 'Not available in free version';
|
|
|
|
|
|
|
|
|
|
|
931 |
}
|
932 |
});
|
933 |
var ftextarea=function(){};
|
957 |
required:false,
|
958 |
size:"medium",
|
959 |
display:function(){
|
960 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
961 |
},
|
962 |
show:function(){
|
963 |
+
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
964 |
}
|
965 |
});
|
966 |
var fSectionBreak=function(){};
|
969 |
ftype:"fSectionBreak",
|
970 |
userhelp:"A description of the section goes here.",
|
971 |
display:function(){
|
972 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
973 |
},
|
974 |
show:function(){
|
975 |
+
return '<div class="fields '+this.csslayout+' section_breaks" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
976 |
}
|
977 |
});
|
978 |
var fPageBreak=function(){};
|
980 |
title:"Page Break",
|
981 |
ftype:"fPageBreak",
|
982 |
display:function(){
|
983 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
984 |
},
|
985 |
show:function(){
|
986 |
+
return '<div class="fields '+this.csslayout+' section_breaks" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
987 |
}
|
988 |
});
|
989 |
var fPhone=function(){};
|
994 |
dformat:"### ### ####",
|
995 |
predefined:"888 888 8888",
|
996 |
display:function(){
|
997 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
998 |
},
|
999 |
show:function(){
|
1000 |
+
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1001 |
},
|
1002 |
showFormatIntance: function() {
|
1003 |
+
return '<div>Not available in free version</div>';
|
1004 |
}
|
1005 |
});
|
1006 |
var fCommentArea=function(){};
|
1009 |
ftype:"fCommentArea",
|
1010 |
userhelp:"A description of the section goes here.",
|
1011 |
display:function(){
|
1012 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
1013 |
},
|
1014 |
show:function(){
|
1015 |
+
return '<div class="fields '+this.csslayout+' comment_area" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
1016 |
}
|
1017 |
});
|
1018 |
var fcheck=function(){};
|
1023 |
required:false,
|
1024 |
showDep:false,
|
1025 |
init:function(){
|
|
|
|
|
|
|
|
|
1026 |
},
|
1027 |
display:function(){
|
1028 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
|
|
|
|
|
|
|
|
1029 |
},
|
1030 |
show:function(){
|
1031 |
+
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1032 |
},
|
1033 |
showChoiceIntance: function() {
|
1034 |
+
return '<div class="choicesSet '+((this.showDep)?"show":"hide")+'">Not available in free version<div class="clearer"></div></div>'+str+'</div>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1035 |
}
|
1036 |
});
|
1037 |
var fradio=function(){};
|
1043 |
choiceSelected:null,
|
1044 |
showDep:false,
|
1045 |
init:function(){
|
|
|
|
|
|
|
1046 |
},
|
1047 |
display:function(){
|
|
|
|
|
|
|
|
|
1048 |
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'"><div class="arrow ui-icon ui-icon-play "></div><div class="remove ui-icon ui-icon-trash "></div><label>'+this.title+''+((this.required)?"*":"")+'</label><div class="dfield">'+str+'<span class="uh">'+this.userhelp+'</span></div><div class="clearer"></div></div>';
|
1049 |
},
|
1050 |
show:function(){
|
1105 |
choiceSelected:"",
|
1106 |
showDep:false,
|
1107 |
init:function(){
|
|
|
|
|
|
|
1108 |
},
|
1109 |
display:function(){
|
1110 |
this.choicesVal = ((typeof(this.choicesVal) != "undefined" && this.choicesVal !== null)?this.choicesVal:this.choices.slice(0));
|
1111 |
+
return '<div class="fields" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
1112 |
},
|
1113 |
show:function(){
|
1114 |
+
return '<div class="fields '+this.csslayout+'" id="field'+opt.identifier+'-'+this.index+'">Not available in free version<div class="clearer"></div></div>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1115 |
},
|
1116 |
showChoiceIntance: function() {
|
1117 |
+
return '<div class="choicesSet '+((this.showDep)?"show":"hide")+'">Not available in free version<div class="clearer"></div></div>'+str+'</div>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1118 |
}
|
1119 |
});
|
1120 |
if (!opt.pub)
|