Is it posible to set one of these up?
So when a form is submitted they get an email sent back immediately? And if so, can it be customized so that from a certain selection within a field different emails can be auto-sent?
Sure, use this line of code at the onsubmit box to get an email sent :
<?php
mosMail($from, $fromname, $recipient, $subject, $html_message, true,$ccemails, $bccemails, $attachments, $replyto_email, $replyto_name );
?>
now config all values to your needs🙂
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Could you please explain what each value is?
Also, can the email that is sent be one I've customized in html?
My form is for clients enquiring about airfares, we have two areas 'Australia' and 'New Zealand' that we wish to have an auto response email sent back to them. We were hoping to use just the one form and if they selected Australia then the Australia auto response email would be sent, same applies with New Zealand.
Sounds like it might be better to setup separate forms for each of these?
And where would I insert the email?
Also, if I had them select which region they are from could I have the form results emailed to a different email for each region?
I want 2 regions going to 1 email address and the rest going to another email address.
Thanks for this, but I only receive emails in my admin mailbox. The sender doesn't receive anything. What have I to change so that sender will receive an autoreply.
For example
admin = [email]admin@mysite.com[/email]
sender = [email]name@sender.com[/email]
Hi weeteringh,
If you want to send the 'same' email to the sender than you can add the 'sender' field name in the Special Fields tab.
If you want to sent two different emails this isn't supported by ChronoForms 'out of the box' but you can do it by using a little php to construct your thank-you email in the 'OnSubmit after email' field. You'll find several recent examples in the forums here.
Bob
Thanks for your reply
I've had a look (few hours) in all kind of forms but cannot find my solution.
What I want is that sender receives an autoreply with a short message, followed by all data that he/she has subscribed.
I've used your test_form
and put this code in 'after submit':
<?php
$from = $replyto_email ="info@myaccount.com";
$fromname = $replyto_name = "myaccount";
$recipient = $_POST['email'];
$subject = "email from myaccount";
$html_message = "<p>We have receveived your subscription with the following data:</p>";
$name = $_POST['name'];
$email = $_POST['email'];
mosMail($from, $fromname, $recipient, $subject, $html_message, true, $email, $name, $ccemails, $bccemails, $attachments, $replyto_email, $replyto_name );
?>
This scripts results in an email with ALL subscribed data to de the mailbox of owner ([email]info@myaccount.com[/email])
but.............
sender/subscriber receives an email (yes, this works), but only with the message:
We have receveived your subscription with the following data:</
My question: How should I change the script above sho that sender/subscriber also receives his/her other data (name and email in this case).
Thanks again for your help and advice.
Hi weeteringh,
I understand, we will edit 2 lines of the code so they are like this :
echo "name = ".$_POST['name'];
echo "email = ".$_POST['email'];
and that will do it!!🙂
Cheers
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
No Sorry. Same (wrong) result.
You are sure that the html_message string is OK?
Weeteringh<br><br>Post edited by: weeteringh, at: 2007/12/28 11:33
Oooh, sorry, I thought this to go at the template field, it should be like this :
$html_message = "<p>We have receveived your subscription with the following data:</p>";
$html_message .= "name = ".$_POST['name'];
$html_message .= "email = ".$_POST['email'];
Cheers
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Almost Max!
This is the result now (I've uses 'MAX' as name and [email]max@myaccount.com[/email] as email address)
We have receveived your subscription with the following data:
name = MAXemail = [email]max@myaccount.nl[/email]
Final question: How can I get email = on a new line
(<br /> and /n won't work)
Rgrds
Weeteringh
Dear all,
I've found the solution (in another forum):
$html_message = "<p>We have receveived your subscription with the following data:</p>";
$html_message .= "name = ".$_POST['name'].'<br />';
$html_message .= "email = ".$_POST['email'].'<br />';
So: '<br />' at the end of each value.
Thanks anyway!
Happy Seasons's greetings from Holland,
Weeteringh
Post edited by: weeteringh, at: 2007/12/28 19:26<br><br>Post edited by: weeteringh, at: 2007/12/28 19:27
Hi weetering,
Yes, you can use '<br />' tags like this or put <p> </p> tags around the entries to make separate paragraphs. Just the same as normal html.
Bob
Hi,
At one point I wa able to use the forums to figure out how to get an auto response email to be sent to the $recepient, but for some reason after upgrading from one older version of CF to newer version is stopped working. After spending nearly 20 hours messing with, yes no joke, it's true my wife is ready to kill me and NO successful fix, so see below and hopefully y'all can help.
So, this is the basic code I have in the On Submit code - after sending email:
------------------------------------------------------------------------------------------------------------------------
<?php
$recipient = $_POST['eMail'];
$subject = "CCVC -Season Survey THANK YOU";
$html_message = "<p> ",</p>;
<p>Thank you for completing the Season Survey.</p>
<p></p>
<p>We look forward to seeing you again in the next season. Stay tuned to the website for the latest and most up-to-date information.</p>
<p></p>
<p>Sincerely,</p>
<br>Capital City Volleyball Club</br>
<br>www.myccvc.com</br>
<br>myccvc@yahoo.com</br>
</p>";
mosMail($from, $fromname, $recipient, $subject, $html_message, true );
?>
------------------------------------------------------------------------------------------------------------------------
I get no email send to the $recipent, but with debug ON I got this error:
------------------------------------------------------------------------------------------------------------------------
_POST: Array ( [eMail] => [email]mike_malloy@cree.com[/email] [Comments] => bpllkepkl )
Case 1: Use table layout
E-mail: 'Yes' custom
Email sent
E-mail message
From: CCVC Season Survey [myccvc.website@yahoo.com]
To: [email]mike_malloy@cree.com[/email]
Subject: CCVC Season Survey -RESPONSE SUBMITTED
eMail [email]mike_malloy@cree.com[/email]
Comments bpllkepkl
Submitted by 24.136.241.129
Parse error: parse error, unexpected ',' in /home/content/c/c/v/ccvchosting/html/components/com_chronocontact/chronocontact.php(537) : eval()'d code on line 4
------------------------------------------------------------------------------------------------------------------------
HELP???
Thanks,
Mike
[email]malloy0@msn.com[/email]