hello kentico team i am trying to detect the current location is there any method in kentico to use it and get the city name i try some this code but didnt work any one have idea thanks
{%if(AnalyticsContext.CurrentGeoLocation.City != null) {%} your food in {% AnalyticsContext.CurrentGeoLocation.City %} {% } #%} {% else{ %} there is no food in this location {% } #%}
hope, you are not doing it on your local server? It wont work for internal network IPs. Print your {%IP%} and google 'IP Location Finder' and see how your IP is resolved there.
{%IP%}
i am doing it in trasnformation what is the best practices to do it
Please, sign in to be able to submit a new answer.