Hi Johan, First of all let me thank you for your quick response. Actually I've been asked to do this with QPSMTPD that's why I need a qpsmtpd plugin, and let me complete the requirement. The 160 characters will be immediately forwarded to a smsc (sms client) to forward it to the receiver, and then look in to the next 160 characters. The main idea is that not to keep any archive but to forward the requested no. of sms's and discard the mail after forwarding it to his mail box.
Let me know if this information is still not enough. Thank you very much. With best regards, Dilshan ----- Original Message ---- From: Johan Almqvist <[EMAIL PROTECTED]> To: [email protected] Cc: Dilshan Perera <[EMAIL PROTECTED]> Sent: Wednesday, April 11, 2007 2:01:23 PM Subject: Re: Could someone help me to write a PLUGIN FOR E-MAIL TO SMS! Dilshan Perera wrote: > Hi Everybody, > Could someone help me to write a plugin for e-mail to sms. > I need to write a plugin to accept an e-mail > then to exract the from: to: subject: attachment names & the body > after that need to chop the mail in to 160 character blocks, to send as sms > first sms contains the info. from: subject: date: attachment names(if any) & > the rest will be the body of the e-mail > the next pages will contain the rest of the body choped in 160 charater > blocks. > maximum number of blocks are 10 and if the e-mail body is longer than that > have to discard the rest. > the email will receive in a format [EMAIL PROTECTED] ([EMAIL PROTECTED]) > from that want to extract the nine digits and assign it as the number of the > sms receiver. > finally the mail will be forwarded to the same receivers ums(email) account. > > This is my requirement. I have so far been modifying using the maildir and > smtp-forward plugins, still couldn't come up with the proper solution. > > Hence I thought of getting some help from you. > If someone who is possible to write this plugin please help me. Your requirements aren't really complete. Where do the 160-character chunks of data go? Do we need to write them to a file, send them by HTTP or SMTP or write them to a database? [I.e. how is the SMS sent?] Also why do you want to do this with a qpsmtpd plugin? This sounds to me like a typical .forward / .qmail case; or at least handoff from qpsmtpd to another program. -Johan -- Johan Almqvist Irisveien 28 0870 Oslo Norway Mobile: +47 40 04 68 21 E-mail: [EMAIL PROTECTED] ____________________________________________________________________________________ Don't get soaked. Take a quick peak at the forecast with the Yahoo! Search weather shortcut. http://tools.search.yahoo.com/shortcuts/#loc_weather
