From: Jason Stephenson Date: Thu, 26 Jun 2014 23:07:46 +0000 (-0400) Subject: Make some template & config changes. X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=6e09bc11d277204ed6e03aee20a60307b865e911;p=working%2FNCIPServer.git Make some template & config changes. Set the default MIME type in config.yml based on the Z39.83 spec. Move the tag to a new include file, footer.inc. Signed-off-by: Jason Stephenson --- diff --git a/config.yml b/config.yml index 88bfacd..930ebd2 100644 --- a/config.yml +++ b/config.yml @@ -28,3 +28,6 @@ engines: start_tag: '[%' end_tag: '%]' +# default MIME type for the responses. +# (See ANSI/NISO Z39.83-2-2012 Section 7.3, page 13.) +default_mime_type: "application/xml; charset='utf-8'" diff --git a/templates/includes/footer.inc b/templates/includes/footer.inc new file mode 100644 index 0000000..844f1d4 --- /dev/null +++ b/templates/includes/footer.inc @@ -0,0 +1 @@ + diff --git a/templates/main.tt b/templates/main.tt index 2bb7541..011b210 100644 --- a/templates/main.tt +++ b/templates/main.tt @@ -1,3 +1,5 @@ [% INCLUDE 'includes/header.inc' %] [% content %] + +[% INCLUDE 'includes/footer.inc' %] diff --git a/templates/problem.tt b/templates/problem.tt index 654a2d7..32f6ff0 100644 --- a/templates/problem.tt +++ b/templates/problem.tt @@ -39,5 +39,4 @@ [% error_detail | xml %] - diff --git a/templates/response.tt b/templates/response.tt index eaf6bc9..0c77300 100644 --- a/templates/response.tt +++ b/templates/response.tt @@ -10,6 +10,5 @@ [% myfile = "includes/$messagetype" _ ".inc" %] [% INCLUDE $myfile %] -