Fileupload element - include files in only 1 email plugin message

boyjah

Member
We have a form that uses the Fileupload element. Under the "Options"tab there is the item "Email files" with a Yes or No option. If we choose Yes, then the uploaded files are included in all emails that we generate with the Email plugin for that form.

Is there a way to include the uploaded files only in one of the emails but not the other? Once our form is submitted we want to send a confirmation email to the user that their data has been received and we want to send an email to the Admins that includes all data from the form, including the uploaded files. But nder the "Options"tab the item "Email files" seems to be an all or nothing choice?
 
See also your other thread.
https://fabrikar.com/forums/index.p...ent-email-files-vs-show-image-in-email.53202/

You can include whatever you want to show in the email body via element placeholder (email plugin or receipt plugin).
I didn't test wether the receipt plugin will show filename or image (I assume filename, you can add HTML to show the image).

If you have set up PDF in Fabrik I think the easiest way to send the form to Admins is to enable "Attach as PDF" in the email plugin [Attachments]
 
See also your other thread.
https://fabrikar.com/forums/index.p...ent-email-files-vs-show-image-in-email.53202/

You can include whatever you want to show in the email body via element placeholder (email plugin or receipt plugin).
I didn't test wether the receipt plugin will show filename or image (I assume filename, you can add HTML to show the image).

If you have set up PDF in Fabrik I think the easiest way to send the form to Admins is to enable "Attach as PDF" in the email plugin [Attachments]

Thank you for this good information. I tried "Attach as PDF" but the Japanese text from the form only shows as a series of question marks.

Screen Shot 2022-01-20 at 22.37.56.png
 

Yes, I inserted * {font-family:'dejavu sans'!important}
into
/components/com_fabrik/views/form/tmpl/bootstrap/custom_css.php
and
/components/com_fabrik/views/details/tmpl/bootstrap/custom_css.php

In each of the custom_css.php files I made no changes to the content other than to add the single line of css here:
Screen Shot 2022-01-21 at 16.01.35.png

This does change the fonts on details view and edit view, but the PDF that is sent by email still has the question marks. Is there a different place that I must put * {font-family:'dejavu sans'!important} so that the emailed PDF will display correctly?
 
This does change the fonts on details view and edit view
on details and edit view? or on PDFs generated via the PDF button?

Did you select a PDF template in form [Layout] settings?
This one is used for PDFs via PDF button and for the email PDF attachment. The utf8 CSS must be included there.

The PDF template is a details template and if you want to have a 'nice' PDF you should create a custom template because the PDF libs need some additional CSS.
 
PDF template selected in Form->Layout is bootstrap (but we also tried all other options)
PDF template selected in List->Layout is bootstrap (but we also tried the other option: div)

We do not use the PDF button. We only send PDF files as email PDF attachment

We inserted * {font-family:'dejavu sans'!important}
into
/components/com_fabrik/views/form/tmpl/bootstrap/custom_css.php
and
/components/com_fabrik/views/details/tmpl/bootstrap/custom_css.php

After inserting this CSS, the font does change on details and edit view, but emailed PDF contains question marks.

We don't care about a "nice" PDF, we just want Japanese characters instead of question marks.
 
Last edited:
It seems dejavu doesn't support Japanese characters.
I got it working with some free Japanese ttf font I found and copied to a local folder.
In the details custom_css.php
Code:
 @font-face {
  font-family: 'jap';
  font-style: normal;
  font-weight: normal;
  src: url('/Oshidashi-M-Gothic-TT.ttf') format('truetype');
}
* {font-family:'jap'!important}
So load a Japanese ttf font via @font-face from a local folder or from the web (it's also possible to add it to the domPDF lib but I don't know extactly how to).
 
Last edited:
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top