=== SmartRoute – Conditional Email Routing for Gravity Forms ===
Contributors: wpsmartroute
Tags: gravityforms, email-routing, notifications, conditional-logic, lead-routing
Requires at least: 6.0
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Conditional email routing for Gravity Forms. Send notifications to different recipients based on form answers using a CSV contact list.

== Description ==

**SmartRoute for Gravity Forms** lets you send Gravity Forms notifications to different email addresses based on what users answer in your forms. Route form submissions based on dropdown, radio, checkbox, or any other field — using a simple CSV contact list, no code required.

Whether you manage a multi-location business, a sales team, or a support desk, SmartRoute makes sure every form submission lands in the right inbox automatically.

= How it works =

1. **Import your CSV** — Upload your contact list with any criteria columns (department, region, category, product, language…)
2. **Map columns** — Tell SmartRoute which column holds the email address and which columns to use as routing criteria
3. **Define rules** — Build conditional notification routing using form fields and AND conditions
4. **Done** — SmartRoute intercepts Gravity Forms notifications and sends them to the right contact automatically

= Use cases =

* **Multi-location businesses** — Route inquiries to the right office based on city, region, or country
* **Sales teams** — Assign form leads automatically based on product interest, company size, or budget
* **Support requests** — Route tickets by department, issue type, or priority level
* **Educational institutions** — Send applications to the right program coordinator or campus
* **Real estate agencies** — Forward listings inquiries to the agent covering that property type or area
* **Healthcare and clinics** — Direct appointment requests to the right specialist or location
* **Multi-language sites** — Route submissions to native-speaking team members

= Features =

* CSV-based routing — no database or code required
* Smart rules engine with AND conditions
* Supports "contains any of" operator for multi-value matching
* Works with dropdown, radio, checkbox, text, and any Gravity Forms field type
* Compatible with Gravity Forms multi-page forms
* Activity log — track every routed notification
* Works with any Gravity Forms notification
* Fallback behavior when no rule matches (send default notification or block)

= SmartRoute Pro =

Unlock additional features with **[SmartRoute Pro](https://wp-smartroute.com/#Pricing)**:

* **Analytics dashboard** — charts, match rates, and top recipients
* **CSV export** — export your routing activity log
* **Priority support** — email support with fast response times



= Learn more =

Visit [wp-smartroute.com](https://wp-smartroute.com) for documentation, tutorials, and pro plans.

== Installation ==

1. Upload the plugin files to `/wp-content/plugins/smartroute-for-gravity-forms/`
2. Activate the plugin through the **Plugins** menu in WordPress
3. Go to **SmartRoute** in the admin sidebar
4. Select a Gravity Forms form and follow the 3-step setup

**Requirements:** Gravity Forms must be installed and activated.

== Frequently Asked Questions ==

= Do I need to know how to code? =

Not at all. SmartRoute has a visual interface — upload your CSV, map columns, and define rules with a few clicks.

= How is this different from the built-in Gravity Forms routing feature? =

Gravity Forms has a basic routing option built into notifications, but it requires you to manually create one rule per recipient inside each notification, and it doesn't scale. SmartRoute lets you manage hundreds of recipients from a single CSV file, with reusable rules, AND conditions, and an activity log.

= Can I route based on a dropdown, radio button, or checkbox field? =

Yes. SmartRoute works with all Gravity Forms field types, including dropdowns, radio buttons, checkboxes, text fields, numbers, and dates.

= Can I send notifications to multiple recipients at once? =

Yes. A single rule can match multiple contacts in your CSV, and SmartRoute will send the notification to all of them.

= Does it work with Gravity Forms conditional logic? =

Yes. SmartRoute runs after Gravity Forms processes your form, so any conditional logic you've set up on fields or notifications still works as expected.

= Does it work with any Gravity Forms notification? =

Yes. SmartRoute intercepts any GF notification and routes it to the right recipient. Your form setup stays untouched.

= What happens if no rule matches? =

The original Gravity Forms notification is sent normally. You can also configure SmartRoute to block the notification if no match is found.

= Can I route based on user location or country? =

Yes, as long as your form captures the location (via a dropdown, address field, or any field your CSV criteria can match).

= Does it support Gravity Forms multi-page forms? =

Yes. SmartRoute reads the final submission, so multi-page forms work without any extra configuration.

= What format should my CSV be in? =

Any CSV with semicolon, comma, or tab separator. SmartRoute auto-detects the separator and columns. No limit on number of rows or columns.

= Can I use it on multiple sites? =

The Single Site plan covers 1 site. The Agency plan covers unlimited sites.

= Does SmartRoute store form submission data? =

SmartRoute only logs metadata about routed notifications (form ID, matched rule, recipient) for the activity log. The form submission data itself stays in Gravity Forms — SmartRoute does not duplicate or send your data anywhere else.

== Screenshots ==

1. Overview — 3-step setup (CSV import, column mapping, routing rules)
2. Routing rules — define conditions with AND logic
3. Activity log — track every routed notification
4. Statistics dashboard — match rates and top recipients (SmartRoute Pro only, not included)

== Privacy ==

SmartRoute processes form submission data locally on your WordPress site to determine the correct recipient. No submission data is sent to external servers.

The activity log stores only the form ID, the matched rule, the recipient email, and a timestamp. You can clear the activity log at any time from the plugin settings.

== Credits ==

SmartRoute is an independent add-on for [Gravity Forms](https://www.gravityforms.com/). Gravity Forms is a registered trademark of Rocketgenius, Inc. This plugin is not affiliated with or endorsed by Rocketgenius.

== Changelog ==

= 1.0.0 =
* Initial release

== Upgrade Notice ==

= 1.0.0 =
Initial release of SmartRoute for Gravity Forms.