- escape image alt attribute as it's breaking xml format in some metadata.xml

This commit is contained in:
Richard Alam 2017-03-28 20:16:26 +00:00
parent 7fdbc5b293
commit fcca81783e
8 changed files with 9 additions and 9 deletions

View File

@ -39,7 +39,7 @@ public class ResponseBuilder {
Template ftl = null;
try {
ftl = cfg.getTemplate("get-meeting-info.ftl");
ftl = cfg.getTemplate("get-meeting-info.ftlx");
} catch (IOException e) {
log.error("Cannot find get-meeting-info.ftl template for meeting : " + meeting.getInternalId(), e);
}
@ -74,9 +74,9 @@ public class ResponseBuilder {
Template ftl = null;
try {
ftl = cfg.getTemplate("get-meetings.ftl");
ftl = cfg.getTemplate("get-meetings.ftlx");
} catch (IOException e) {
log.error("IO exception for get-meetings.ftl : ", e);
log.error("IO exception for get-meetings.ftlx : ", e);
}
StringWriter xmlText = new StringWriter();
@ -90,7 +90,7 @@ public class ResponseBuilder {
} catch (TemplateException e) {
log.error("Template exception : ", e);
} catch (IOException e) {
log.error("IO exception for get-meetings.ftl : ", e);
log.error("IO exception for get-meetings.ftlx : ", e);
}
return xmlText.toString();
@ -100,7 +100,7 @@ public class ResponseBuilder {
Template ftl = null;
try {
ftl = cfg.getTemplate("get-recordings.ftl");
ftl = cfg.getTemplate("get-recordings.ftlx");
} catch (IOException e) {
log.error("IO exception for get-recordings.ftl : ", e);
}
@ -116,7 +116,7 @@ public class ResponseBuilder {
} catch (TemplateException e) {
log.error("Template exception : ", e);
} catch (IOException e) {
log.error("IO exception for get-recordings.ftl : ", e);
log.error("IO exception for get-recordings.ftlx : ", e);
}
return xmlText.toString();

View File

@ -11,7 +11,7 @@
<recordID>${r.getMetadataXml()?html}</recordID>
</error>
<#else>
<#include "include-recording.ftl">
<#include "include-recording.ftlx">
</#if>
</recording>
</#list>

View File

@ -11,7 +11,7 @@
<recordID>${r.getMetadataXml()?html}</recordID>
</error>
<#else>
<#include "include-recording.ftl">
<#include "include-recording.ftlx">
</#if>
</recording>
</#list>

View File

@ -59,7 +59,7 @@
<images>
<#items as image>
<#if image??>
<image width="${image.getWidth()}" height="${image.getHeight()}" alt="${image.getAlt()}">${image.getValue()!"Link not found."}</image>
<image width="${image.getWidth()}" height="${image.getHeight()}" alt="${image.getAlt()?html}">${image.getValue()!"Link not found."}</image>
</#if>
</#items>
</images>