Closed anirbanbasu closed 1 year ago
You can change the address format as described here.
In your config/_default/params.yaml
there is the section:
locale:
date_format: 'Jan 2, 2006'
time_format: '3:04 PM'
address_format: en-us
You can use one of the format already available in data/address_formats.toml
. The default is en-us
, which only displays 'street', 'city', 'region', 'postcode'.
Closing as the question has been answered by @Agos95 above.
@Agos95 thank you. That solved the problem. I had to choose en-ca
. I wonder why the en-us
or en-gb
address formats do not include the country. I guess I can override it locally but that is not an option I would like to go for.
Preliminary Checks
Description
Even if the country is specified for the event, it is not displayed when the site is rendered.
For example, the code at https://github.com/wowchemy/starter-hugo-research-group/blob/main/content/event/example/index.md?plain=1 renders as https://research-group.netlify.app/event/example/ where the location does not show the country.
Likewise, the code at https://github.com/anirbanbasu/ifiptm.github.io/blob/main/content/event/ifiptm2023/index.md?plain=1 renders as https://ifiptm.netlify.app/event/ifiptm2023/ with no mention of the country. Furthermore, if the
postcode
is not specified, the address line ends with a comma, as in https://ifiptm.netlify.app/event/ifiptm2009/.Reproduction Link
https://github.com/wowchemy/starter-hugo-research-group/blob/main/content/event/example/index.md?plain=1
Steps to Reproduce
content/event/example-event/
with the content of https://github.com/wowchemy/starter-hugo-research-group/blob/main/content/event/example/index.md?plain=1country
is present, it will not be displayed when Hugo renders the website.Expected Result
A location with the specified address fields, including the country (if present).
Actual Result
postcode
, but not the country.postcode
is not present then the address line ends abruptly with a comma.What Hugo Module versions does your site use?
What operating system(s) are you seeing the problem on?
macOS
What browser(s) are you seeing the problem on?
Other
Which Wowchemy template are you using?
Research Group
What version of Hugo are you using?
hugo v0.111.3+extended darwin/amd64