server side script to automatically extract data from new email.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • tgmcnaughton
    New Member
    • Aug 2007
    • 6

    server side script to automatically extract data from new email.

    I'm brand new to server-side scripting. I don't even know if javascript can do this.

    I would like a script running on my server to periodically login to and check my email account and each time it finds a new message with a particular identifying subjectline, it should extract the body of the message into a text variable and append it to an existing file already on the server.

    I can handle the parsing and the appending, but I don't know how to have the server script automatically check and extract data from an email.

    If javascript isn't the right tool for this then what is?

    Thanks,
    Tim
  • acoder
    Recognized Expert MVP
    • Nov 2006
    • 16032

    #2
    Welcome to TSDN!

    You can't do this with Javascript. You may be able to do it with a server-side language, but I'm not sure. Which server-side language are you using?

    Comment

    • tgmcnaughton
      New Member
      • Aug 2007
      • 6

      #3
      Thanks for the reply.
      Let me explain my goals more explicitly. I have a javascript running on a page hosted by googlepages at:
      http://tgmcnaughton.go oglepages.com/map2.htm
      It uses the google map api to draw a map and plot a marker at a particular latitude and longitude.

      I have a GPS device which sends emails to my gmail account containing in the body a string of the form A3402.40611712. 29122514400 which is the current location of the device.
      I want to have the script periodically check for new messages from the sender: xxx@airmessage. net, extract the string from the body and break it into the latitude (34.02406) and the longitude (-117.12291) and a timestamp (22:51:44) and assign the variables lat and lon to be the new values to redraw the map and marker. I can do the parsing and variable assignment; I need help with the method of accessing the email account.

      Does this constitute server-side scripting? If JavaScript cannot do this, then what language would I use?
      Thanks very much,
      Tim

      Comment

      Working...