GravityView
2.17
The best, easiest way to display Gravity Forms entries on your website.
|
If this file is called directly, abort. More...
Static Public Member Functions | |
static | array_merge_recursive_distinct (array &$array1, array &$array2) |
array_merge_recursive does indeed merge arrays, but it converts values with duplicate keys to arrays rather than overwriting the value in the first array with the duplicate value in the second array, as array_merge does. More... | |
static | calculate_get_entries_criteria ( $passed_criteria=array(), $form_ids=array()) |
Calculates the Search Criteria used on the self::get_entries / self::get_entry methods. More... | |
static | check_entry_display ( $entry, $view=null) |
Checks if a certain entry is valid according to the View search filters (specially the Adv Filters) More... | |
static | decode_shortcodes ( $string) |
Inspired on ::encode_shortcodes, reverse the encoding by replacing the ascii characters by the shortcode brackets. More... | |
static | entry_has_transaction_data ( $entry=array()) |
Check if an entry has transaction data. More... | |
static | format_date ( $date_string='', $args=array()) |
Allow formatting date and time based on GravityView standards. More... | |
static | generate_notice ( $notice, $class='', $cap='', $object_id=null) |
Display updated/error notice. More... | |
static | get_all_views ( $args=array()) |
Get all existing Views. More... | |
static | get_connected_views ( $form_id, $args=array()) |
Get the views for a particular form. More... | |
static | get_directory_fields ( $post_id, $apply_filter=true, $form_id=0) |
Get the field configuration for the View. More... | |
static | get_directory_widgets ( $view_id, $json_decode=false) |
Get the widget configuration for a View. More... | |
static | get_entries ( $form_ids=null, $passed_criteria=null, &$total=null) |
Retrieve entries given search, sort, paging criteria. More... | |
static | get_entry ( $entry_slug, $force_allow_ids=false, $check_entry_display=true, $view=null) |
Return a single entry object. More... | |
static | get_entry_id ( $entry_id_or_slug='', $force_allow_ids=false) |
Get the entry ID from a string that may be the Entry ID or the Entry Slug. More... | |
static | get_entry_id_from_slug ( $slug) |
Get the entry ID from the entry slug, which may or may not be the entry ID. More... | |
static | get_entry_ids ( $form_id, $search_criteria=array()) |
Wrapper for the Gravity Forms GFFormsModel::search_lead_ids() method. More... | |
static | get_entry_meta ( $form_id, $only_default_column=true) |
get extra fields from entry meta More... | |
static | get_field ( $form, $field_id) |
Returns the field details array of a specific form given the field id. More... | |
static | get_field_array ( $field) |
Return a Gravity Forms field array, whether using GF 1.9 or not. More... | |
static | get_field_label ( $form=array(), $field_id='', $field_value='') |
Retrieve the label of a given field id (for a specific form) More... | |
static | get_field_type ( $form=null, $field_id='') |
Returns the GF Form field type for a certain field(id) of a form. More... | |
static | get_form ( $form_id) |
Returns the form object for a given Form ID. More... | |
static | get_form_fields ( $form='', $add_default_properties=false, $include_parent_field=true) |
Return array of fields' id and label, for a given Form ID. More... | |
static | get_form_from_entry_id ( $entry_slug) |
Get the form array for an entry based only on the entry ID. More... | |
static | get_form_or_form_template ( $form_id=0) |
Returns form object for existing form or a form template. More... | |
static | get_forms ( $active=true, $trash=false, $order_by='id', $order='ASC') |
Alias of GFAPI::get_forms() More... | |
static | get_forms_as_options ( $active=true, $trash=false, $sort_column='id', $sort_dir='ASC') |
Get all forms to use as options in View settings. More... | |
static | get_link_html ( $href='', $anchor_text='', $atts=array()) |
Generate an HTML anchor tag with a list of supported attributes. More... | |
static | get_meta_form_id ( $view_id) |
Get the Gravity Forms form ID connected to a View. More... | |
static | get_meta_template_id ( $view_id) |
Get the template ID (list , table , datatables , map ) for a View. More... | |
static | get_product_field_types () |
Return array of product field types. More... | |
static | get_sortable_fields ( $formid, $current='') |
Render dropdown (select) with the list of sortable fields from a form ID. More... | |
static | get_sortable_fields_array ( $formid, $blocklist=array( 'list', 'textarea')) |
static | get_template_setting ( $post_id, $key) |
Get the setting for a View. More... | |
static | get_template_settings ( $post_id) |
Get all the settings for a View. More... | |
static | get_users ( $context='change_entry_creator', $args=array()) |
Get WordPress users with reasonable limits set. More... | |
static | gv_parse_str ( $string, &$result) |
Do the same than parse_str without max_input_vars limitation: Parses $string as if it were the query string passed via a URL and sets variables in the current scope. More... | |
static | has_cap ( $caps='', $object_id=null, $user_id=null) |
Alias of GravityView_Roles_Capabilities::has_cap() More... | |
static | has_gravityview_shortcode ( $post=null) |
Check whether the post is GravityView. More... | |
static | has_product_field ( $form=array()) |
Check whether a form has product fields. More... | |
static | has_shortcode_r ( $content, $tag='gravityview') |
Placeholder until the recursive has_shortcode() patch is merged. More... | |
static | is_field_numeric ( $form=null, $field='') |
Checks if the field type is a 'numeric' field type (e.g. More... | |
static | js_encrypt ( $content, $message='') |
Encrypt content using Javascript so that it's hidden when JS is disabled. More... | |
static | matches_operation ( $val1, $val2, $operation) |
Wrapper for the GFFormsModel::matches_operation() method that adds additional comparisons, including: 'equals', 'greater_than_or_is', 'greater_than_or_equals', 'less_than_or_is', 'less_than_or_equals', 'not_contains', 'in', and 'not_in'. More... | |
static | send_email ( $from, $to, $bcc, $reply_to, $subject, $message, $from_name='', $message_format='html', $attachments='', $entry=false, $notification=false) |
Send email using GFCommon::send_email() More... | |
If this file is called directly, abort.
Definition at line 19 of file class-common.php.
|
static |
array_merge_recursive does indeed merge arrays, but it converts values with duplicate keys to arrays rather than overwriting the value in the first array with the duplicate value in the second array, as array_merge does.
array | $array1 | |
array | $array2 |
Definition at line 1801 of file class-common.php.
References $value.
|
static |
Calculates the Search Criteria used on the self::get_entries / self::get_entry methods.
array | $passed_criteria | array Input Criteria (search_criteria, sorting, paging) |
array | $form_ids | array Gravity Forms form IDs |
gravityview_search_operator
Modify the search operator for the field (contains, is, isnot, etc) string | $operator | Existing search operator |
array | $filter | array with key , value , operator , type keys |
Prepare date formats to be in Gravity Forms DB format; $passed_criteria may include date formats incompatible with Gravity Forms.
gravityview_search_criteria
Apply final criteria filter (Used by the Advanced Filter extension) array | $criteria | Search criteria used by GravityView |
array | $form_ids | Forms to search |
int | $view_id | ID of the view being used to search |
Definition at line 494 of file class-common.php.
References $criteria, GravityView_frontend\getInstance(), GravityView_View_Data\getInstance(), and gravityview().
Referenced by View\get_entries(), and GV\Mocks\GravityView_frontend_get_view_entries().
|
static |
Checks if a certain entry is valid according to the View search filters (specially the Adv Filters)
GVCommon::calculate_get_entries_criteria();
array | $entry | Gravity Forms Entry object |
\GV\View | \GV\View_Collection | $view | The View or a View Collection |
Check whether the entry is in the entries subset by running a modified query.
$query
Definition at line 936 of file class-common.php.
References $criteria, $entries, $entry, Utils\_GET(), and gravityview().
Referenced by GravityView_frontend\_get_single_entry_title(), gravityview\callback(), and View\content().
|
static |
Inspired on ::encode_shortcodes, reverse the encoding by replacing the ascii characters by the shortcode brackets.
string | $string | Input string to decode |
Definition at line 1874 of file class-common.php.
|
static |
Check if an entry has transaction data.
Checks the following keys to see if they are set: 'payment_status', 'payment_date', 'transaction_id', 'payment_amount', 'payment_method'
array | $entry | Gravity Forms entry array |
Definition at line 201 of file class-common.php.
References $entry, and Utils\get().
Referenced by GravityView_Plugin_Hooks_Gravity_Forms_Coupon\should_hide_coupon_fields(), and GravityView_Field_Product\should_hide_product_fields().
|
static |
Allow formatting date and time based on GravityView standards.
string | $date_string | The date as stored by Gravity Forms (Y-m-d h:i:s GMT) |
string | array | $args | Array or string of settings for output parsed by wp_parse_args() ; Can use raw=1 or `array('raw' => true)\n - rawUn-formatted date string in original Y-m-d h:i:sformat - timestampInteger timestamp returned by GFCommon::get_local_timestamp() - diff"%s ago" format, unless other formatis defined - humanSet $is_human parameter to true for GFCommon::format_date(). Shows diffwithin 24 hours or date after. Format based on blog setting, unless formatis defined. - timeInclude time in the GFCommon::format_date()output - formatDefine your own date format, or diff` format |
Gravity Forms code to adjust date to locally-configured Time Zone
Definition at line 1070 of file class-common.php.
References $args, $format, and Utils\get().
Referenced by GravityView_Merge_Tags\format_date(), GravityView_Field_Date_Created\get_content(), GravityView_Field_Date_Updated\get_content(), and GravityView_Field_Workflow_Current_Status_Timestamp\modify_entry_value_workflow_current_status_timestamp().
|
static |
Display updated/error notice.
string | $notice | text/HTML of notice |
string | $class | CSS class for notice (updated or error ) |
string | $cap | [Optional] Define a capability required to show a notice. If not set, displays to all caps. |
Definition at line 1857 of file class-common.php.
References $class.
Referenced by GravityView_frontend\context_not_configured_warning(), GravityView_Delete_Entry\display_message(), GravityView_Edit_Entry_Render\maybe_print_message(), GravityView_Entry_Approval_Merge_Tags\maybe_show_approval_notice(), GravityView_Edit_Entry_Render\user_can_edit_entry(), and GravityView_Edit_Entry_Render\user_can_edit_field().
|
static |
Get all existing Views.
array | $args | Pass custom array of args, formatted as if for get_posts() |
WP_Post
. Empty array if none found. gravityview/get_all_views/params
Modify the parameters sent to get all views. array | $params | Array of parameters to pass to get_posts() |
Definition at line 114 of file class-common.php.
References $args.
Referenced by GravityView_Search_WP_Widget\form(), Views_Route\get_items(), and Blocks\get_views().
|
static |
Get the views for a particular form.
get_posts()
int | $form_id | Gravity Forms form ID |
array | $args | Pass args sent to get_posts() |
Definition at line 1245 of file class-common.php.
References $args, and $form_id.
Referenced by gravityview_get_connected_views().
|
static |
Get the field configuration for the View.
array(
[other zones]
'directory_list-title' => array(
[other fields] '5372653f25d44' => array( 'id' => string '9' (length=1) 'label' => string 'Screenshots' (length=11) 'show_label' => string '1' (length=1) 'custom_label' => string '' (length=0) 'custom_class' => string 'gv-gallery' (length=10) 'only_loggedin' => string '0' (length=1) 'only_loggedin_cap' => string 'read' (length=4) ) [other fields]
)
[other zones] )
int | $post_id | View ID. |
bool | $apply_filter | Whether to apply the gravityview/configuration/fields filter [Default: true] |
gravityview/configuration/fields
Filter the View fields' configuration array $fields | array Multi-array of fields with first level being the field zones | |
$post_id | int Post ID | |
int | $form_id | The main form ID for the View. |
gravityview/view/configuration/fields
Filter the View fields' configuration array. array | $fields | Multi-array of fields with first level being the field zones. |
\GV\View | $view | The View the fields are being pulled for. |
int | $form_id | The main form ID for the View. |
Definition at line 1388 of file class-common.php.
References $form_id.
Referenced by GravityView_Welcome\getting_started_screen(), and gravityview_get_directory_fields().
|
static |
Get the widget configuration for a View.
int | $view_id | View ID |
bool | $json_decode | Whether to JSON-decode the widget values. Default: false |
Definition at line 1426 of file class-common.php.
References $view_id, and gv_map_deep().
|
static |
Retrieve entries given search, sort, paging criteria.
int | array | $form_ids | The ID of the form or an array IDs of the Forms. Zero for all forms. |
mixed | $passed_criteria | (default: null) |
mixed | &$total | Optional. An output parameter containing the total number of entries. Pass a non-null value to generate the total count. (default: null) |
Reduce # of database calls
gravityview_pre_get_entries
Define entries to be used before GFAPI::get_entries() is called null | $return | If you want to override GFAPI::get_entries() and define entries yourself, tap in here. |
array | $criteria | The final search criteria used to generate the request to GFAPI::get_entries() |
array | $passed_criteria | The original search criteria passed to GVCommon::get_entries() |
int | null | $total | Optional. An output parameter containing the total number of entries. Pass a non-null value to generate |
Remove filter added above
Remove filter added above
gravityview_entries
Modify the array of entries returned to GravityView after it has been fetched from the cache or from GFAPI::get_entries()
. array | null | $entries | Array of entries as returned by the cache or by GFAPI::get_entries() |
array | $criteria | The final search criteria used to generate the request to GFAPI::get_entries() |
array | $passed_criteria | The original search criteria passed to GVCommon::get_entries() |
int | null | $total | Optional. An output parameter containing the total number of entries. Pass a non-null value to generate |
Definition at line 595 of file class-common.php.
References $criteria, $entries, gravityview(), and GravityView_Cache.
Referenced by gravityview_get_entries().
|
static |
Return a single entry object.
Since 1.4, supports custom entry slugs. The way that GravityView fetches an entry based on the custom slug is by searching gravityview_unique_id
meta. The $entry_slug
is fetched by getting the current query var set by is_single_entry()
string | int | $entry_slug | Either entry ID or entry slug string |
boolean | $force_allow_ids | Force the get_entry() method to allow passed entry IDs, even if the gravityview_custom_entry_slug_allow_id filter returns false. |
boolean | $check_entry_display | Check whether the entry is visible for the current View configuration. Default: true. { |
\GV\View | null | $view | The View if $check_entry_display is set to true. In legacy context mocks, can be null. { |
gravityview/common/get_entry/check_entry_display
Override whether to check entry display rules against filters bool | $check_entry_display | Check whether the entry is visible for the current View configuration. Default: true. |
array | $entry | Gravity Forms entry array |
\GV\View | null | $view | The View |
Definition at line 749 of file class-common.php.
References $entry, $entry_slug, Utils\_GET(), View\by_id(), and gravityview().
Referenced by GravityView_API\entry_link(), GravityView_Entry_Link_Shortcode\get_entry(), gravityview_get_entry(), and GravityView_frontend\setEntry().
|
static |
Get the entry ID from a string that may be the Entry ID or the Entry Slug.
string | $entry_id_or_slug | The ID or slug of an entry. |
bool | $force_allow_ids | Whether to force allowing getting the ID of an entry, even if custom slugs are enabled |
gravityview_custom_entry_slug
Whether to enable and use custom entry slugs. boolean | True: Allow for slugs based on entry values. False: always use entry IDs (default) |
gravityview_custom_entry_slug_allow_id
When using a custom slug, allow access to the entry using the original slug (the Entry ID)./entry/custom-slug/
NOT /entry/123/
)/entry/custom-slug/
OR /entry/123/
) boolean | $custom_slug_id_access | True: allow accessing the slug by ID; False: only use the slug passed to the method. |
If we're using custom entry slugs, we do a meta value search instead of doing a straight-up ID search.
Definition at line 697 of file class-common.php.
Referenced by GravityView_Entry_Approval\ajax_update_approved(), and GravityView_Entry_Approval\get_entry_status().
|
static |
Get the entry ID from the entry slug, which may or may not be the entry ID.
string | $slug | The entry slug, as returned by GravityView_API::get_entry_slug() |
NULL
if not gravityview/common/get_entry_id_from_slug/form_id
The form ID used to get the custom entry ID. Change this to avoid collisions with data from other forms with the same values and the same field ID. int | $form_id | ID of the form to search. Default: 0 (searches all forms) |
Definition at line 235 of file class-common.php.
References $form_id.
|
static |
Wrapper for the Gravity Forms GFFormsModel::search_lead_ids() method.
int | $form_id | ID of the Gravity Forms form |
Definition at line 476 of file class-common.php.
References $form_id.
Referenced by gravityview_get_entry_ids().
|
static |
get extra fields from entry meta
string | $form_id | (default: '') |
Definition at line 449 of file class-common.php.
References $field, and $form_id.
Referenced by gravityview_get_entry_meta().
|
static |
Returns the field details array of a specific form given the field id.
Alias of GFFormsModel::get_field
GFFormsModel::get_field
array | int | $form | Form array or ID |
string | int | $field_id |
Definition at line 1161 of file class-common.php.
References $field, $field_id, and GV\$form.
Referenced by gravityview_get_field().
|
static |
Return a Gravity Forms field array, whether using GF 1.9 or not.
array | GF_Fields | $field | Gravity Forms field or array |
Definition at line 89 of file class-common.php.
References $field.
|
static |
Retrieve the label of a given field id (for a specific form)
array | $form | Gravity Forms form array |
string | $field_id | ID of the field. If an input, full input ID (like 1.3 ) |
string | array | $field_value | Raw value of the field. |
Definition at line 1130 of file class-common.php.
References $field, $field_id, $field_value, GV\$form, $label, and Utils\get().
Referenced by GravityView_Field_Gravatar\_get_email_field_choices(), and gravityview_get_field_label().
|
static |
Returns the GF Form field type for a certain field(id) of a form.
object | $form | Gravity Forms form |
mixed | $field_id | Field ID or Field array |
Definition at line 1559 of file class-common.php.
References $field, $field_id, and GV\$form.
Referenced by gravityview_get_field_type().
|
static |
Returns the form object for a given Form ID.
mixed | $form_id |
Definition at line 27 of file class-common.php.
References $form_id.
Referenced by GravityView_Field\_filter_gform_custom_merge_tags(), GravityView_frontend\_get_single_entry_title(), GravityView_Admin_View_Item\getOutput(), gravityview_get_form(), GravityView_Entry_Approval\update_approved_meta(), and GravityView_Search_WP_Widget\widget().
|
static |
Return array of fields' id and label, for a given Form ID.
string | array | $form_id | (default: '') or $form object |
bool | $add_default_properties | |
bool | $include_parent_field |
In case of email/email confirmation, the input for email has the same id as the parent field
gravityview/common/get_form_fields
Modify the form fields shown in the Add Field field picker. array | $fields | Associative array of fields, with keys as field type, values an array with the following keys: (string) label (required), (string) type (required), desc , (string) customLabel , (GF_Field) parent , (string) adminLabel , (bool)adminOnly |
array | $form | GF Form array |
bool | $include_parent_field | Whether to include the parent field when getting a field with inputs |
Definition at line 344 of file class-common.php.
References $field, GV\$form, and GravityView_Fields\get_all().
Referenced by gravityview_get_form_fields().
|
static |
Get the form array for an entry based only on the entry ID.
int | string | $entry_slug | Entry slug |
Definition at line 142 of file class-common.php.
References $entry, $entry_slug, and GV\$form.
Referenced by gravityview_get_form_from_entry_id().
|
static |
Returns form object for existing form or a form template.
int | string | $form_id | Gravity Forms form ID. Default: 0. |
Definition at line 53 of file class-common.php.
References GV\$form, $form_id, and GravityView_Ajax\pre_get_form_fields().
Referenced by GravityView_Admin_Views\render_additional_fields(), GravityView_Admin_Views\render_available_fields(), and GravityView_Render_Settings\render_field_options().
|
static |
Alias of GFAPI::get_forms()
bool | string | $active | Status of forms. Use any to get array of forms with any status. Default: true |
bool | $trash | Include forms in trash? Default: false |
string | array | $order_by | Optional. Either the field name to order by or an array of multiple orderby fields as $orderby => $order. |
string | $order | Optional. Either 'ASC' or 'DESC'. Only used if $orderby is a string. |
Definition at line 317 of file class-common.php.
References $forms.
Referenced by gravityview_get_forms().
|
static |
Get all forms to use as options in View settings.
GFAPI::get_form() -by ::defaults()
bool | $active | True if active forms are returned. False to get inactive forms. Defaults to true. |
bool | $trash | True if trashed forms are returned. False to exclude trash. Defaults to false. |
string | $sort_column | The column to sort the results on. |
string | $sort_dir | The sort direction, ASC or DESC. |
Definition at line 283 of file class-common.php.
References GV\$form, and $forms.
Referenced by View_Settings\defaults().
|
static |
Generate an HTML anchor tag with a list of supported attributes.
string | $href | URL of the link. Sanitized using esc_url_raw() |
string | $anchor_text | The text or HTML inside the anchor. This is not sanitized in the function. |
array | string | $atts | Attributes to be added to the anchor tag. Parsed by wp_parse_args() , sanitized using esc_attr() |
gravityview/get_link/allowed_atts
Modify the attributes that are allowed to be used in generating links array | $allowed_atts | Array of attributes allowed |
Fix potential security issue with target=_blank
Definition at line 1705 of file class-common.php.
References $href, $output, and $value.
Referenced by gravityview_get_link().
|
static |
Get the Gravity Forms form ID connected to a View.
int | $view_id | The ID of the View to get the connected form of |
Definition at line 1295 of file class-common.php.
References $view_id.
Referenced by gravityview_get_form_id(), and GravityView_Search_WP_Widget\widget().
|
static |
Get the template ID (list
, table
, datatables
, map
) for a View.
int | $view_id | The ID of the View to get the layout of |
Definition at line 1308 of file class-common.php.
References $view_id.
Referenced by gravityview_get_template_id().
|
static |
Return array of product field types.
Modify the value using the gform_product_field_types
filter
Definition at line 183 of file class-common.php.
Referenced by GravityView_Field_Product\edit_entry_field_blocklist().
|
static |
Render dropdown (select) with the list of sortable fields from a form ID.
int | $formid | Form ID |
Definition at line 1454 of file class-common.php.
References $field, and $output.
Referenced by gravityview_get_sortable_fields().
|
static |
int | $formid | Gravity Forms form ID |
array | $blocklist | Field types to exclude |
Merge date and time subfields.
gravityview/common/sortable_fields
Filter the sortable fields array | $fields | Sub-set of GF form fields that are sortable |
int | $formid | The Gravity Forms form ID that the fields are from |
Definition at line 1494 of file class-common.php.
References $field.
Referenced by GravityView_HTML_Elements\field_dropdown().
|
static |
Get the setting for a View.
If the setting isn't set by the View, it returns the plugin default.
int | $post_id | View ID |
string | $key | Key for the setting |
Definition at line 1343 of file class-common.php.
References $settings.
Referenced by GravityView_Edit_Entry\check_user_cap_edit_entry(), and gravityview_get_template_setting().
|
static |
Get all the settings for a View.
::defaults() Parses the settings with the plugin defaults as backups.
int | $post_id | View ID |
Definition at line 1320 of file class-common.php.
References $settings.
Referenced by gravityview_get_template_settings(), and oEmbed\render_frontend().
|
static |
Get WordPress users with reasonable limits set.
string | $context | Where are we using this information (e.g. change_entry_creator, search_widget ..) |
array | $args | Arguments to modify the user query. See get_users() { |
gravityview/get_users/{$context}
There are issues with too many users using get_users() where it breaks the select. We try to keep it at a reasonable number. $context
is where are we using this information (e.g. change_entry_creator, search_widget ..) array | $settings | Settings array, with number key defining the # of users to display |
Definition at line 1823 of file class-common.php.
References $args.
Referenced by GravityView_Change_Entry_Creator\add_select(), GravityView_Change_Entry_Creator\entry_creator_get_users(), and GravityView_Widget_Search\get_created_by_choices().
|
static |
Do the same than parse_str without max_input_vars limitation: Parses $string as if it were the query string passed via a URL and sets variables in the current scope.
$string | string string to parse (not altered like in the original parse_str(), use the second parameter!) |
$result | array If the second parameter is present, variables are stored in this variable as array elements |
Definition at line 1665 of file class-common.php.
Referenced by _gravityview_process_posted_fields().
|
static |
Alias of GravityView_Roles_Capabilities::has_cap()
string | array | $caps | Single capability or array of capabilities |
int | $object_id | (optional) Parameter can be used to check for capabilities against a specific object, such as a post or user |
int | null | $user_id | (optional) Check the capabilities for a user who is not necessarily the currently logged-in user |
Definition at line 77 of file class-common.php.
References GravityView_Roles_Capabilities\has_cap().
Referenced by GravityView_Compatibility\_shortcode_gf_notice(), GravityView_Admin_ApproveEntries\add_entry_approved_hidden_input(), GravityView_Admin_Bar\add_floaty_icon(), GravityView_Admin_Bar\add_hooks(), GravityView_Admin_Views\add_post_type_columns(), GravityView_Admin_ApproveEntries\add_scripts_and_styles(), GravityView_Admin_Add_Shortcode\add_shortcode_button(), Plugin\add_to_gravitykit_admin_menu(), GravityView_Admin_Notices\admin_notice(), GravityView_Entry_Approval\ajax_update_approved(), GravityView_Entry_Approval\autounapprove(), gvfield\callback(), gravityview\callback(), View\can_render(), GravityView_Delete_Entry\check_user_cap_delete_entry(), GravityView_Duplicate_Entry\check_user_cap_duplicate_entry(), GravityView_Edit_Entry\check_user_cap_edit_entry(), GravityView_Edit_Entry_Render\check_user_cap_edit_field(), View\content(), GravityView_Admin_Duplicate_View\current_user_can_copy(), GravityView_Field_Notes\display_note(), GravityView_Edit_Entry_Render\filter_admin_only_fields(), GravityView_Field_Notes\get_add_note_part(), GravityView_Admin_Views\get_connected_form_links(), View\get_entries(), GravityView_Edit_Entry_Locking\get_lock_ui(), GravityView_Field_Notes\get_note_email_fields(), Views_Route\get_sub_item_permissions_check(), GravityView_Admin_Views\gform_toolbar_menu(), GravityView_frontend\is_entry_approved(), Field\is_visible(), GravityView_Change_Entry_Creator\load(), GravityView_Field_Notes\maybe_add_note(), GravityView_Field_Notes\maybe_delete_notes(), GravityView_Duplicate_Entry\maybe_duplicate_list(), GravityView_Field_Entry_Approval\maybe_not_visible(), GravityView_Field_Entry_Approval\maybe_prevent_field_render(), Plugin_Settings\maybe_save_app_settings(), GravityView_Field_Notes\maybe_send_entry_notes(), GravityView_Entry_Approval_Merge_Tags\maybe_update_approved(), GravityView_Edit_Entry_Render\maybe_update_post_fields(), GravityView_Field_Unsubscribe\modify_entry_value_unsubscribe(), GravityView_Admin\no_views_text(), Views_Route\prepare_view_for_response(), GravityView_Field_Notes\process_add_note(), GravityView_Field_Notes\process_delete_notes(), GravityView_frontend\process_search_only_approved(), oEmbed\render_frontend(), GravityView_frontend\render_view(), GravityView_Edit_Entry_Locking\request_lock(), GravityView_Admin_Views\save_postdata(), Plugin\setup_gravitykit_admin_menu_redirects(), GravityView_Admin_ApproveEntries\show_approve_entry_column(), GravityView_Support_Port\show_for_user(), GravityView_Entry_Approval\update_bulk(), GravityView_Cache\use_cache(), and GravityView_Support_Port\user_field().
|
static |
Check whether the post is GravityView.
gravityview
?WP_Post | $post | WordPress post object |
Definition at line 1178 of file class-common.php.
References $post.
Referenced by has_gravityview_shortcode().
|
static |
Check whether a form has product fields.
array | $form | Gravity Forms form array |
Definition at line 165 of file class-common.php.
References GV\$form.
Referenced by GravityView_Field_Product\clear_product_info_cache().
|
static |
Placeholder until the recursive has_shortcode() patch is merged.
string | $content | Content to check whether there's a shortcode |
string | $tag | Current shortcode tag |
Definition at line 1199 of file class-common.php.
References $content.
Referenced by gravityview_has_shortcode_r().
|
static |
Checks if the field type is a 'numeric' field type (e.g.
to be used when sorting)
int | array | $form | form ID or form array |
int | array | $field | field key or field array |
gravityview/common/numeric_types
What types of fields are numeric? array | $numeric_types | Fields that are numeric. Default: [ number, time ] |
Definition at line 1579 of file class-common.php.
References $field, GV\$form, $gv_field, and GravityView_Fields\get().
Referenced by View\get_entries(), and GravityView_frontend\get_search_criteria_paging().
|
static |
Encrypt content using Javascript so that it's hidden when JS is disabled.
This is mostly used to hide email addresses from scraper bots.
string | $content | Content to encrypt |
string | $message | Message shown if Javascript is disabled |
gravityview/phpenkoder/msg
Modify the message shown when Javascript is disabled and an encrypted email field is displayed string | $message | Existing message |
string | $content | Content to encrypt |
Definition at line 1625 of file class-common.php.
References $content, $output, and GRAVITYVIEW_DIR.
|
static |
Wrapper for the GFFormsModel::matches_operation() method that adds additional comparisons, including: 'equals', 'greater_than_or_is', 'greater_than_or_equals', 'less_than_or_is', 'less_than_or_equals', 'not_contains', 'in', and 'not_in'.
mixed | $val1 | Left side of comparison |
mixed | $val2 | Right side of comparison |
string | $operation | Type of comparison |
Definition at line 812 of file class-common.php.
References $value, gravityview_get_context(), and gravityview_maybe_convert_date_string_to_timestamp().
Referenced by gvlogic\callback(), and GravityView_GFFormsModel\is_value_match().
|
static |
Send email using GFCommon::send_email()
string | $from | Sender address (required) |
string | $to | Recipient address (required) |
string | $bcc | BCC recipients (required) |
string | $reply_to | Reply-to address (required) |
string | $subject | Subject line (required) |
string | $message | Message body (required) |
string | $from_name | Displayed name of the sender |
string | $message_format | If "html", sent text as text/html . Otherwise, text/plain . Default: "html". |
string | array | $attachments | Optional. Files to attach. { |
array | false | $entry | Gravity Forms entry array, related to the email. Default: false. |
array | false | $notification | Gravity Forms notification that triggered the email. { |
Definition at line 1902 of file class-common.php.
References $entry.
Referenced by GravityView_Field_Notes\maybe_send_entry_notes().