Template Service API V3
Standard API (ver. 3)
- getRequiredHead
- This method returns the required HTML head with common merged JS and CSS declarations.
https://www.eea.europa.eu/templates/v3/getRequiredHead
ORhttp://www.eea.europa.eu/templates/v3/getRequiredHead
- getHeader
- This method returns the header. Optional parameter "jsdisable" works together with setting this parameter on getRequiredHead.
https://www.eea.europa.eu/templates/v3/getHeader
ORhttp://www.eea.europa.eu/templates/v3/getHeader
- getFooter
- This method returns the required footer.
https://www.eea.europa.eu/templates/v3/getFooter
ORhttp://www.eea.europa.eu/templates/v3/getFooter
I18N: Translated template
In order to get a translated version of the EEA template, please add the 2-letters ISO 639-1 language code into the URL call. For example, to get the header in Italian you would call the header like this:
https://www.eea.europa.eu/templates/v3/it/getHeader
ORhttp://www.eea.europa.eu/templates/v3/it/getHeader
The language code is used, it must be used consistently on all the calls, in order to not mix languages.
Performance and caching
All the template service calls are cached by a proxy cache system (squid) at the EEA servers. This improves the response time from EEA.
However we do not reccomend to rely solely on the EEA template service when thinking about performance. We strongly recommend you locally cache each call to the template service and then provide a way to EEA for invalidating and refreshing your local cached template.
For example, you should provide a URL similar either as
- parameter
https://myproject.eea.europa.eu/?refreshtemplate=1
OR - page
https://myproject.eea.europa.eu/refreshtemplate
This will allow EEA to refresh the templates on all sites when a new template and CSS is available. In this way all sites will stay synchronized with latest design and main navigation.
Permalinks
- Permalink to this version
- 6716b2d910d14317a7f95a5ff87adbdc
- Permalink to latest version
- 9VKF4D867P
Geographic coverage
For references, please go to https://www.eea.europa.eu/code/templates/template-service-api-v3 or scan the QR code.
PDF generated on 01 Jul 2022, 07:26 PM
Document Actions
Share with others