Sha256: 232cddc79d80044e5e9db52e799b84d4ad95bb9782286ea0f577217528dc92bf
Contents?: true
Size: 735 Bytes
Versions: 1
Compression:
Stored size: 735 Bytes
Contents
# -*- coding: utf-8 -*- # # tpoint.rb: T-POINT for PointsScraper # # Copyright (C) 2012 by TADA Tadashi <t@tdtds.jp> # Distributed under GPL. # require 'points-scraper/default' module Points::Scraper class TPoint < Default URL = 'https://tsite.jp' def start start_scrape do |agent| agent.get( URL + '/tm/pc/login/STKIp0001001.do' ) agent.page.form_with( :name => 'form1' ) do |form| form.action = URL + '/tm/pc/login/STKIp0001010.do' form['LOGIN_ID'] = @user form['PASSWORD'] = @pass form.click_button end agent.page.at( 'p.point > span.number' ).text end end end end # Local Variables: # mode: ruby # indent-tabs-mode: t # tab-width: 3 # ruby-indent-level: 3 # End: # vim: ts=3
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
points-scraper-0.1.0 | lib/points-scraper/tpoint.rb |