-
AuthorPosts
-
December 30, 2024 at 12:25 am #15434SaynParticipant
Hi there,
I have recently tried to set a rule in Geolocation with timezone but it seems not working no matter what to target users in the US. Added for ex America/Chicago – America UTC-06:00 – America only or time only but unfortunately nothing worked. And checked with VPN and set my computer time to central America .I’d like to have a banner only visible to the US users and also hiding another banner only for US visitors. Any help is appreciated, thanksDecember 30, 2024 at 8:45 pm #15436Aakash ChakravarthyKeymasterHi Sayn,
Geolocation feature in announcer plugin works by detecting the timezone set on the device by the user and not by the IP address.
Also, geolocation by IP requires additional API calls to 3rd party providers and it is not free always.
Hence for this reason, switching VPN won’t work. But the current implementation will work for actual users.
Thanks,
AakashDecember 30, 2024 at 10:25 pm #15438SaynParticipantHi, thanks for the reply, so shouldn’t changing the computer timezone help in this case to test the functionality? Because it did not work for me.
Could you please let me know the correct setting to target the whole US? What should I write exactly, thanks again!December 30, 2024 at 11:08 pm #15439Aakash ChakravarthyKeymasterHi Sayn,
Chaning timezone will work. To target users from America, select
Geolocation with timezone
–contains
–America
More details below,
If it still does not work after changing timezone and restarting your browser, press ctrl+shift+j in your browser and paste the below code in the console.
Intl.DateTimeFormat().resolvedOptions().timeZone;
This text should contain the value you have mentioned in the settings.
Thanks,
AakashDecember 31, 2024 at 4:37 pm #15443SaynParticipantHi, unfortunately it does not display as I tried with different browsers. Incognito mode… Deactivated all the cachings…nothing. The preview from admin side does not show it either. I’m not sure why. Please let me know if you have any other suggestions to troubleshoot, thanks!
January 1, 2025 at 10:57 pm #15447Aakash ChakravarthyKeymasterHi Sayn,
Can you please share the page URL where the announcement is active?
Also, could you please share the value of
Intl.DateTimeFormat().resolvedOptions().timeZone;
like described above?Thanks,
AakashJanuary 2, 2025 at 10:29 pm #15448SaynParticipantHi, this message shows in console ( Uncaught SyntaxError: Unexpected identifier ‘resolvedOptions’ ) I’ll email the link. Thanks!
January 3, 2025 at 12:32 am #15449Aakash ChakravarthyKeymasterHi Sayn,
I received your page URL and there seems to be no obvious errors.
Running the above command should not return any error.
It should display a result like in the below image.
Probably, the code you have entered is incorrect or has a mistake.
Can you please run the command again like in the screenshot above and share me a “screenshot”?
Please upload it to a iamge hosting service like https://imgur.com/
Thanks,
AakashJanuary 3, 2025 at 5:30 pm #15451SaynParticipantHi again,
please check, now it seems ok but still does not show the banner.
thanksJanuary 3, 2025 at 5:30 pm #15452SaynParticipantJanuary 4, 2025 at 12:56 am #15454Aakash ChakravarthyKeymasterHi Sayn,
I looked at your website.
The issue is not with the timezone. You have configured “schedule” display between March 2024 and November 2024.
Please set to display “immediately” under Display -> “Display the announcement”
Thanks,
AakashJanuary 4, 2025 at 9:09 pm #15456SaynParticipantHi, thank but it is already on ”immediately” but you know I have duplicated it probably from the other announcement where it could have been scheduled setting! but this new one has the display on immediately since long time ago. it probably did not updated ? please could you check thanks!
January 5, 2025 at 12:01 am #15457Aakash ChakravarthyKeymasterHi,
I can see 2 announcements on the page. One with immediate display and other with scheduled display.
Can you please check the announcement ID and confirm the display types?
Do you have any WordPress cache enabled? If yes can you please try after clearing it? May be we are looking at cached page.
Thanks,
Aakash -
AuthorPosts
- You must be logged in to reply to this topic.