added functionality to read GET data on the client

adopted from this stackoverflow answer: http://stackoverflow.com/a/814628/422356