Re: Some questios about digitalData

Hello JC,

The digitalData object is just like any other JavaScript object.  You may 
build it in any way you like and at any time you like as long as it is 
built before it is needed.  There are numerous ways to build a JavaScript 
object and you do not have to rely on the method in the examples.  Here is 
a link to the W3C spec that may help:

http://www.w3.org/2013/12/ceddl-201312.pdf

I worked on that committe and can give background if you have any other 
questions.

Thanks,

Hutch White   

Partner Solutions Manager
IBM ExperienceOne


11501 Burnett Rd. 
Bldg. 905, 2nd Floor 
Austin, TX 78758-3400   
 
Phone:  720.395.3682
Email  :  hutchwh@us.ibm.com



 


 

 



From:   Juan Carlos Palacios Chavez <jcpalaci@mx1.ibm.com>
To:     public-custexpdata@w3.org
Date:   09/18/2015 03:16 AM
Subject:        Some questios about digitalData



Hi there 

I am trying to understand the way a user can build the digitalData object, 
since we have to parse the documents in order to find the information 
stored there. 

In general, I understand the specification, but I have a few questions I 
would like you to help me understand: 

In the specification, a few examples are used, and they give me the 
impression we can use multiple expressions to build the digitalObject 
across the document.. Instead of having the digitalObject definition in 
one single expression (using one single object literal), can we use 
different expressions (like my example below) to define digitalData? 
Are we supposed to define digitalObject in the head? Can be spread across 
the document (body)? 
Can we use variables to build values? Like "productURL": basePath + 'path'


digitalData = { 
        page: { 
                category: { 
                        primaryCategory: 'SB03' 
                }, 
                pageInfo: { 
                        effectiveDate: '2015-05-14', 
                        expiryDate: '2017-12-18', 
                        language: 'en-US', 
                        ibm: { 
                                ... 
                        }, 
                } 
        } 
}; 

.... 

digitalData.page.pageInfo.maxymiser: { 
        "synchronous": true 
}; 

.... 
var basePath = 'http://www.server.com/'; 

digitalData.product = []; 
digitalData.product[0] = { 
        productID: "testID", 
        'productName': "testName", 
        "productURL": basePath + 'path' 
}; 



Thanks in advance 

Best regards 
JC 

Juan Carlos Palacios 
UX Developer  - IBM Client Innovation Center 
Phone: +52-33-3669-7000 x4321 
Mobile: 52-33-1150-6292 
E-mail: jcpalaci@mx1.ibm.com

Received on Friday, 18 September 2015 13:48:24 UTC