CMS Development

prasadcolumbus
Participant | Diamond Partner
Participant | Diamond Partner

HUBL- How to get the country code or country name?

I have created the custom module. In this module currency symbol has changed based on the country.can you any one help how to get the country code on custom module?

0 Upvotes
3 Replies 3
Anonymous
Not applicable

HUBL- How to get the country code or country name?

Would getting the language be a workable solution? https://designers.hubspot.com/docs/hubl/hubl-supported-variables#hs_cos_wrapper_widget_1548717022513

 

--
Bryan Schneidewind
Manager of Web Development
Weidert Group

0 Upvotes
prasadcolumbus
Participant | Diamond Partner
Participant | Diamond Partner

HUBL- How to get the country code or country name?

Thanks Bryan for your valuable replay!.But this not solution for my issue because I need the vistior country code or country name same like "{{ request.remote_ip }}"

 

Can you please let me know how to get it on HUBL?

0 Upvotes
Anonymous
Not applicable

HUBL- How to get the country code or country name?

Unfortunately hubl will only allow you to get US, CA and GB for a country code with the postal_location function: https://designers.hubspot.com/en/docs/hubl/hubl-supported-functions#postal-location

I'm not aware of any other hubl markup that pulls a country code.... have you looked into smart content for this? https://knowledge.hubspot.com/cos-general/how-to-set-up-smart-content-by-preferred-language

 

--
Bryan Schneidewind
Manager of Web Development
Weidert Group