Humm... You see another use for it is making a Security login screen at work... I am making an Itranet, and I want it so to go into an area of the Intranet you click a link it opens a cut down version of RPG Maker XP that I have made and then from there I have set an integer script working on a 6 digit code.
A Fun Security application, and fairly unhackable as its embeded into an EXE... WICKED !!!
Just need it to work... Just wondered if there is an ADAVANCED advanced message window script that can launch URL's or Hyperlinks to Drives within a network.
I have found some Ruby Script for GET URL commands... but I don't know nothing about scripting:-
require 'mechanize'
class Player
def initialize(element)
@data = element
elementList = @data.elements
@name = elementList.to_a(".//a[@class='name']")[0].text
gameLink = elementList.to_a(".//td[@class='gametime']/a")[0]
if gameLink
daLink = gameLink.attribute('href')
if !gameLink.to_s.include?('preview')
@started = true
end
@link = daLink.to_s.sub('recap','boxscore')
@status = gameLink.text.to_s
else
@link = ''
@status = ''
end
end
def started
@started
end
def name
@name
end
def link
@link
end
def status
@status
end
end
class BoxScore
def initialize(url, agent)
@url = url
@agent = agent
page = @agent.get(@url)
page.watch_for_set = {}
page.watch_for_set['body']=nil
body = page.watches['body'][0]
tables = body.elements.to_a("//table[@class='yspwhitebg']")
tables.each do | t |
header = t.elements.to_a('tr[1]/td[1]')[0]
if header.text
if header.text.to_s == 'Rushing'
@rushing = t
end
if header.text.to_s == 'Receiving'
@receiving = t
end
if header.text.to_s == 'Passing'
@passing = t
end
end
end
end
def print_stats(player)
print_table('Passing', player, @passing, 4,9)
print_table('Rushing', player, @rushing, 3,6)
print_table('Receiving', player, @receiving, 3,6)
end
def print_table(stat_name, player, table, yd_index, td_index)
exp = "tr[@class='ysprow1' or @class='ysprow2']"
if table
stats = table.elements.each(exp) do |row|
firstData = row.elements.to_a("td[1]")[0].text
if firstData.to_s == player.name
print stat_name + ' Yds:' + row.elements.to_a("td["+yd_index.to_s+"]")[0].text
print ' TDs:' + row.elements.to_a("td["+td_index.to_s+"]")[0].text
puts
end
end
end
end
end
agent = WWW::Mechanize.new
agent.user_agent_alias = 'Windows IE 6'
username = ARGV[0].strip
password = ARGV[1].strip
teamPage = ARGV[2].strip
# puts username +"@" + password +':'+ teamPage
loginPage = agent.get('http://login.yahoo.com/config/login')
form = loginPage.forms.find {|f| f.name == 'login_form'}
form.fields.find {|f| f.name == 'login'}.value = username
form.fields.find {|f| f.name == 'passwd'}.value = password
loginResult = agent.submit(form, form.buttons.first)
# puts loginResult.inspect
page = agent.get(teamPage)
page.watch_for_set = {}
page.watch_for_set['tr']=nil
statLines = ['even', 'odd', 'odd first', 'odd last', 'even last', 'even first']
stats = page.watches['tr'].find_all {|n| statLines.include?(n.attributes['class'])}
#puts stats.inspect
for element in stats
player = Player.new(element)
puts player.name + ' - ' + player.status
if player.started
boxScore = BoxScore.new(player.link, agent)
boxScore.print_stats(player)
end
puts
end