DTM - How to use Client IP address as a rule condition

Avatar

Avatar
Validate 1
Level 2
stewart_schilli
Level 2

Likes

6 likes

Total Posts

9 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 1
View profile

Avatar
Validate 1
Level 2
stewart_schilli
Level 2

Likes

6 likes

Total Posts

9 posts

Correct reply

0 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 1
View profile
stewart_schilli
Level 2

15-10-2015

I'd like to know how to use the client's IP address as a rule condition in DTM.  I'd like to be able to include or exclude based on IP address using regular expressions for matching.  Is there a clean way to do this? 

 

Thanks, 

-Stew

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Boost 3
Level 2
shawncreed1
Level 2

Likes

3 likes

Total Posts

25 posts

Correct reply

12 solutions
Top badges earned
Boost 3
Boost 1
Affirm 5
Affirm 3
Affirm 10
View profile

Avatar
Boost 3
Level 2
shawncreed1
Level 2

Likes

3 likes

Total Posts

25 posts

Correct reply

12 solutions
Top badges earned
Boost 3
Boost 1
Affirm 5
Affirm 3
Affirm 10
View profile
shawncreed1
Level 2

15-10-2015

Stew,

Unfortunately IP address is not exposed directly in the browser via HTML/Javascript for security reasons. The only way that DTM could use IP address is if your site actually set the user's IP address in a Javascript variable on every page, or if you used an AJAX call to an outside server to get this information.  The latter of these is not the preferred option given that it adds additional latency to the processing of your DTM rules (because it has to wait for the remote server to respond), but on the plus side it is something that you would be able to implement and try out without involving your IT department to update the code on the page.

Here's a link to check out with some ideas on how this might be done (note that this is an external site so none of the code has been vetted/tested by Adobe):
http://stackoverflow.com/questions/391979/get-client-ip-using-just-javascript

Hope this helps!

Best,
Shawn

Answers (0)