I was wondering if anyone knows how to put an image into the E-mail Autoresponder?
HTML formatted autoresponder (e.g. to add images) (Pro)
(3 posts) (2 voices)-
Posted 1 year ago #
-
Adding an image to your autoresponder would require that the email was sent in HTML format. Neither simpleContact Lite nor Pro include support for this by default, but by using the hack below you can add this capability.
Please note: This hack relies on some of the code in Pro that enables HTML snippets to be added to your contact form. For that reason this hack is Pro-only.
------------------------------------------
Open sc_admin/response.php
Change line 17 to read:
$responder_message = sql_quote($_POST['responder_message'],1);Change line 19 to read:
$list_responder_message = sql_quote($_POST['list_responder_message'],1);------------------------------------------
Open sc_admin/include/common.php
Duplicate the sendMessage function at the bottom of the script. Call this second function sendhtmlMessage. By making a duplicate function we prevent conflicts with other scripts in Pro.
Find the line in sendhtmlMessage that says...
$mail->Host = $smtp_host;... add this line after it ...
$mail->isHTML(true);------------------------------------------
Open sc_admin/include/contact.php
Change line 295 to read (all the code below on one line):
sendhtmlMessage($email,$responder_email,$responder_name,
$responder_replyto,$responder_subject,$responder_message);------------------------------------------
You should now be able to add an HTML formatted message to your autoresponder message in sc_admin. You could for example write:
<p>Hi [name_first],</p>
<p><strong>Thank you</strong> for your interest.</p>
<p>We will respond to your enquiry as soon as possible.</p>
<p>Kind regards,<br />Your Company Ltd</p>
<img src="http://www.yourwebsite.com/signature.jpg" />
<a href="http://www.yourwebsite.com">Your Company Ltd</a>A word of caution: There are a multitude of desktop email clients and webmail services, whose ability to display HTML formatted messages ranges from excellent (e.g. Apple Mail, Mozilla Thunderbird, Googlemail) to poor (e.g. Lotus Notes, Microsoft Outlook 2007). If you plan to do any complex layout in your email, I recommend that you test it with Litmus.
Posted 1 year ago # -
Thank you very much.
Everything worked great.
Posted 1 year ago #
Reply
You must log in to post.