GravityView
2.17
The best, easiest way to display Gravity Forms entries on your website.
|
Public Member Functions | |
__construct () | |
check_ajax_nonce () | |
--—— AJAX ----—— More... | |
create_preset_form () | |
Create the preset form requested before the View save. More... | |
get_active_areas () | |
Returns template active areas given a template ID AJAX callback. More... | |
get_available_fields_html () | |
AJAX action to get HTML markup for form(s) or template fields AJAX callback. More... | |
get_field_options () | |
Returns field options - called by ajax when dropping fields into active areas AJAX callback. More... | |
get_preset_fields_config () | |
Fill in active areas with preset configuration according to the template selected. More... | |
get_sortable_fields () | |
Given a View id, calculates the assigned form, and returns the form fields (only the sortable ones ) AJAX callback. More... | |
import_fields ( $file) | |
Import fields configuration from an exported WordPress View preset. More... | |
import_form ( $xml_or_json_path='') | |
Import Gravity Form XML or JSON. More... | |
Static Public Member Functions | |
static | pre_get_form_fields ( $template_id='') |
Get the form fields for a preset (no form created yet) More... | |
Private Member Functions | |
_exit ( $mixed=NULL) | |
Handle exiting the script (for unit testing) More... | |
Definition at line 3 of file class-ajax.php.
__construct | ( | ) |
Definition at line 5 of file class-ajax.php.
|
private |
Handle exiting the script (for unit testing)
bool | false | $mixed |
Don't exit if we're running test suite.
Definition at line 33 of file class-ajax.php.
Referenced by check_ajax_nonce(), create_preset_form(), get_active_areas(), get_available_fields_html(), get_field_options(), get_preset_fields_config(), and get_sortable_fields().
check_ajax_nonce | ( | ) |
--—— AJAX ----——
Verify the nonce. Exit if not verified.
Definition at line 52 of file class-ajax.php.
References _exit().
Referenced by create_preset_form(), get_active_areas(), get_available_fields_html(), get_field_options(), get_preset_fields_config(), and get_sortable_fields().
create_preset_form | ( | ) |
Create the preset form requested before the View save.
Definition at line 189 of file class-ajax.php.
References GV\$form, _exit(), check_ajax_nonce(), gravityview(), and import_form().
get_active_areas | ( | ) |
Returns template active areas given a template ID AJAX callback.
Definition at line 111 of file class-ajax.php.
References _exit(), and check_ajax_nonce().
get_available_fields_html | ( | ) |
AJAX action to get HTML markup for form(s) or template fields AJAX callback.
Definition at line 64 of file class-ajax.php.
References _exit(), and check_ajax_nonce().
get_field_options | ( | ) |
Returns field options - called by ajax when dropping fields into active areas AJAX callback.
Definition at line 254 of file class-ajax.php.
References $form_id, _exit(), check_ajax_nonce(), gravityview(), gravityview_strip_whitespace(), and GravityView_Render_Settings\render_field_options().
get_preset_fields_config | ( | ) |
Fill in active areas with preset configuration according to the template selected.
Definition at line 135 of file class-ajax.php.
References _exit(), check_ajax_nonce(), Widget\get_default_widget_areas(), gravityview(), and import_fields().
get_sortable_fields | ( | ) |
Given a View id, calculates the assigned form, and returns the form fields (only the sortable ones ) AJAX callback.
Definition at line 287 of file class-ajax.php.
References GV\$form, _exit(), check_ajax_nonce(), gravityview_get_sortable_fields(), gravityview_strip_whitespace(), and pre_get_form_fields().
import_fields | ( | $file | ) |
Import fields configuration from an exported WordPress View preset.
string | $file | path to file |
Definition at line 355 of file class-ajax.php.
References gravityview(), and GRAVITYVIEW_DIR.
Referenced by get_preset_fields_config().
import_form | ( | $xml_or_json_path = '' | ) |
Import Gravity Form XML or JSON.
string | $xml_or_json_path | Path to form XML or JSON file |
Definition at line 222 of file class-ajax.php.
References $forms, and gravityview().
Referenced by create_preset_form().
|
static |
Get the form fields for a preset (no form created yet)
string | $template_id | Preset template |
Definition at line 319 of file class-ajax.php.
References GV\$form, $forms, and gravityview().
Referenced by GVCommon\get_form_or_form_template(), GravityView_Widget_Search\get_searchable_fields(), get_sortable_fields(), and GravityView_Admin_Views\render_active_areas().