Short Tag – Web Development Blog

Entries for February, 2010

Connect to your POP3/IMAP mailbox with php and read e-mails

Thanks to PHP’s library this is a very easy thing to do.  We will use the imap_ functions (their names start with imap_).  Imap_ functions can also work with POP3 mailboxes (don’t get fooled by their names).
In order to get all your new emails from your mailbox you would use this code:

if (($emailbox = imap_open("{computername:110/pop3}INBOX", [...]

Creating PDF documents from HTML content via PHP

Since PDF is such a very frequently used file type every web developer will face the challenge of developing an application that creates a PDF file.
And this is indeed a challenge. There are a few classes out there for PHP, but you can’t find a perfect one, because every one of them has to render [...]