I have been toying with this idea for few days now.
What I want to do is: I have a powershell script which sends mails mentioning status of some links which I am monitoring.
I wanted to add its functionality. I wanted to add a feature like, when a user sends the mail to a particular email ID with a subject line like "Status", it should send the user, the result of the powershell script.
From my perspective, an IMAP configuration needs to be done in the script. But just wanted opinion if this idea is feasible or not. I have IMAP configured in my organization. I just need to learn how to configure the script with IMAP settings so that the script can send automatic replies after reading the subject line.
IF this is possible from any other technology, then I would like to learn that as well.
EDIT:
Its not a duplicate, because here I want to know pretty basic stuff, like if its possible, and if it is, then what are the technology I need to use to make it possible. Let me know your suggestions.
I saw the duplicate question as well; well it hasn't been properly answered and the links given don't work.
Please help me here.
Thanks in advance!
Related
is there are program or script or anything that will make my email client/webmail to open webpage links from newly received emails automatically?
If someone knows or can make a add-on for thunderbird or make this to work I don't mind paying. Just I need links that are in emails I receive to be automatically opened in default internet browser tabs.
All I can say is I very very much doubt it. If there ever was one created it would most probably be removed by most download source providers as there is a fairly huge security risk there.
Additionally, aside from the security factor you have a simple load factor to account for. I regularly make newsletters for clients, each with a link to a text version, a online version, a link for the logo and so forth... So if you did have such a plugin you would also open these links, which seams crazy. Additionally, remember the Unsubscribe link for emails, on some you are asked to confirm on others you click(/open), your taken off. Which would be very undesired.
I do understand you probably have a reason X for doing this, like because its a in house email system which creates reports and it does this and does that etc. I think most people here do understand there are sometimes very odd usage cases for things, but I don't think anyone will be able to assist you here, sorry!
I assure you this is a programming question: someone asked about this same problem before and was told that this is not a programming question, but that is because he did not phrase it as such. Please read my full description.
The Problem: I just graduated from college and want to transfer all my emails in my college account (henceforth "account O" for old) to a regular gmail account (henceforth N). Note that account O is powered by Gmail, and is effectively a gmail account.
Gmail has a suggested means for doing this: POP/IMAP. But, this did not work for me, and it has failed many others (see here); upon trying to sync by IMAP, my account N is bombarded with messages reading "A message in your account was listed with an invalid size. It has been left on the server."
It would seem natural to try to mass-forward all of one's emails. But google does not allow such an action. Other people say to use a filter, because filtered items can be mass-forwarded. But you can't filter by date, and there is no way to get the filter to select everything.
My workaround, and where I need more experience programmer advice: I want to run a program which signs into my account O and finds the first email I ever received. Then, I want to begin a for loop which runs through all of my emails where the body of the loop does the following: a) click the forward button b) type in my account N email address c) hit "next", so that the 2nd email I ever received shows up, and so on.
This would accomplish my task.
Unfortunately, all I have under my belt is a semester of C++, some knowledge of statistical
scripting languages (ie R), and VBA. I don't know how to make code interact with the internet. Could someone tell me a language and how to do this?
Thanks,
Ryan
While you are correct in saying that the approach you want to take to this problem makes it a programming question, Ben makes a valid point that your question probably does not confirm to site guidelines.
To answer your problem, pretty much any language should be able to handle this, as nearly all have libraries for working with SMTP. However, this is most likely overkill and I would not suggest programming your own solution when other alternatives exist.
If you receive that message when trying to import mail (or add an account) in gmail's web interface, you should try to import them using an actual mail client such as Thunderbird, a procedure for which is described here. If you have already tried that but still encounter errors, you can use GMail Loader to read archive emails from a variety of formats and mass forward them to a gmail address.
Yes it is possible to create a filter that selects everything.
Simply put your email in the "to" field.
If you have other accounts forwarding to O, make a filter for them too (or us the "OR" keyword).
for my group at the university I'd like to set up a server-sided email-to-rss service.
It should work like that, that different people can send emails to a certain address (nothing proprietary like gmail but a certain imap or pop server) which will the be translated into an rss feed. One main and important feature has to be that one can see the sender of the email in the feed. Furthermore it would be nice (to take the load off the server) if the emails get translated to a feed only once a day or so.
Does anyone has some input on this subject? Are there any scripts/services which will allow that?
Thanks a bunch.
Instead of "reinventing the wheel", you could use a mailing list that supports RSS. Your people can then write the mails to the mailing list and you can then use the mailing list's RSS feed however you intend to.
This should help you find a solution: https://encrypted.google.com/search?q=mailing%20list%20rss
Pick a programming language you're familiar with, then use either an imap library to fetch the E-mails (through cron, every hour or something like that), or if you have access to procmail on your mail server, launch your script as an email arrives (this shouldn't be too much work to handle for a server, unless you're talking a vast amount of E-mail).
The script would just insert the E-mails into a database, before extracting them and outputting the RSS-feed directly from that (this shouldn't be more than a handful of lines of code).
There's a couple of providers that does this for you, although it seems that the most popular ones have disappeared. Advanced Email2RSS seems to be an option, although I have no idea how good they are or if it'll even solve your issue.
I fear I've stumbled into unknown Magento territory. I have exhausted what's left of my Googling abilities and have come up short, so I thought I'd try my luck here.
Our platform is Magento Enterprise 1.9.1.1.
We use an archaic print solution that reads orders via ODBC. As such, we can't have it read from Magento's MySQL database directly (thanks to the high likelihood of change). What I've done is extend Mage_Sales_Model_Order to intercept the _beforeSave() function with direct SQL queries to another database, before returning parent::_beforeSave(). There are likely better ways to have done this, but it's done now, and functional, and regardless it is not where my problem lies.
If any SQL errors are thrown, updates are rolled back and the errors & order data are passed to a function that sends an email to a mailing list with the error information. The email template file in /locale/en_US/template/email/ calls on a .phtml file to process the arrays of data like so:
{{block type='core/template' area='frontend' template='/email/errors/order/beforesave.phtml' orderdata=$orderdata errors=$errors}}
This is functionality I borrowed from /locale/en_US/template/email/sales/shipment_new.phtml. And this is also where I hit my roadblock. The email fires fine from the front end, if errors are encountered when the user is processing an order. If you make order changes from adminhtml, the email is sent, but without the above mentioned block.
I have tried with and without area='frontend' in the block call, and the script exhibits the same behaviour regardless.
I think that the problem may be in my XML, though it finds the template itself just fine from both admin and frontend (and this block is not required to be defined in my XML anywhere). I can also not find any examples of this within Magento's own files, or anywhere on the internet.
Any help would be more than greatly appreciated. This is doing my head in!
Mike
Are you setting the "area" for the actual email template? E.g.:
$emailTemplate = Mage::getModel('core/email_template');
$emailTemplate
->setDesignConfig(array('area' => 'frontend', 'store' => $storeId));
Possible duplicate of sharing template between frontend and backend (admin or adminhtml) in magento.
Don't mean to revive a dead question; just tying up the loose end.
#ColinM: My thoughts were the same as yours, but that somehow didn't work for me. Maybe I don't understand the purpose of setDesignConfig(). Anyhow, the link above worked perfectly for me, in the same scenario as that of the original poster.
I am writing a script to handle an automated email inbox. I've never really dealt with mail servers before, but have gotten to a point where every email sent is executing my script. I am using a .forward file in the home directory of the recipient user that looks like this:
"|exec /home/[MY USER]/magic || exit 75 #[MY USER]"
The script simply takes it's input and writes it to a file at this point. The problem is, I don't know how to find the email being sent, and I can't seem to find any documentation on how the .forward-file works in detail. How do I get to the email?
Any help is greatly appeciated :)
Some general information about the ~/.forward file and the interaction with the mail server is described here, and the Filtering Mail FAQ also contains some information.
While just using a dot-forward file might be sufficient you very typically want to use procmail for more powerful mail processing.