Ejemplo n.º 1
0
 public static function add_email_list()
 {
     global $frm_field, $frm_vars;
     $email_key = $_POST['list_id'];
     $form_id = $_POST['form_id'];
     $frm_form = new FrmForm();
     $form = $frm_form->getOne($form_id);
     unset($frm_form);
     $first_email = $email_key ? false : true;
     $notification = FrmProFormsHelper::get_default_notification_opts();
     $values = array('fields' => array(), 'id' => $form_id);
     $fields = $frm_field->getAll(array('fi.form_id' => $form_id));
     foreach ($fields as $k => $f) {
         $values['fields'][] = (array) $f;
         unset($k);
         unset($f);
     }
     include FrmAppHelper::plugin_path() . '/classes/views/frm-forms/notification.php';
     die;
 }
Ejemplo n.º 2
0
 public static function get_default_opts()
 {
     global $frmpro_settings;
     return array('edit_value' => $frmpro_settings->update_value, 'edit_msg' => $frmpro_settings->edit_msg, 'edit_action' => 'message', 'edit_url' => '', 'edit_page_id' => 0, 'logged_in' => 0, 'logged_in_role' => '', 'editable' => 0, 'save_draft' => 0, 'draft_msg' => __('Your draft has been saved.', 'formidable'), 'editable_role' => '', 'open_editable_role' => '-1', 'copy' => 0, 'single_entry' => 0, 'single_entry_type' => 'user', 'success_page_id' => '', 'success_url' => '', 'ajax_submit' => 0, 'create_post' => 0, 'cookie_expiration' => 8000, 'post_type' => 'post', 'post_category' => array(), 'post_content' => '', 'post_excerpt' => '', 'post_title' => '', 'post_name' => '', 'post_date' => '', 'post_status' => '', 'post_custom_fields' => array(), 'post_password' => '', 'notification' => array(0 => FrmProFormsHelper::get_default_notification_opts()));
     /*
     Old emailer values for reference
     'auto_responder' => 0, 
     'ar_email_to' => '', 'ar_reply_to' => get_option('admin_email'), 'ar_reply_to_name' => get_option('blogname'),
     'ar_plain_text' => 0, 'ar_update_email' => 0,
     'ar_email_subject' => '', 'ar_email_message' => '', 
     */
 }