I wanted to create (or at least learn/know how it is done) application(or configuration?) that does similar to what craigslist does when people choose to hide their email with the "anonymous" option when making posts. I suspect that it is done with what's called email relaying. I'd like to find out how it is done in process - from when user enter their email to receiving an email via an anonymous email address. I come from a "LAMP" background at an intermediate level so please bear with me and kindly explain.
Your responses/comments/suggestions/pointers are greatly appreciated.
Thank you
The easiest way to do this is to receive email with your php app. There are a wide range of ways to do this, collecting using cron, piping from an email server directly into your app or using a third party like CloudMailin.
I wrote a blog post explaining some of the methods you can use to receive incoming email using php here. The post discusses rails but the principals are the same for most languages and frameworks.
Related
I'm trying to create a custom webmail, for one of our products, that has thousand of users.
We would like to create the webmail by our own, and let the user sends it by his/hers personal email (One that they already have, and is created)
I know that HubSpot CRM has something like that, but i don't know what i should be aware of, or how i can do it.
I know there I's a lot with spam, reputation etc, but i need some guidance. Can anyone help me out?
It could be awesome to do it with SendGrid integrated.
Kind regards
You may start using a open source webmail client like Roundcube or Rainloop. You can customize the client and use any third party MTA, or just use your current MTA in your own server.
If you want something more advanced, you could pipe all emails from a domain to your custom application and handle everything internally.
Hello I have a registration form, that carries fields such as name, phone number and email. These details are sent to a database, I am trying to implement a system whereby after registration, an SMS is sent to the user who filled the form as a form of confirmation, instead of emails, I know I need a provider to do this, but from the region where I come from i haven't seen a reliable company that can do this, so I am asking for the best suggestions, I am building with PHP programming language.
We do a similar thing. We personally use TextMagic but most proviers are the similar. You are generally given a few options, the most common being an email proxy or a web page call. For instance, to send messages we use:
mail('07123456789#textmagic.com', 'SECRET_CODE', 'Our message');
Here, there mobile number before the #textmagic.com is the number we're sending to, the SECRET_CODE is our pass key and Our message whatever we want to send.
The web version would be similar, something like:
https://www.textmagic.com/app/api?username=xxxx&password=yyyy& cmd=send&text=Our%20message&phone=447123456789
Really what you want to do is find a service like this then check the API documentation. It's a very simple thing to do, but your question is a little too general to give anything more specific.
Im building an email management software using PHP. Im a bit stuck on something, and thought SO might provide some insight. The user retrieves messages. Messages get replied. I was thinking that I could create some sort of custom hash for an incoming message, store the data and hash in the database, and then for replies, inject the custom hash into the message header to denote that this message being sent is apart of that particular incoming message.
After I reply to a message, and then the user re-replies, will the injected custom hash be in the message? If not, it would be treated as a new incoming message.
Should I be looking into injecting custom hashes into messages? Is that even possible? Is it a good method?
Is this a good theory to use? Any suggestions or comments? I really have no experience in this and Im just trying to figure out the best method for implementation.
** NOTE: If there are any open-source PHP email management software that I could reverse-engineer, that would also be something I would be interested in looking at.
Injecting custom headers into the message is possible but it's pretty rare that they would be included in the reply. Sometimes, clients will include a In-Reply-To header, that quotes the original message id and you can use that.
However, the easiest and most common method of doing this is by using a customised from address. If you send the email from message-12345#yourdomain.com then any bounces or replies will come back to that email address. If the next message uses message-12346#yourdomain.com then you can easily tell which reply is for which original message.
There are a few options when receiving the emails:
Poll using POP3 or IMAP
Have the mail server init a script as messages are received
Use a system that converts the emails from SMTP and forwards them as HTTP
I wrote a blog post outlining the methods to receive the messages, it was for Ruby but the same principals all apply. Unfortunately I don't know of any PHP software for this.
Like Wordpress and Blogger have. For example, I send an email to something_blog_post#myblog.com and the email that I sent would be transformed in a post on my blog.
There are services like mailgun that make this fairly easy to do since they convert inbound email into API calls.
The alternative is to find a way to poll IMAP with PHP, then parse the messages. This is probably a whole lot harder.
There are several solutions to this problem:
Firstly, you can setup a system to poll an existing IMAP or POP3 system and return the result.
You can setup an email server which will call a script itself upon receiving an email.
You can use a third party provider (such as CloudMailin or MailGun).
I wrote a blog post a little while back outlining some of these options for Rails applications but they all apply directly to PHP too.
Does anyone know where and or how I can build a PHP Script for a Newsletter that would allow the end-user to Forward their received E-Mail to a friend or so?
Basically, allowing them to take the entire body and subject of the e-mail and open up a new E-Mail Draft which would allow them to enter in the contacts they want to forward the e-mail to?
I am fully aware that this function is available in most, if not all, e-mail clients to this day. But it is requested that this functionality be added within the newsletter.
Any guidance? Any concepts? Any feedback would be greatly appreciated.
Thank you!
If I understand you correctly, you'd need to do the following:
in your email create a "Forward to friend" link that directs the user to a php page on a remote server.
On the remote page, create a script that would contain a form asking for the email address of the friends to email.
Use the mail() function (Or 3rd party class) to mail the users
EDIT:
You can take it another step further by using one of Google's API's to automatically grab email addresses from the users account (Like LinkedIn etc.)
Have a look at ZF's Mail class, which allows to fetch emails using POP3 or IMAP and finally decompose emails into parts.
The ZF documentation page provides extensive sample code.
Add link to email which directs user to a web page that contains
<form action="sendmails.php">
<input name="sendto" type="text"/>
...
and send more letters from there..