';
// Loop through each HIT on this page
$('table[width="100%"][height="100%"]', data).each( function(i) {
title[i] = $(this).find("a.capsulelink[href='#']").text().trim();
requester[i] = $(this).find(".requesterIdentity").text()
pay[i] = $(this).find(".reward").text()
timeLeft[i] = $(this).find("td[width='25%'] td.capsule_field_text").text().trim();
// sign is used to alterate the row backgrounds
var sign = "odd"
if ( ((i + 1)/2) == Math.round((i + 1)/2) )
sign = 'even';
// Shorten the time left string
timeLeft[i] = timeLeft[i].replace(" minutes", "m").replace(" seconds", "s");;
// Construct the return link for this HIT
returnURL[i] = $(this).find("a[href^='/mturk/return']").attr("href");
// Construct the continue link for this HT
continueURL[i] = $(this).find("a[href^='/mturk/continue']").attr("href");
// Add the HIT to the table
hitString += '' +
'' + (title[i].length > 60 ? title[i].substring(0, 60 - 3) + '...' : title[i]) + ' | ' +
'' + (requester[i].length > 15 ? requester[i].substring(0, 15 - 3) + '...' : requester[i]) + ' | ' +
'' + pay[i] + ' | ' +
'' + timeLeft[i] + ' | ' +
'Return | ' +
'
';
}); // End loop
// Close the table
hitString += '