The optional client configuration parameter propertyHref
maps your on-page implementation to a specific URL as it is set up in your Sourcepoint portal. In this article, we have collected some use cases and best practices when utilizing the propertyHref
parameter.
propertyHref
use case- Include
joinHref
in client configuration script propertyHref
vspropertyId
in client configuration script
propertyHref
use case
The propertyHref
parameter is typically used for testing campaigns on properties in local environments. A key benefit of using the propertyHref
parameter is locally testing campaign entities on a property for which there is no property set up in your Sourcepoint portal.
Note: When a campaign is ready to launch publicly to your end-users, we recommend that you swap propertyHref
with the more efficient propertyId
parameter. Click here for more information.
Example
Your organization manages three websites that require consent campaigns to show to end-users:
You have already configured the campaign entities for www.example1.com in your Sourcepoint portal and are currently testing the consent experience in a local environment.
Rather than recreating the campaign entities in your Sourcepoint portal for www.example2.com and www.example3.com, respectively, you can assign www.example1.com to the propertyHref
parameter in your local testing environment for the latter properties to spoof your existing consent message experience.
Include joinHref
in client configuration script
Sourcepoint strongly suggests that whenever you use the propertyHref
parameter in your client configuration script that you also include the joinHref
parameter set to true
as well.
window._sp_ = {
config: {
accountId: XXXXX,
baseEndpoint: 'https://cdn.privacy-mgmt.com',
propertyHref: 'https://www.example1.com',
joinHref: true,
...
The joinHref
parameter is solely used to test your implementation across different servers while still allowing for directory regular expression (RegEx) matching. When joinHref
is set to true
it will ensure that all directory regular expression (RegEx) functionality works in conjunction with the propertyHref
parameter.
propertyHref
vs propertyId
in client configuration script
When you are ready to launch your consent campaign(s) to your end-users publicly, we strongly suggest that you swap propertyHref
with the more efficient propertyId
parameter.
window._sp_queue = [];
window._sp_ = {
config: {
accountId: XXXX,
baseEndpoint: 'https://cdn.privacy-mgmt.com',
propertyId: 12345,
...
By using the propertyId
instead of propertyHref
parameter when launching a campaign publicly to your end-users you will eliminate a network call for your overall implementation
Comments
0 comments