Conditional Notifications Plugin for Gravity Forms
Gravity Forms is one of those plugins that many enjoy and make use of. A recent project of mine involved adding some functionality that seems as indispensable as conditional field logic – conditional notifications.
Based on the values of form fields selected notification settings are overridden, including e-mails and, more importantly content, and whether a notification is sent or not in the first place.
This Gravity Forms Addon allows users to select specific conditions that override the default notification settings. The first condition that is met will provide the settings that replace the ones that are set in the Notification area for a form. If no condition is met for a form the default Notification settings happen.
A fantastic use for this Gravity Forms Add-on would be to have an auto-responder setup for an inquiry form, where visitors select a predefined inquiry (although an FAQ would handle that in most cases). Applications to specific departments where a response arrives with that departments contact details, terms, working hours, or something. In short, should be quite useful.
Gravity Forms Conditional Notifications Add-on is available on Github.
I’m giving your plugin a whirl. I’ve installed it, and I’m having trouble setting up an address field as conditional -so I can attach your conditional notification requirement.
I need to send emails out based on US state selections.
Any suggestions how to get that working?
Hey Bryan,
Thanks for trying it out. Notification conditions can only be dropdowns, check boxes and radio buttons. What sort of address field are we talking? Text? Do you think that adding a “contains” or “is equal to” functionality for text fields would be convenient to have? I never met any use for native text conditionals before.
Edit: ah, checked out the Address forms, I see the drop-downs contained within, never thought of them. That’s quite a miss, especially the “Country” in International address type. I’ll see what I can do and post an update. Thanks for pointing it out.
Edit 2: I have opened an issue on github to keep track of it all: https://github.com/soulseekah/Gravity-Forms-Conditional-Notifications/issues/1
Any way to make the time of day a condition? Need the autoresponder to send one message during business hours, and a different one after hours.
Roberto, this should be quite easy to work out by adding new search variables called
time_from
andtime_to
perhaps which depending on the time of day would trigger a different condition set.https://github.com/soulseekah/Gravity-Forms-Conditional-Notifications/blob/master/gravityforms-conditional-notifications/gravityforms-conditional-notifications.php#L49
The UI would also need to have some more fields added to the
$condition
array that gets passed around, etc. Hope this helps.hey there,
thanks for your great plugin.
could you explain me how i could change the script so that they work as AND conditions instead of OR?
thanks & greets
troy
Troy, thanks for stopping by. Check out https://github.com/soulseekah/Gravity-Forms-Conditional-Notifications/blob/master/gravityforms-conditional-notifications/gravityforms-conditional-notifications.php#L58 you would have to keep track of the two conditions that you would like to AND-relate here. I image you would also need to modify the UI a bit and add some extra selectors. Hope this helps. Good luck!
Hello,
Is there a way that I can make two conditions with the same value? as when I tried doing that, it overwrites the first one. thanks for the great plugin btw.
Not sure how that is possible, can you elaborate with some examples?
Hi, I’m trying out your plugin, it is possible to add a condition also for pricing drop down fields? I think only for drop downs, radio buttons and check boxes is quite limitating!
Let me know!
Hi Riccardo, I’m not sure it is. I’m not really maintaining the plugin, but if you want I can guide you through the code so you can write a patch for this. Thanks for your interest.
Hey, I tried the plugin, but autoresponse emails never came back, any idea?
Im runing the alst version.
It is probably a general e-mail issue or misconfiguration. Check your /var/log/mail.* logs, turn on error reporting (set
WP_DEBUG
totrue
to get all warnings and errors). And make sure to correctly isolate the issue, does your WordPress send out e-mails in general (try towp_mail
yourself something)? Does Gravity Forms send you out the regular autoresponse e-mails? Did you check you spam box? Lots to go wrong here, as you can see, maybe the conditions in the Gravity Forms Conditional Notifications plugin are setup incorrectly? Let me know, I’ll be glad to help you debug the issue and find out what’s wrong with your setup.Can I put html in the response email? I have tried with tables then divs and writing a whole HTML page in there. The HTML code doesn’t show up ever but the text is never formatted. right now I just have a few h1 – h2 tags on my text and it changes then a bit but I can’t change color or margin. any suggestions?
Robert, does the e-mail come through with the tags intact? How does the “view-source” of the e-mail look like? Are you using the latest code?
[…] have written yet another Gravity Forms plugin/addon. This time the plugin was to generate bulk reports for form […]
Hi, thanks for yor great plugin. I installed it, but I’m having trouble setting it. I’ve a form make donations in my web page. The donations method is selected with a 3 radio buttoms seT. I’d like to send different message for each radio buttom. I select my form in Conditional Notifications menu and Add new condition, but “if” and “is” dropdowns are empty. Am I doing something wrong? I’m running Gravity Forms 1.6.1 and WordPress 3.1.2.
Thanks
Ramon,
There are bound to be errors with such old untested versions. I’m going to contact you via e-mail so that you can provide me more information.
Hi! Interesting plug-in 🙂
I’m looking for a way to “schedule” Gravity Forms notifications based on the value of a date-picker field. Here’s the intended use of the form: the user fills out the form and indicates via a date-picker field the future date in which they will do something (have an event); what I’d like to do is be able to send them a notification email AFTER that date (i.e. “How was your event?”).
Can this be achieved with your plug-in?
Andres, this should be possible, although I’ve not tested logic with dates. You can file a feature request on github if it doesn’t work. Thanks 😉
Andres,
I’m looking to do the same – schedule a notification after the event takes place, based on the date picker. It’s 3 years after your post in this forum, so I doubt you’ll get this. If so, please let me know if you were able to get it to work.
Franklin, did you try setting the condition on the date picker field?
Hey, could you shoot me an email to franklin@rimtours.com to simplify this back and forth?
Your question about setting conditions on the date picker field did not make sense – as that date field is a required field and is filled out for every reservation (hence, it shows in the form for all users under all conditons.)
What I need is to be able to set a condition in the notification builder, but, after checking the “Enable conditional logic” the date picker field does not show in the list of all the fields in the form. It is the only field that does show in the selector (probably because it is the jscript date picker and not a drop down.)
Also, the conditional logic is to send a notification if the field = something. What I need is to send the notification at a later date, that date being what is entered in that field.
I meant to say “it is the only field that does NOT show in the selector”
Your plug-in saved my butt in 2012. I’ve used it successfully for a year-and-a-half.
Now I’m migrating my site, and couldn’t find your plug-in in the WP plug-ins directory.
Turns out, Gravity Forms rolled your plug-in functionality into their latest version. It’s so suspiciously similar, even the routing instructions use the same language. I hope they paid you for your work. But I suspect they didn’t. So this is just a kudos for your innovation and foresight to fill the need years before rocket genius got around to it. A belated thank you.
Yes, I think my plugin might have inspired the new functionality in Gravity Forms. My plugin is not in the directory, it is on https://github.com/soulseekah/Gravity-Forms-Conditional-Notifications though; development has ceased for obvious reasons. Thanks for your support 😉