Check email accounts with a ruby script

I’ve seen a Ruby script that could check web-based email accounts (e.g.,
log into specific gmail, yahoo, or hotmail email accounts) by opening a
web browser. I’m not sure what triggers the yahoo captcha challenge.
However, I’d like to know if there was free Ruby code for a script to
check email accounts. In the script you hardcode the username and
password. I don’t have much experience with Ruby. This isn’t homework.
You can send it to me after a semester would normally end (e.g.,
12/21/12). But assistance sooner would be very appreciated.

On Sat, Nov 26, 2011 at 10:02 PM, Michael C. [email protected]
wrote:

I’ve seen a Ruby script that could check web-based email accounts (e.g.,
gmail, yahoo, hotmail, etc.) by opening a web browser. I’m not sure what
triggers the yahoo captcha challenge. However, I’d like to know if
there was free Ruby code for a script to check email accounts. In the
script you hardcode the username and password. I don’t have much
experience with Ruby.

Years ago I used FireWatir to drive Firefox to hit GMail; Watir
Webdriver looks to be the modern equivalent:

http://watirwebdriver.com/

require ‘watir-webdriver’
b = Watir::Browser.new
b.goto ‘bit.ly/watir-webdriver-demo’
b.text_field(:id => ‘entry_0’).set ‘your name’
b.select_list(:id => ‘entry_1’).select ‘Ruby’
b.select_list(:id => ‘entry_1’).selected? ‘Ruby’
b.button(:value => ‘Submit’).click
b.text.include? ‘Thank you’

http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/374100

Captchas would be a problem though :slight_smile: A more reliable approach may
be to use another protocol or API for the service (e.g. REST,
Atom/RSS, IMAP).

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs