Hi
I know my version of Joomla & Chrono Component are way out of date but I'm hoping you can help please ...
I have one form called "Order_Form" working fine with the field name 'subject' in the Dynamic Subject text box of the "Setup Emails" tab
The code in the "On Submit code - before sending email:" area for that form is ...
When a customer fils out the form and submits it, it creates an email with the subject line like (for example) ... "Roses-To-Pattaya Order for delivery to Aunyaa on 14/02/2016 - Waiting for Payment"
I copied the form using the "Copy form" button on the main button bar and changed the name of the copy to "Order_Form_For_Valentine". (The above On Submit code contents was copied over automatically, within the copy). The only other change I made to the copy was to change the "Redirect URL:" to point to a different webpage on my website.
The copy form works well except for the Subject line of e-mails created by customers using the copy form - the Subject line is blank.
I would have thought (& I need) the Subject line of e-mails created by customers using the copy form to look the same as when using the original form. Please could you tell me how to do that?
Much appreciating any help
Simon
I know my version of Joomla & Chrono Component are way out of date but I'm hoping you can help please ...
I have one form called "Order_Form" working fine with the field name 'subject' in the Dynamic Subject text box of the "Setup Emails" tab
The code in the "On Submit code - before sending email:" area for that form is ...
<?php
$MyForm =& CFChronoForm::getInstance('Order_Form');
$MyFormEmails =& CFEMails::getInstance($MyForm->formrow->id);
$MyFormEmails->setEmailData(1, 'subject', 'Roses-To-Pattaya Order for delivery to ' . JRequest::getString('text_18') . ' on ' . JRequest::getString('date_35') . ' - Waiting for Payment');
?>
When a customer fils out the form and submits it, it creates an email with the subject line like (for example) ... "Roses-To-Pattaya Order for delivery to Aunyaa on 14/02/2016 - Waiting for Payment"
I copied the form using the "Copy form" button on the main button bar and changed the name of the copy to "Order_Form_For_Valentine". (The above On Submit code contents was copied over automatically, within the copy). The only other change I made to the copy was to change the "Redirect URL:" to point to a different webpage on my website.
The copy form works well except for the Subject line of e-mails created by customers using the copy form - the Subject line is blank.
I would have thought (& I need) the Subject line of e-mails created by customers using the copy form to look the same as when using the original form. Please could you tell me how to do that?
Much appreciating any help
Simon
Hi Simon,
That isn't code that I recognise which makes it a bit hard to debug. There is probably a PHP Error somewhere that is giving you the blank subject. Possibly you need to change the name of the form in the second line?
The more usual way to create a Dynamic Subject in CFv3 would be to add a Dynamic Subject to the Email with subject in it and then add code like this
Bob
That isn't code that I recognise which makes it a bit hard to debug. There is probably a PHP Error somewhere that is giving you the blank subject. Possibly you need to change the name of the form in the second line?
The more usual way to create a Dynamic Subject in CFv3 would be to add a Dynamic Subject to the Email with subject in it and then add code like this
<?php
$subject = 'Roses-To-Pattaya Order for delivery to ' . JRequest::getString('text_18', '') . ' on ' . JRequest::getString('date_35', '') . ' - Waiting for Payment';
JRequest::setVar('subject', $subject);
?>
Bob
Hi Bob
Yes, Fixed !! I changed the name of the form in the second line to Order_Form_For_Valentine and the subject line now gets added to e-mails (orders) correctly.
(I should have realised myself that it would need to match the name of the copy form !)
Strange about the unrecognisable code. I cannot remember where I got it from. I assumed it came with the software but obviously not.
Many thanks, Bob!
Simon
Yes, Fixed !! I changed the name of the form in the second line to Order_Form_For_Valentine and the subject line now gets added to e-mails (orders) correctly.
(I should have realised myself that it would need to match the name of the copy form !)
Strange about the unrecognisable code. I cannot remember where I got it from. I assumed it came with the software but obviously not.
Many thanks, Bob!
Simon
Hi All,
I have a problem in uploading file in multipage form. I'm having a 3 page form with file upload on page2. Debugger action gives list of all fields except file type. Also server has no image uploaded neither in my db table.
Please help me ASAP. I've already delayed my deadline😟
I have a problem in uploading file in multipage form. I'm having a 3 page form with file upload on page2. Debugger action gives list of all fields except file type. Also server has no image uploaded neither in my db table.
Please help me ASAP. I've already delayed my deadline😟
This topic is locked and no more replies can be posted.
