Sending a message to TouchDesigner

Now its time to get some data into TouchDesigner. Lets do that by first creating a simple function to send a test value to TouchDesigner.

function button_send(){
	ws.send("This is a text from the browser");	

And a button element in our body, asigning the button_send function to the onclick attribute of the button.

<button onclick = "button_send()" >Click Me</button>

In touchdesigner we create a new table as our output.
in the callbacks, we delete the existing line of the onWebSocketReceiveText and write the following line

op('table2').appendRow( [ client, data ] )

Now, everytime we click on the button on our website, a new line should appear at the table.