humanmade / P2-By-Email

For those who like to interact with P2 by email.
13 stars 8 forks source link

Invalid from-address if home is in subdirectory #26

Open petskratt opened 11 years ago

petskratt commented 11 years ago

If site's home URL is like domain.tld/mysite get_domain_email_address generates From:-address as noreply@domain.tld/mysite

Perhaps something like:

... $url = parse_url ( home_url() ); return $mailbox . '@' . $url['host'];

(not submitting it as a pull as I understand from open issues you have some plans with supporting multisite by including blog ID somewhere)

danielbachhuber commented 11 years ago

Thanks for the report, @petskratt. The solution you've proposed seems like a reasonable fix. I think the blog ID is an independent issue. Up for submitting a pull request?

petskratt commented 11 years ago

mmmm... won't it break reply-by-email in some cases? haven't looked into your code on that side, but it seemed like these parts need to be in sync, at least when considering multisite (what I'm currently using P2-by-Email for)

ALSO - for incoming mail & catch-all address that is possibly needed for multisite: have you considered using Mandrill inbound API instead on pulling a mailbox over pop/imap?

danielbachhuber commented 11 years ago

I don't think it will break reply by email, as that uses the Reply-To header and the Gmail address (if you have that set up).

Mandrill would make for a nice alternative integration.

On Thu, Aug 29, 2013 at 12:31 PM, Peeter Marvet notifications@github.com wrote:

mmmm... won't it break reply-by-email in some cases? haven't looked into your code on that side, but it seemed like these parts need to be in sync, at least when considering multisite (what I'm currently using P2-by-Email for)

ALSO - for incoming mail & catch-all address that is possibly needed for multisite: have you considered using Mandrill inbound API instead on pulling a mailbox over pop/imap?

Reply to this email directly or view it on GitHub: https://github.com/humanmade/P2-By-Email/issues/26#issuecomment-23517042