diff options
author | Benjamin Franzke <benjaminfranzke@googlemail.com> | 2016-07-04 07:26:37 +0200 |
---|---|---|
committer | Benjamin Franzke <benjaminfranzke@googlemail.com> | 2016-07-04 07:37:21 +0200 |
commit | df7ec5a70f0effd1c7749392a86c3d7adaf83364 (patch) | |
tree | 1249e28633ddc9ba99148ee94568c94f809b9cf8 /xsl/common.xsl | |
parent | b2f92f6011e27de75b38ea5e88f2390cfea2fa78 (diff) | |
download | mutti-web-df7ec5a70f0effd1c7749392a86c3d7adaf83364.tar.gz mutti-web-df7ec5a70f0effd1c7749392a86c3d7adaf83364.tar.bz2 mutti-web-df7ec5a70f0effd1c7749392a86c3d7adaf83364.zip |
Add git hash as query string to resources
..to be able to set an infinite cache for the browser, but to
invalidate the resources for every git commit
(That may be a waste of resources, but is "most safe" to ensure we get an up to date site)
It has to be explicitly defined in the template.
Occurences of the img-tag in the source files get the git hash automatically appended.
Diffstat (limited to 'xsl/common.xsl')
-rw-r--r-- | xsl/common.xsl | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/xsl/common.xsl b/xsl/common.xsl index f9387dc..07acb7d 100644 --- a/xsl/common.xsl +++ b/xsl/common.xsl @@ -9,6 +9,7 @@ <xsl:include href="navi.xsl" /> <xsl:include href="link.xsl" /> <xsl:include href="svg.xsl" /> + <xsl:include href="img.xsl" /> <xsl:strip-space elements="*"/> @@ -16,6 +17,7 @@ <xsl:variable name="title" select="document('../main.xml')/s:site/s:page[@filename = $filename]/@title" /> <xsl:param name="suffix" select="'.xml'" /> <xsl:param name="stylesheet" select="'style.css'" /> + <xsl:param name="version" select="''" /> <xsl:output method="xml" indent="no" encoding="utf-8" cdata-section-elements="script style" |