TOPIC:

Need Help With Digital Signature 1 year 6 months ago #266339

  • Topic Author
  • louisdadj
  • Offline
  • Junior Member
  • Junior Member
  • Registered
  • Posts: 61
  • Thanks: 1
I need help with a form that uses responsive calendar and digital signature function:

1. When the client receives the email, I don't want the digital signature to be added as a png file. Only the PDF document.

2. I want the calendar to show the date as: Day Month Year (%e.%B.%Y). But when I enter this in the format field, the calendar values aren't saved.

3. Where or how can one adjust the size of the signature that gets embed on the pdf document?

4. What formatting options (CSS etc) are available for the pdf document?

5. Change the name of the pdf that gets emailed to the recipient (ffexport-pdf-20211126143804-1906413614.pdf).


I don't mind paying for support, but I need to know that this can be done.
Attachments:

Please Log in or Create an account to join the conversation.

Need Help With Digital Signature 1 year 6 months ago #266341

  • Mirec's Avatar
  • Mirec
  • Offline
  • Platinum Member
  • Platinum Member
  • Registered
  • Posts: 3262
  • Thanks: 163
Hi,

give me a little time and I will answer your questions as soon as possible!

Update:

1. When the client receives the email, I don't want the digital signature to be added as a png file. Only the PDF document.

I made a mistake please follow Tihana's answer for this step



3. Where or how can one adjust the size of the signature that gets embedded in the pdf document?


Please open the following file :
\joomla\media\breezingforms\pdftpl\pdf_attachment.php

and inside add this :
<?php echo $data[_FF_DATA_TYPE] == 'Signature' && file_exists(JPATH_SITE.'/media/breezingforms/signatures/'.$data[_FF_DATA_VALUE]) ? '<img src="'.JPATH_SITE.'/media/breezingforms/signatures/'.$data[_FF_DATA_VALUE].'" height="120" width="120"/>' : nl2br(htmlentities(substr(is_array($data[_FF_DATA_VALUE]) ? implode('|',$data[_FF_DATA_VALUE]) : $data[_FF_DATA_VALUE],0,10000), ENT_QUOTES, 'UTF-8')); ?>
I added height="120" width="120" but you can set it to what suites you best.



4. What formatting options (CSS etc) are available for the pdf document?

please take a look at this article on how to modify PDF attachments:

crosstec.org/en/support/online-documenta...-s-pdf-template.html


5. Change the name of the pdf that gets emailed to the recipient (ffexport-pdf-20211126143804-1906413614.pdf).


Please see this link below:
crosstec.org/en/forums/1-forums/127659-c...to-field.html#241112



2. I want the calendar to show the date as: Day Month Year (%e.%B.%Y). But when I enter this in the format field, the calendar values aren't saved.


can you try with this format:
dd-mmm-yyyy

Calendar is using Joomla Calendar API:
docs.joomla.org/Calendar_form_field_type

Regards,
Mirko

Please Log in or Create an account to join the conversation.

Last edit: Post by Mirec. Reason: delete first step because of mistake

Need Help With Digital Signature 1 year 6 months ago #266344

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Registered
  • Posts: 12079
  • Thanks: 786
Hi,

