9 Replies
Charles Jude Prestia

You can include a javascript function to fire when the user submits their name and email (Player Triggers > Execute Javascript). 

The function could take the name and email values, store them in local or session storage

example:  sessionStorage.setItem('actorName', actorNameFromForm)

then you can retrieve them before the xAPI statement is created 

example: actorNameForStatement = sessionStorage.getItem('actorName') 

and include the new variable in the statement 


"actor": {
    "name": "User: " + actorNameForStatement,

Kyle Mullaney

I have a way to get the name (and I assume I will be able to pull the email address also) from he player (LMS) and store them as variables. In the code I am using the name is stored as myName. How do I get the xAPI statement to send that variable as the actor?

The same would then apply to the email address.

andrew mcsmith

HI, i've followed your steps word for word on linkedin but am getting this error when clicking on note01:

FROM CHROME CONSOLE:  Access to XMLHttpRequest at 'https://trial-lrs.yetanalytics.io/xapi/statements' from origin 'http://www.designguru.co.nz' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.

FROM IE CONSOLE:  SCRIPT7002: XMLHttpRequest: Network Error 0x80700013, Could not complete the operation due to error 80700013.

any ideas whats going wrong ?  Im not a programmer and any pointers to fix would be so much appreciated.

This discussion is closed. You can start a new discussion or contact Articulate Support.