function expireHit($hitId) { global $dbh; turk_easyExpireHit($hitId); sleep(0.25); //Give the HIT a moment to expire $mt = turk_easyDispose($hitId); sleep(0.25); //Give the HIT a moment to dispose }
$loop--; } break; case 'expireAll': $msg = 'All asssignable hits expired and disposed of.'; $array = turk50_searchAllHits(); if (isset($hitTitle) && isset($num)) { foreach ($array as $hit) { if ($hit->Title != $hitTitle) { unset($array[$num]); } } } foreach ($array as $hit) { if ($hit->HITStatus == 'Assignable' && (isset($hitTitle) && $hit->Title == $hitTitle || !isset($hitTitle))) { turk_easyExpireHit($hit->HITId); turk_easyDispose($hit->HITId); } } break; default: break; } //die('action performed.'); } ?> <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> <html> <head> <title> Overview - What was that?</title> <!--
function expireHit($hitId) { global $dbh, $debug, $numAssignableHits, $SANDBOX; turk_easyExpireHit($hitId); sleep(0.25); //Give the HIT a moment to expire $mt = turk_easyDispose($hitId); sleep(0.25); //Give the HIT a moment to dispose return $mt; }