Home
 

Customer Support

Search for keywords:

Browse by category:

Can I pipe email to a program?

We do not currently allow "piping" of email on the shared system for security reasons. However, there are other options for processing your mail with your own programs.

First, you should take a look at the Sieve filtering language. It's quite powerful, and while we do not currently offer a web interface, we will work with you to install a Sieve script.

You might also want to deploy a Perl or PHP script on a regular schedule that examines your mailbox and manipulates your email in any way you desire, such as adding messages to a MySQL database, forwarding them, deleting them (though Sieve would be a better choice for deleting), or nearly anything else.

User-Contributed Notes

add a note
27-Jul-2004 11:39
Here is a simple example of a Perl script which prints out the subject 
line of any unseen mail in your inbox (marking them as seen in the
process):


     #!/usr/bin/perl

     use Net::IMAP::Simple;

     # open a connection to the IMAP server
     $server = new Net::IMAP::Simple( 'mail.modwest.com' );

     # login
     $server->login( 'YOURUSERNAME', 'YOURPASSWORD' );

     # select the desired folder
     $number_of_messages = $server->select( 'inbox' );

     # go through all the messages in the selected folder
     foreach $msg ( 1..$number_of_messages )
     {
       if (! $server->seen( $msg ) )
       {
         $fh = $server->getfh( $msg );
         while( <fh> )
         {
           $line = $_;

           if($line =~ /Subject:/)
           {
             print $line;
           }
         }
         close $fh;
       }

     }


22-Nov-2007 09:13
Hi,

I have recently had the same task to solve and found that one can have a
workaround by using www.email2php.com. 

add a note

Related Questions:


Sending email takes a long time and then fails.

I get "relaying denied" when trying to send email from my computer.

My ISP does not give me an SMTP/Outgoing mailserver to send mail from my own computer, so I must use yours.

How do I send email?

Do you have screenshots of Outlook Express configurations?

How do I receive and read e-mail?

Occasionally, Outlook Express just asks for my username and password but will not let me get my mail.

Someone is sending viruses or spam that appears to come "from" an address at my domain.

Why can't I send or receive email with large attachments?

Do you have screenshots of Entourage 2004 configurations?

I can't get my email because I am continually asked to retype my mailbox password, or am getting a [LOGIN-DELAY] error.

Do you support Secure POP and IMAP?

Can I have a special MX record so a different mailserver like everyone.net or my own Exchange server will handle all mail for my domain?

Why am I getting spam?

Is there a way I can bounce all email addressed to unknown users?

How do I delete hundreds or thousands of emails easily?

How many email addresses can I have and how do aliases work?

How do I protect email that contains sensitive information?

Can I have an automatic reply sent to people who email me while I'm on vacation?

I cannot get into webmail.

Which e-mail protocol should I use, POP or IMAP?

How does the mail server filter spam and viruses?

How Do I Backup My Email?

Why won't my email attachment go through?

I receive too much SPAM: what can I do?

My website forms are spamming me with 'gibberish@mydomain.com' or Form Email Injection Attack

Do you scan email for viruses?

Can I do mass emailings through my ISP that advertises my website?

When I "Add Mailbox" in Onsite, it says "That login name is already taken. Please choose another."

Why are HTML emails a security hazard?

How do I view full email headers?

I get this error when logging into Webmail: Security failure, data decryption error

How do I import addresses into webmail?

How do I forward e-mail in OnSite?

Do you support anti-forgery standards (SPF / DomainKeys) for email?

I'm having trouble with email.

Do you purge messages from Trash and Spam folders?

Why can't I forward @mydomain.com email to my ISP mailbox?

Why is/isn't an email being marked as spam?

Why can't I delete messages from my mailbox if it is over quota?

Can I have an email address which both stores and forwards mail?

How can I access my Modwest mail from another provider's webmail?

What does the "Flag Subject" radio button do in OnSite spam settings?

Why is webmail seem slow?

When I send from Modwest webmail, my email has the wrong 'sender' or 'reply-to' address

Toggling 'Default Email Composition Format' to 'HTML' inside Modwest webmail only works temporarily

My Interspire Shopping Cart isn't Emailing Order Confirmations

Why can't I sort my messages in Webmail?

I use Modwest webmail. Is there a way to attach an image to my signature block?

Browse Categories:

Getting Started, FTP, Telnet/SSH, Moving Domains, E-mail, Traffic Reports, Mailing Lists, Apache, PHP, CGI, Other Server-Side Scripting, MySQL Database, Imaging Libraries, Other Software, Billing & Terms, Control Panel, E-commerce, Pre-Sales


Modwest PHP Hosting      Copyright 2000-2009 by Modwest, Inc.      About    |    Blog    |    Community    |    Design    |    Jobs    |    Contact