When the Submit button is clicked, an AJAX call is triggered to pull the data from the EMR. (In the case of this demo, it is just a static JSON file.) The nature of this call will depend on the API of the particular EMR; for Epic Hyperspace it could be a standard XMLHttpRequest to an Interconnect Web Service, for Cerner PowerChart it would be a call to XMLCclRequest from an MPage, and in other EMRs it could be some other means of retrieving the data entirely.
Once the data has been retrieved, depending on the level of control you have over what comes out of the EMR, it may need to be modified into a format that will work with Hyperisk. When the data is in the form of an acceptable JSON string as defined in the EMR Integration guide, it is then loaded into the form's "data" field. Finally, the form is triggered to submit to https://hyperisk.stanfordchildrens.org/?src=DEMO, transmitting the data and loading Hyperisk via an HTTP Post.