I’m using formit for a contact form that has a dropdown for topics. Based on the selected topic, the data will be send to a specific email address. The site admin must be able to manage the topics and emails, so I created a migx tv to store the topic-email pairs.
I’m displaying the topics in the form with getImageList, and they show correctly, but the email isn’t send, even though I get a success message. If I replace the getImageList call with hard coded options, the email gets through.
Here is my code:
<select name="subject" class="form-control">
<option value="" disabled="" selected=""> [[%contact.form.topic.select? &namespace=`language` &topic=`default`]]</option>
and in the tpl I used both:
With the same outcome, the email isn’t sent.
Any ideas why this happens?
Can you share your formit call so we can try to help you?
You forgot the value here.
<option [[!+fi.subject:FormItIsSelected=`[[+topic]]`]] value="[[+topic]]">[[+topic]]</option>
Thank you for your replies.
@jnogueira This is my formit call:
&emailSubject=`MFA - Contact form`
&successMessage=`<div class="alert alert-success container">
<button type="button" class="close" data-dismiss="alert">×</button>
<h5> [[%contact_form_thanks_message? &topic=`default` &namespace=`language`]]</h5>
@jako yeah, I noticed now, but I only forgot in this post, not in the tpl.
I found the reason the emails were not sent. I removed one of the test emails I was sending to, and after that, everything worked fine. I just don’t understand why was this happening. Any thoughts?