Jump to content

Php to show/send show mails Oo?

Recommended Posts

Hi, this is a quick one.

Is it somehow possible to "show" the mails i GET on my mails on my server/domain?

I know some ppl do this... but never seen any code for this out there Oo?

Asking bcoz i would like to try and insert this into my project portfolio somehow :D

thanks in advanse! :D

Link to post
Share on other sites

Not in an easy way. I'd start by looking for APIs offered by your mail server. Some APIs are through HTTP, but some are through the IMAP protocol.

  • Thanks 1
Link to post
Share on other sites
  • 4 weeks later...

Hi sry for late reply as always.

Actually the API part sounds like a good idea, but in case i cant find any with theese services, where should i look as to how to implement IMAP services? Done this through CPanel b4 but never by php code? Is this not done to server only? Or is it possible to actually use IMAP to do this stuff on something like front-end on a server and to interact like the way i intended? :D

thx in advance :D

Link to post
Share on other sites

I have not worked directly with it, but PHP has the IMAP extension to interact with mail servers. https://www.php.net/imap

This page indicates how to open a connection: https://www.php.net/manual/en/function.imap-open.php

This function returns message IDs for items in the inbox: https://www.php.net/manual/en/function.imap-search.php

fetchbody() and other fetch functions will give you data about an email give its ID: https://www.php.net/manual/en/function.imap-fetchbody.php


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...