Skip to content

Commit

Permalink
Add HIT ID.
Browse files Browse the repository at this point in the history
  • Loading branch information
longouyang committed Oct 4, 2011
1 parent 713a824 commit 217318a
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions README.markdown
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
A tiny library for submitting external HITs on Mechanical Turk.

It creates a global JavaScript object, `turk`, that has these four properties:
It creates a global JavaScript object, `turk`, that has these five properties:

* `previewMode`: true if we're currently in the external HIT preview mode.
* `hitId`: the HIT ID variable.
* `assignmentId`: the assignment ID variable.
* `workerId`: the worker ID variable.
* `turkSubmitTo`: the Mechanical Turk submission server (either production or sandbox)..
* `previewMode`: true if we're currently in the external HIT preview mode.
* `turkSubmitTo`: the Mechanical Turk submission server (either production or sandbox).


These variables get read from `window.location.href`. If they aren't in `window.location.href`, the scrip script also tries `document.referer`, so you can conceivably split a task across two different pages. The script provides a single method:

Expand Down

0 comments on commit 217318a

Please sign in to comment.