email-headers

accented words in email subject break spacing - how do I stop this?

白昼怎懂夜的黑 提交于 2019-12-07 02:33:45
问题 We have a custom php email marketing app, and an interesting problem: If the subject line of the message contains a word with accents, it 'swallows' the spaces between it and the following word. An example: the phrase Ángel Ríos escucha y sorprende is shown (by at least gmail and lotus notes) as ÁngelRíos escucha y sorprende The particular line in the message source shows: Subject: =?ISO-8859-1?Q?=C1ngel?= =?ISO-8859-1?Q?R=EDos?= escucha y sorprende (semi-full headers): Delivered-To: me@gmail

RegEx to match time in “Received: by” e-mail header

雨燕双飞 提交于 2019-12-06 20:06:22
On the shared-host where my website is, I have an e-mail forwarder that sends messages to my phone as a text message. Recently, however, it's been getting a bit out of hand. I am hoping that, using the "User Level Filtering" in cPanel, I can setup a RegEx-based filter to only forward e-mails to my phone between the hours of 07:00:00 and 22:00:00. This filter would match the following e-mail header, which typically occurs 2-3 lines into the message source: Received: by 99.99.99.99 with SMTP id XyXyXyXyXyXyXy; Tue, 15 May 2012 01:22:33 ... and this is how I am hoping it'd work: Received: by (ANY

Method for parsing text Cc field of email header?

天涯浪子 提交于 2019-12-06 02:52:16
问题 I have the plain text of a Cc header field that looks like so: friend@email.com, John Smith <john.smith@email.com>,"Smith, Jane" <jane.smith@uconn.edu> Are there any battle tested modules for parsing this properly? (bonus if it's in python! the email module just returns the raw text without any methods for splitting it, AFAIK) (also bonus if it splits name and address into to fields) 回答1: There are a bunch of function available as a standard python module, but I think you're looking for email

Content-Type with charset only

点点圈 提交于 2019-12-05 22:24:47
I came across this interesting header: Content-Type: charset=utf-8 Set HTTP header to UTF-8 using PHP The answerer says that this syntax is defined by RFC 2616 , but I am not seeing it in the provided link. Is this valid syntax, and if so where specifically is this defined? The production in RFC 2616 for the Content-Type header is this: Content-Type = "Content-Type" ":" media-type And the media-type production is this: media-type = type "/" subtype *( ";" parameter ) type = token subtype = token That says that while the parameter part (e.g., charset=utf-8 is optional, the type "/" subtype part

How can the Return-Path header be different than the actual email bounce recipient?

删除回忆录丶 提交于 2019-12-05 01:53:52
I recently moved my transactional email sending to Mailgun It works good so far however I am wondering about the return-path header. Consider this email (I removed irrelevant header and replaced email/domain for privacy purposes) Delivered-To: RECIEVER@gmail.com Received: by 10.76.154.104 with SMTP id vn8csp478308oab; Wed, 4 Sep 2013 05:04:44 -0700 (PDT) X-Received: by 10.50.22.105 with SMTP id c9mr1537992igf.36.1378296283817; Wed, 04 Sep 2013 05:04:43 -0700 (PDT) Return-Path: <bounce+a801a1.c2b37-RECIEVER=gmail.com@my-website.com> Received: from so254-63.mailgun.net (so254-63.mailgun.net.

Customizing email headers in WooCommerce email notifications

北城以北 提交于 2019-12-04 20:08:32
I am trying to write a filter that changes the reply-to address for WooCommerce email, dependent on the 'billing city' the order is made for. This works for WooCommerce emails, but doesn't seem to work for WooCommerce Advanced notifications - it doesn't seem to pass the '$order' into the header information to do the IF statement. It is a long shot but any thoughts much appreciated. This is my code. function change_headers($order, $object, $headers); // Get the city $city = $order->get_billing_city(); // Change Headers if ($city == 'Manchester') { $headers = array(); $headers[] = 'Reply-to:

custom email header

两盒软妹~` 提交于 2019-12-04 19:27:55
i want to add a enquiry id number to my emails so that when a user replies i i can automatically attach the email to an enquiry. I am going to put a message with please do not remove this enquiry number when replying but it would be good if i can put a custom header with the enquiry number so the user doesnt see it. Is this possible and is there any spam isssues addingh a custom header ? best regards rick Easy to do, just use the headers method from your ActionMailer subclass Per the email spec, start your non-standard headers with an X- Eg X-enquiry-num, not enquiry-num Also, don't count on

How do i specify X-Headers for outgoing emails in Microsoft Outlook 2010

折月煮酒 提交于 2019-12-04 18:44:22
I need to include custom headers in my outgoing emails. I'm using Microsoft Outlook 2010 and SendGrid SMTP server. In particular, i want to specify a unique tracking ID on each mail using SendGrid's X-SMTPAPI header. My Approach: I am build an Outlook Add-In that will intercept outgoing emails and add the required headers Outlook.Application object has an ItemSend event that serves this purpose. How do i use Mail.PropertyAccessor.SetProperty to set the custom headers? I am unable to find the correct header identifier that points to x-headers, or that will allow me set custom headers. Your help

How to stop HTTP (and rfc822, email) header injection?

杀马特。学长 韩版系。学妹 提交于 2019-12-04 18:23:04
(I am asking this question (and answering it), to make accessible some (hopefully useful) information, since I could not find this readily using search engines. However, feel free to answer it and add useful information :-).) How can HTTP headers be escaped/quoted in Python? And/Or how can they be validated to make sure they do not contain any context-escaping values? In other words, how can we do for HTTP headers, what cgi.escape and urllib.quote methods (and sanitizing) do for HTML and URLs? This can be used to guard against HTTP header injection and similar exploits. For example... We have

Correct headers for replying and forwarding emails

◇◆丶佛笑我妖孽 提交于 2019-12-04 17:59:39
问题 Are you that programmer that knows all about emails? Can you dream about mail headers, write them with your eyes closed? Maybe you might be able to help me with this issue. Let me explain ... Workflow The mail server receives emails A PHP cronjob imports all emails from IMAP into the MySQL database The user finds all emails in the Inbox in my application Sending an email In that same application a user can send new emails. I've handled that using the following code snippet. $message = \Swift