Introduction
The Feed Meta object for the Zapier Add-On is an associative array containing the properties which determine how the add-on should process the form submission.
$feed['meta'] = array(
'feedName' => 'Your Feed Name',
'feed_condition_conditional_logic' => true,
'feed_condition_conditional_logic_object' => array(
'conditionalLogic' => array(),
),
);
Usage
We recommend accessing the $feed meta using the rgar() or rgars() functions, e.g.:
$conditional_logic_enabled = rgars( $feed, 'meta/feedCondition' );
if ( $conditional_logic_enabled ) {
// Conditional logic is enabled for this feed.
$logic_rules = rgars( $feed, 'meta/feed_condition_conditional_logic_object/conditionalLogic/rules' );
foreach ( $logic_rules as $rule ) {
// Process each conditional logic rule.
$field_id = rgar( $rule, 'fieldId' );
$operator = rgar( $rule, 'operator' );
$value = rgar( $rule, 'value' );
// Example: Use $field_id, $operator, and $value in your logic.
}
}
Properties
- feedName string
The feed name which appears on the add-ons feeds tab.
-
zapURL string
The Zapier hosted URL where the entry data will be sent when the feed is processed.
-
adminLabels string
Indicates if the field admin labels should be sent to Zapier instead of the main labels, if configured. Possible values: 1 or 0.
-
feed_condition_conditional_logic boolean
Is the feed condition (conditional logic) setting enabled. Default is false.
-
feed_condition_conditional_logic_object array
An associative array containing the conditional logic rules. See the Conditional Logic Object for more details.
-
legacy boolean
Indicates if the feed was migrated from the non-framework version of the add-on (pre 4.0).
-
legacy_id int
The feed ID when it was stored in the legacy rg_zapier table.