Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8982829
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T20:40:38+00:00 2026-06-15T20:40:38+00:00

I have an inbox with 5000+ emails saying that somebody has signed up. Within

  • 0

I have an inbox with 5000+ emails saying that somebody has signed up. Within the body of the email is their email address and name which I want to store in a database.

Q) How can I get this into a database? Ideally mysql.

Ideally I would like to do this in a PHP which I am most familiar with.

I am using iRedMail with: OpenLDAP

UPDATE: since posting the question I have already written the actual email parser using Plan Cake Email Parser, literally took 5 mins once I found this.

UPDATE 2:
To make things easier I have moved all of the emails I want in the database into a separate IMAP folder.

But when I do a search it returns nothing: find /var/vmail -name ‘Subscribers’ -type d –

UPDATE 3:
Another alternative is that I already have the emails downloaded in my email client locally using Thunderbird Windows 7. When I check my Profiles I can see 3 files related to:

  1. Subscribers.msf
  2. Subscribers-1
  3. Subscribers-1.msf
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T20:40:39+00:00Added an answer on June 15, 2026 at 8:40 pm

    The real tricky part isn’t parsing the emails, but getting the emails from your server. There are three ways I can think of doing this:

    1. Use php’s imap library http://php.net/manual/en/book.imap.php. I personally haven’t worked with it very much but since you’re just fetching all emails, it might be useful. The downside is that you’ll end up fetching all of your other mails as well.
    2. Use a 3rd-party service to handle the imap and expose your email via a simpler REST interface. Ideally you’d want to search for a key term (maybe “user signed up”) and then parse it.
    3. Use offlineimap to download all the emails as a Maildir and store it localy. Now you can use PHP to search all the emails and it’ll be faster and easier to test the version here.

    As for parsing, I personally recommend using grep to find the mails that contain the information you want to extract, and awk to convert this information into a CSV file. You can do text processing using PHP but it’s far simpler and cleaner to do it with these tooks.

    You can now easily push the data into MySQL.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have written/copied a script that reads emails from an inbox and updates a
I have a webservice that should return the top 5 emails in my inbox
I have a mail reading service that reads every email from an inbox, parses
I have a bot that is scanning my inbox periodically for specific emails. Whenever
I have created an inbox system. Signed in user can message other signed in
I have a program which reads Inbox messages from email accounts, as the title
i have developed a web servcies in my local system with name (inbox service).
I have tons of email in my inbox (mostly spam), I have a php
I have a requirement of reading subject, sender address and message body of new
I want to show how many unread emails I have in my inbox (gmail)

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.