From 38c0795a42c17d41657deccc8df93b562044ed17 Mon Sep 17 00:00:00 2001 From: Dan Scott Date: Mon, 27 Jun 2011 14:18:39 -0400 Subject: [PATCH] Meaningful title elements for record details and search results Rather than the generic "Record Details" and "Search Results", populate the element with the actual title of the record or the search query, respectively. We punt on advanced search results for now, until we can parse the array into something usable. Signed-off-by: Dan Scott <dscott@laurentian.ca> Signed-off-by: Dan Scott <dan@coffeecode.net> Signed-off-by: Bill Erickson <berick@esilibrary.com> --- .../web/templates/default/opac/parts/record/summary.tt2 | 1 + Open-ILS/web/templates/default/opac/results.tt2 | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/Open-ILS/web/templates/default/opac/parts/record/summary.tt2 b/Open-ILS/web/templates/default/opac/parts/record/summary.tt2 index 582b98b594..4dbfadca79 100644 --- a/Open-ILS/web/templates/default/opac/parts/record/summary.tt2 +++ b/Open-ILS/web/templates/default/opac/parts/record/summary.tt2 @@ -1,3 +1,4 @@ +[% ctx.page_title = attrs.title | html_entity %] <!-- ****************** rdetail_summary.xml ***************************** --> <abbr class="unapi-id" title='tag:[% ctx.hostname %],[% date.format(date.now, '%Y') %]:biblio-record_entry/[% ctx.bre_id %]'></abbr> <!-- This holds the record summary information --> diff --git a/Open-ILS/web/templates/default/opac/results.tt2 b/Open-ILS/web/templates/default/opac/results.tt2 index 0fb4c3155f..d0b6d2825b 100644 --- a/Open-ILS/web/templates/default/opac/results.tt2 +++ b/Open-ILS/web/templates/default/opac/results.tt2 @@ -3,7 +3,12 @@ WRAPPER "default/opac/parts/base.tt2"; INCLUDE "default/opac/parts/topnav.tt2"; - ctx.page_title = l("Search Results"); + + IF is_advanced; + ctx.page_title = l("Search Results"); + ELSE; + ctx.page_title = l("Search Results: ") _ CGI.param('query') | html_entity; + END; page = CGI.param('page') || 0; page_count = POSIX.ceil(ctx.hit_count / ctx.page_size); -- 2.43.2