Highlighted

Is posible change the s_account in iOS+SiteCatalyst implementation in function of device type?

Hi Jason. For example, I have a one profile for iOS devices but I need apply in one extension to change the s_account of SC in function if the user device is iPad or iPhone. I thought this code: if(b.device=='ipad' || b.device=='iPad'){ b.account='nhhotelesipadapp'; } That is possible?
2 REPLIES 2
Highlighted

Is posible change the s_account in iOS+SiteCatalyst implementation in function of device type?

Tealium Employee
Hey Jorge, You should be able to accomplish this through a "Set Data Values" Extension. You can create a new data source that would be a "container." In my implementation I refer to it as "reportsuite." It would look like this Set "reportsuite" to text "nhhotelesipadapp" Condition: when device = iPad Then map reportsuite to s_account in you tag mappings. I have been successful with this in the Site Catalyst App Measurement for JavaScript Tag. Not sure if the H26 Site Catalyst tag supports this. Hope it helps. Jim
Highlighted

Is posible change the s_account in iOS+SiteCatalyst implementation in function of device type?

Employee Emeritus
Hey Jorge, As Jim mentions above this is possible in both the AppMeasurement tag and H25/H26 versions of the standard SiteCatalyst tag. Your original set up should work fine. if(b.device=='ipad' || b.device=='iPad'){ b.account='nhhotelesipadapp'; } Scope this tag to SiteCatalyst and map "account" to "s_account" in the SiteCatalyst Tag Mappings Section. Jim's method will also work. It is essentially the same thing, but using "reportsuite" as the variable instead of "account." The only caveat to the above methods would be that "device" would need to be defined prior to this code running that distinguishes what type of device is being used. If the device type is not being defined somewhere prior to this code then that will need to be added before these methods will work. Hope this helps.