help with custom email template

  • dama
  • Topic Author
  • Offline
  • Senior Boarder
  • Senior Boarder
  • Posts: 45
  • Thank you received: 1

dama replied the topic: help with custom email template

Hello

It didn't help. It seems $NL is not working for me. I forgot to tell y0u that earlier that even second part of code
<?php echo $DATA[_FF_DATA_TITLE]?>: <?php echo $DATA[_FF_DATA_VALUE]?><?php echo $NL; ?>
<?php endif; ?>
<?php endforeach; ?>
wasn't producing anew line so I had to wrap it in <div> and now I have it working like this:
<div>Dear 
<?php foreach ($MAILDATA as $DATA): ?>
<?php if($DATA[_FF_DATA_NAME] == "name"): ?>
		<?php echo $DATA[_FF_DATA_VALUE] .",". $NL; ?></div>
<div>Thank you for contacting...</div>
<div style="margin:15px 0;">Here is the summary of your request:</div>
<?php else: ?>
<div style="line-height:2;"><?php echo $DATA[_FF_DATA_TITLE]?>: <strong><?php echo $DATA[_FF_DATA_VALUE]?></strong><?php echo $NL ?></div>
<?php endif; ?>
<?php endforeach; ?>

Do you still want me to send you the template file?

Regards
#236603
  • Posts: 2461
  • Karma: 86
  • Thank you received: 333

mihaela replied the topic: help with custom email template

Hello again,

Based on what you wrote I assume that you have named the file FORMNAME.html.php and therefore HTML template is expected.

The code I've provided is suitable for a non HTML file so the name should be FORMNAME.txt.php. Therefore, if you just change the file extension problem should be solved. In that case, the <div> won't be needed.

If you prefer to have a HTML file, you can leave it with the div-s as it is.

I hope this helps.

Best regards,

Mihaela
#236612
  • dama
  • Topic Author
  • Offline
  • Senior Boarder
  • Senior Boarder
  • Posts: 45
  • Thank you received: 1

dama replied the topic: help with custom email template

Hello

Yes, I prefer HTML template because I added some additional code at the bottom.
Now it is working as I intended. Thank you for the help.

Kind regards
#236617
  • Posts: 2461
  • Karma: 86
  • Thank you received: 333

mihaela replied the topic: help with custom email template

Ok then,

I'm glad that this is now working as you wanted. :)

Best regards,

Mihaela
#236618
Moderators: ForumSupporttomeperica
Time to create page: 0.067 seconds

New Icon Packs Category!

Crosstec is now offering icon packs.

If you are a paying subscriber, icon packs are automatically added to your account.

Check out our icon packs page!

Live Support Chat Opened!

Join our Discord chat here to receive live support and talk directly to the team!

Summer Sale!

50% discount on all of our extension subscription plans, templates and icon packs!

Get Your Subscription Here

News and Updates

Get informed about new downloads, updates and more in our News and Updates newsletter.

All Extensions Subscription

Get 1 year access to all of our current and future products and 1 year of professional support -- 99 for just 49! (Summer Sale)

No support per domain or website installation limits! Includes all of our current and future Joomla!® extensions, Joomla!® templates for the duration of your membership. This means, by purchasing an All Extensions Subscription you'll have it all covered!

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!

Live Support Chat Opened!

Join our Discord chat here to receive live support and talk directly to the team!

Community Reward

Help us to create new extensions and plugins! With only $5 you help us a lot and get unlimited download access to all of our products, professional support and even more. Get your reward now!

Read More Here