Format date fields in ISO 8601 format

Modify the queryToArray function to format the date fields in ISO 8601 format yyyy-mm-ddTHH:mm:ss.lZ
Modified the queryToArray function to pass in a callback function.

Added a callback function to the queryToArray function which if present
will get each query element passed to it before it is added to the
array. The developer can modify the item how ever they wish in the
callback function.
Add example for use of callback function in queryToArray function

Added an example on how to use the newly added Callback function
capability of the queryToArray function.
Merge pull request #202 from bpamiri/master

Formatting callback added to queryToArray helper