Willkommen, Gast
Angemeldet bleiben:

THEMA:

Include signature image (not as an attachment) in the admin email (Html code)? 4 Jahre 4 Monate her #224522

  • Autor
  • sakari
  • Offline
  • Junior Breezer
  • Junior Breezer
  • Beiträge: 38
  • Dank erhalten: 0
Hello friends,
have a problem with the signature!
How do I get the signature image (not as attachment) in the admin email (Html code)?
{Signatur: value}
Many thanks for your help.

Best regards :)
Sakari

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Include signature image (not as an attachment) in the admin email (Html code)? 4 Jahre 4 Monate her #224805

  • mihaela
  • Offline
  • Developer
  • Developer
  • Beiträge: 3128
  • Karma: 105
  • Dank erhalten: 416
Hello,

It is not possible to display image while creating custom email in Admin email tab with: {Signatur: value} .

There is a way to include signature in your admin email, but you have to go to Advance options of your form > More options > Submit pieces > End Submit, select Type Custom and paste in something like this:
$this->execPieceByName('ff_InitLib');
$from ='test@gmail.com';
$fromname ="test";
$subject = 'Your Email Subject'; // Change to your preferred Email subject
$recipient = 'youremail'; // Change to your admin Email address

//grab values from fields that you want to pass in Admin email, replace Signatur and name with names of elements in your form
$signature= ff_getSubmit('Signatur');
$name= ff_getSubmit('name');

$attachment=null;
$isHtml = true;

$body =  "
<html><body>
<h1>This is the title of email </h1>

<table>
<tr>
<td>
   <strong>Name:</strong>
</td>
<td>
   $name
</td>
</tr>

<tr>
<td>
   <strong>Signature:</strong>
</td>
<td>
   <img src= 'http://localhost/media/breezingforms/signatures/'.$signature alt='mypicture' width='50' height='60'>
</td>
</tr>
</table>
</body></html>";

$this->sendMail($from, $fromname, $recipient, $subject, $body, $attachment, $isHtml);   
This is an example for a form that has fields named Signatur and name.

Replace what is noted in the coments.
The part of the code that shows the picture is:
<img src= 'http://localhost/media/breezingforms/signatures/'.$signature alt='mypicture' width='50' height='60'>
In that part of code replace localhost with your site domain.

I hope that this will help you.
Let me know if you've managed to set this for your form. If you have more questions, feel free to ask.

Regards,

Mihaela

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Include signature image (not as an attachment) in the admin email (Html code)? 4 Jahre 4 Monate her #224813

  • Autor
  • sakari
  • Offline
  • Junior Breezer
  • Junior Breezer
  • Beiträge: 38
  • Dank erhalten: 0
Hello Michaela,
First of all thank you for your help.
I have set as you have described it and replaced the "localhost" against the web address, but unfortunately the signature is not displayed!

Best regards
Sakari
Anhänge:

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Letzte Änderung: Post by sakari.

Include signature image (not as an attachment) in the admin email (Html code)? 4 Jahre 4 Monate her #224860

  • mihaela
  • Offline
  • Developer
  • Developer
  • Beiträge: 3128
  • Karma: 105
  • Dank erhalten: 416
Hmm, that is strange. As you can see in the picture below it should work.


Please check whether the signatures are saved in /media/breezingforms/signatures folder.

Regards,

Mihaela
Anhänge:

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Include signature image (not as an attachment) in the admin email (Html code)? 4 Jahre 4 Monate her #224876

  • Autor
  • sakari
  • Offline
  • Junior Breezer
  • Junior Breezer
  • Beiträge: 38
  • Dank erhalten: 0
The path is correct, but I see in the folder now two stored signatures, one which generates the form itself and one of the script of you!

From the form: Signatur-4eb648320dda45a60ab93a7ae197f1eb.png
From the script: bfQuickMode9729867-d7d467d99a2977b62f5cf3092eee4b58.png

Is that the problem?


Best regards :)
Sakari

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Letzte Änderung: Post by sakari.

Include signature image (not as an attachment) in the admin email (Html code)? 4 Jahre 4 Monate her #224880

  • mihaela
  • Offline
  • Developer
  • Developer
  • Beiträge: 3128
  • Karma: 105
  • Dank erhalten: 416
The script shouldn't generate new signature. It is only used to display a signature in the email.

Can you replace this line of code:
<img src= 'http://localhost/media/breezingforms/signatures/'.$signature alt='mypicture' width='50' height='60'>
with this one:
<img src= 'http://localhost/media/breezingforms/signatures/Signatur-4eb648320dda45a60ab93a7ae197f1eb.png' alt='mypicture' width='50' height='60'>
Once again, instead of localhost it should be your site's address.
Please, before testing the email, check whether the picture is displayed when you visit that link 'http://localhost/media/breezingforms/signatures/Signatur-4eb648320dda45a60ab93a7ae197f1eb.png .

This will be a test to see whether the image(signature) that you know is there will be displayed in the email. If this will work then it must be some issue with $signature variable not fetching the value correctly.

Regards,

Mihaela

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Moderatoren: ForumSupport
Ladezeit der Seite: 0.112 Sekunden

Angebot

Sommer Special! Alle Mitgliedschaften zum Sonderpreis!

Prio Support, alle Extensions und alle Templates in einem Paket.

Hier geht's zur Bestellung

Crosstec hilft sparen!

Falls Sie neu bei Crosstec sind aber bereits einen Formulargenerator bei einem anderen Hersteller gekauft haben, dann bekommen sie von uns einen Rabatt von 25% auf unsere 1-Jahres und Pro-Mitgliedschaften

Wie Sie an den Rabatt kommen?

Schreiben Sie uns einfach eine kurze Email mit beigelegten Kaufbeleg (z.B. PayPal Quittung) an sales@crosstec.org.

Wir unterstützen die Joomla Community

Crosstec unterstützt weltweit alle offiziellen Joomla! User Groups und Organisatoren von Joomla! Days die bei Joomla.org registriert sind.

Falls das auf dich zutrifft und du eines unserer Produkte brauchst, schreib uns eine kurze Email an info@crosstec.org und du bekommst eine Flatrate-Mitgliedschaft geschenkt!