1) please go to your :
Joomla/components/com_breezingforms/facileforms.process.php
around line 6140 - 6192 find this code
	$attachToAdminMail = JRequest::getVar('attachToAdminMail', array());
		if (count($this->maildata)) {
			foreach ($this->maildata as $data) {
				if (isset($attachToAdminMail[$data[_FF_DATA_NAME]])) {
					if (isset($data[_FF_DATA_FILE_SERVERPATH])) {
						$testEx = explode("\n", trim($data[_FF_DATA_FILE_SERVERPATH]));
						$cntTestEx = count($testEx);
						if ($cntTestEx > 1) {
							for ($ex = 0; $ex < $cntTestEx; $ex++) {

								if(strpos(strtolower($testEx[$ex]), '{cbsite}') === 0){
									$testEx[$ex] = str_replace(array('{cbsite}','{CBSite}'), array(JPATH_SITE, JPATH_SITE), $testEx[$ex]);
								}

								if(strpos(strtolower($testEx[$ex]), '{site}') === 0){
									$testEx[$ex] = str_replace(array('{site}','{site}'), array(JPATH_SITE, JPATH_SITE), $testEx[$ex]);
								}

								if (!is_array($attachment) && $attachment != '') {
									$attachment = array_merge(array(trim($testEx[$ex])), array($attachment));
								} else if (is_array($attachment)) {
									$attachment = array_merge(array(trim($testEx[$ex])), $attachment);
								} else {
									$attachment = trim($testEx[$ex]);
								}
							}
						} else {

							if(strpos(strtolower(trim($data[_FF_DATA_FILE_SERVERPATH])), '{cbsite}') === 0){
								$data[_FF_DATA_FILE_SERVERPATH] = str_replace(array('{cbsite}','{CBSite}'), array(JPATH_SITE, JPATH_SITE), trim($data[_FF_DATA_FILE_SERVERPATH]));
							}

							if(strpos(strtolower(trim($data[_FF_DATA_FILE_SERVERPATH])), '{site}') === 0){
								$data[_FF_DATA_FILE_SERVERPATH] = str_replace(array('{site}','{site}'), array(JPATH_SITE, JPATH_SITE), trim($data[_FF_DATA_FILE_SERVERPATH]));
							}

							if (!is_array($attachment) && $attachment != '') {
								$attachment = array_merge(array(trim($data[_FF_DATA_FILE_SERVERPATH])), array($attachment));
							} else if (is_array($attachment)) {
								$attachment = array_merge(array(trim($data[_FF_DATA_FILE_SERVERPATH])), $attachment);
							} else {
								$attachment = trim($data[_FF_DATA_FILE_SERVERPATH]);
							}
						}
					}
				}

				if($data[_FF_DATA_TYPE] == 'Signature'){

					$signatures[] = JPATH_SITE . '/media/breezingforms/signatures/' . $data[_FF_DATA_VALUE];
				}
			}
		}
Delete it, or comment

After that you will recevie mail with pdf but there will not be png file

2) (%e.%B.%Y)
Date can't be in this format, only in %d.%m.%Y


Regards,
Tihana

Please Log in or Create an account to join the conversation.

Last edit: Post by tihana.krivic.

Need Help With Digital Signature 1 year 6 months ago #266354

  • Topic Author
  • louisdadj
  • Offline
  • Junior Member
  • Junior Member
  • Registered
  • Posts: 61
  • Thanks: 1
Thank you very much. The png file is no longer delivered to the admin. However, the end-user still receives the png file with the PDF document.

What coding should be removed to ensure that the client also doesn't receive the png file?

Please Log in or Create an account to join the conversation.

Need Help With Digital Signature 1 year 6 months ago #266363

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Registered
  • Posts: 12079
  • Thanks: 786
Hi,

stay in same facileforms.process.php file.

Around line 6632-6635 find this code:
if($DATA[_FF_DATA_TYPE] == 'Signature'){

								$signatures[] = JPATH_SITE . '/media/breezingforms/signatures/' . $DATA[_FF_DATA_VALUE];
							}
Delete or comment it

Let me know if you need anything else

Regards,
Tihana

Please Log in or Create an account to join the conversation.

Need Help With Digital Signature 1 year 6 months ago #266367

  • Topic Author
  • louisdadj
  • Offline
  • Junior Member
  • Junior Member
  • Registered
  • Posts: 61
  • Thanks: 1
There were 4 instances of the coding in the facileforms.process.php file. I commented all of them out.

The png attachment has now been removed from the (mailback) email, but now the mailback doesn't show the signature inside the pdf document.

The admin email does show the signature inside the PDF document, but not the mailback of the sender.

Please Log in or Create an account to join the conversation.

Time to create page: 0.108 seconds

Support Chat

Join our Discord chat and enter the Crosstec channels for live-support, chat forums and interact directly with the community!

After joining, please enter the Crosstec Area and use the #crosstec-support or #crosstec-general channels.

Quick Links

Downloads

BreezingForms

ContentBuilder

BreezingCommerce

Templates

Documentation

BreezingForms

ContentBuilder

BreezingCommerce

Apprendre BreezingForms (French Community)

Apprendre et maîtriser BreezingForms par des tutoriels et exemples, le tout en français

breezingforms.eddy-vh.com

Questions et réponses sur les forums de l'AFUJ

AFUJ

Subscribe to news and updates!

Special Offer

Sale! All subscriptions at a special price!

Includes prio support, all of our current and future Joomla!® extensions and Joomla!® templates for the duration of your membership.

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 and enter the Crosstec channels to receive live support and talk directly to the team!