This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set text item delimiters to " " | |
set scriptName to text item 1 of parameter | |
set paramCount to count parameter's text items | |
try | |
set scriptParameters to text items 2 thru paramCount of parameter | |
on error | |
set scriptParameters to "" | |
end try | |
set text item delimiters to "" | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<form> -- remove this | |
<h3>Give us a buzz.</h3> | |
<p> | |
The fastest way to get a hold of us is to give us a call. Our hours are 9 AM to 5 PM, Monday through Friday. But we're dedicated to our customers, so we'll probably call you back if you ring us after hours. | |
</p> | |
<h3>Leave a message.</h3> | |
<table class="contact-table"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var httpAgent = require('http-agent'), | |
sys = require('sys'); | |
var agent = httpAgent.create('www.bungie.net', ['/stats/reach/playergamehistory.aspx?player=thechapel&vc=2']); | |
agent.addListener('next', function (err, agent) { | |
var window = jsdom.jsdom(agent.body).createWindow(); | |
jsdom.jQueryify(window, '/home/wyl/webapps/node/jquery.js', function (window, jquery) { | |
window.jQuery('a[id$=hypGame]').each(function () { | |
agent.addUrl('/stats/reach'+this.href); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var httpAgent = require('http-agent'), | |
sys = require('sys'); | |
var agent = httpAgent.create('http://www.bungie.net/stats/reach/playergamehistory.aspx?player=thechapel&vc=2'); | |
agent.addListener('next', function (err, agent) { | |
sys.puts('Body of the current page: ' + agent.body); | |
sys.puts('Response we saw for this page: ' + agent.response); | |
// Go to the next page in the sequence |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var httpAgent = require('http-agent'), | |
jsdom = require('jsdom'), | |
url = require('url'), | |
sys = require('sys'); | |
exports.start = function () { | |
var agent = httpAgent.create('www.bungie.net', ['/stats/reach/playergamehistory.aspx?player=thechapel&vc=2']); | |
agent.addListener('next', function (err, agent) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var window = jsdom.jsdom(agent.body).createWindow(); | |
jsdom.jQueryify(window, '/home/wyl/webapps/node/jquery.js', function (window, jquery, query) { | |
window.jQuery('.selector').each(function () { | |
query.push(this.innerHTML.trim()); | |
}); | |
window.jQuery('.selector2').each(function () { | |
query2.push(this.innerHTML.trim()); | |
}); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
exports.jqwindow = function(agent, ratingSel, userSel, callback) { | |
var window = jsdom.jsdom(agent.body).createWindow(); | |
jsdom.jQueryify(window, './jquery.js', function (window, jquery) { | |
var ratings = []; | |
var userRating; | |
window.jQuery(ratingSel).each(function () { | |
ratings.push(this.innerHTML.trim()); | |
}); | |
window.jQuery(userSel).each(function () { | |
console.log(this.innerHTML.trim()); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var httpAgent = require('http-agent'), | |
jsdom = require('jsdom'), | |
url = require('url'), | |
sys = require('sys'); | |
exports.start = function () { | |
var agent = httpAgent.create('www.bungie.net', ['/stats/reach/playergamehistory.aspx?player=thechapel&vc=2']); | |
agent.addListener('next', function (err, agent) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var request = require('request'), | |
sys = require('sys'); | |
var gamerTag = 'thechapel'; | |
getGames = function() { | |
getData = function(url, cb) { | |
request({uri:url}, function (error, response, body) { | |
if (!error && response.statusCode == 200) { | |
cb(body); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"reason":"Okay","status":0,"HasMorePages":true,"RecentGames":[{"CampaignDifficulty":"Easy","CampaignGlobalScore":0,"CampaignMetagameEnabled":false,"GameDuration":449,"GameId":218832247,"GameTimestamp":"\/Date(1287007233000-0700)\/","GameVariantClass":2,"GameVariantHash":-9102622298157329361,"GameVariantIconIndex":1,"GameVariantName":"Slayer DMRs","HasDetails":false,"IsTeamGame":true,"MapName":"Countdown","MapVariantHash":-7331108254952843887,"PlayerCount":8,"PlaylistName":"Team Arena (Season 2)","RequestedPlayerAssists":0,"RequestedPlayerDeaths":11,"RequestedPlayerKills":11,"RequestedPlayerRating":1208,"RequestedPlayerScore":38,"RequestedPlayerStanding":1},{"CampaignDifficulty":"Easy","CampaignGlobalScore":0,"CampaignMetagameEnabled":false,"GameDuration":451,"GameId":218752990,"GameTimestamp":"\/Date(1287006332000-0700)\/","GameVariantClass":2,"GameVariantHash":-9102622298157329361,"GameVariantIconIndex":1,"GameVariantName":"Slayer DMRs","HasDetails":false,"IsTeamGame":true,"MapName":"Forge World","MapVarian |
OlderNewer