Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
blocks:app-note:visitor:hello-world [2022-12-22 16:18]
admin created
blocks:app-note:visitor:hello-world [2022-12-22 17:28] (current)
mattias [Viewing the Results]
Line 1: Line 1:
 ====== Collecting Basic Data using Visitors Phone ====== ====== Collecting Basic Data using Visitors Phone ======
  
-This application note provides a gentle starting point for learnig about the Visitor Data Collection functionality of Blocks. While it shows the basic steps for collecgin visigor data based on mobile phones, it provides no useful functionality beyond the data collection as such.+This application note provides a gentle starting point for learning about the Visitor Data Collection functionality of Blocks. While it shows the basic steps for collecting visitor data based on mobile phones, it provides no useful functionality beyond the data collection as such.
  
 ===== Installation ===== ===== Installation =====
Line 28: Line 28:
 ==== Viewing the Results ==== ==== Viewing the Results ====
  
-As mentioned at the beginning of this application not, all it does is collect data frmo visitor's phones. The resulting data ends up in the //record// directory of your Blocks server, in the subdirectory named after the data type collected, which in this case is //HelloWorldData//. Herein you'll find a folder named with the identity given to the visitor's phone, beginning with a P followed by a number. There's one such folder for each uniwue data record, containing at least a TSV file with a log of all the actions taken by the visitor affecting the data record. A TSV file is similar to its more well known CSV cousin, but uses tab characters as separators instead of commas. The content of the file can be viewed in a text editor, or opened using a spreadsheet such as Microsoft Excel or Apple Numbers. Here's an example of what it can look like:+As mentioned at the beginning of this application not, all it does is collect data from visitor's phones. The resulting data ends up in the //record// directory of your Blocks server, in the subdirectory named after the data type collected, which in this case is //HelloWorldData//. Herein you'll find a folder named with the identity given to the visitor's phone, beginning with a P followed by a number. There's one such folder for each unique data record, containing at least a TSV file with a log of all the actions taken by the visitor affecting the data record. A TSV file is similar to its more well known CSV cousin, but uses tab characters as separators instead of commas. The content of the file can be viewed in a text editor, or opened using a spreadsheet such as Microsoft Excel or Apple Numbers. Here's an example of what it can look like:
  
 {{ :blocks:app-note:visitor:visitortsvdata.png?nolink&400 |}} {{ :blocks:app-note:visitor:visitortsvdata.png?nolink&400 |}}
Line 41: Line 41:
 The collection of fields match what data you want to collect, and is defined in the script managing the data collection. The name of this record type is then specified in the "Identify Individual Visitors by" field on the //Identity// tab of the Visitor Spot's settings.  The collection of fields match what data you want to collect, and is defined in the script managing the data collection. The name of this record type is then specified in the "Identify Individual Visitors by" field on the //Identity// tab of the Visitor Spot's settings. 
  
-The script defining the data record as well as how data is collected and used in this example is at script/user/HelloWorld.ts. This script consists mostly of comments providing detailed explanations on what's going on. You need to have the recommended set of [[blocks:drivers:tools|development tools]] (or equivalent) to check out or modify this example.+==== The Script ==== 
 + 
 +The script defining the data record as well as how data is collected and used here is at script/user/HelloWorld.ts. This script consists mostly of comments providing detailed explanations on what's going on. You need to have the recommended set of [[blocks:drivers:tools|development tools]] (or equivalent) to check out or modify this example.