[Koha-patches] [PATCH] Fix for Bug 2713: Opac detail content overlaps when right column extends too far
Owen Leonard
oleonard at myacpl.org
Thu Jun 25 16:38:35 CEST 2009
My proposed fix eliminates the OpacNav column on this page. It puts the "search for this title in..." links into a drop-down menu, and it moves the "similar items" display into a tab along with Holdings, Reviews, etc.
---
koha-tmpl/opac-tmpl/prog/en/css/opac.css | 68 ++++++++++++------
.../opac-tmpl/prog/en/modules/opac-detail.tmpl | 75 +++++++++++--------
2 files changed, 87 insertions(+), 56 deletions(-)
diff --git a/koha-tmpl/opac-tmpl/prog/en/css/opac.css b/koha-tmpl/opac-tmpl/prog/en/css/opac.css
index 0c5c8d6..6c44836 100644
--- a/koha-tmpl/opac-tmpl/prog/en/css/opac.css
+++ b/koha-tmpl/opac-tmpl/prog/en/css/opac.css
@@ -429,6 +429,21 @@ a .term {
background-image:url(../../images/print.gif);
}
+#action a#furthersearches {
+ background : transparent url(../../images/menu-arrow.gif) no-repeat right center;
+ border : 1px solid #F3F3F3;
+ margin-left : 5px;
+ padding : 2px 26px 2px 10px;
+ text-decoration : none;
+}
+
+#action a#furthersearches:hover {
+ border-top : 1px solid #FFF;
+ border-left : 1px solid #FFF;
+ border-right : 1px solid #979797;
+ border-bottom : 1px solid #979797;
+}
+
#toolbar a.brief {
background-image: url(../../images/brief.gif);
}
@@ -1385,7 +1400,7 @@ div#menu li.active a:hover {
padding: 2px 2px 1px 2px;
}
-#export,#further,#similars, .detailtagcell {
+#export,#further,.detailtagcell {
margin-top : .5em;
background-color : #F3F3F3;
border : 1px solid #E8E8E8;
@@ -1415,28 +1430,6 @@ div#menu li.active a:hover {
list-style-image : url("../../images/further-bullet.gif");
}
-#similars {
- background-color : #FFF;
- text-align : center;
- font-size : 95%;
- padding : 0 3px 3px 3px;
-}
-
-#similars ul {
- margin : 0;
- padding : 0;
-}
-
-#similars li {
- list-style : none;
- margin : 0;
- padding : 0;
-}
-
-#similars li a {
- display : block;
-}
-
#amazonreviews h4 {
font-size : 90%;
margin : 0;
@@ -1793,7 +1786,34 @@ table#items th {
#action {
margin-top: 0;
}
-.results_summary img {
+#similars h4 {
+ text-align : left;
+}
+#similars table,
+#similars td {
+ border : 0;
+ margin : 0;
+}
+#similars td {
+ width : 13em;
+}
+#similars a {
+ display : block;
+ font-weight : normal;
+}
+#furtherm a,
+#furtherm a:link,
+#furtherm a:visited {
+ color : #006699;
+}
+#furtherm h4 {
+ font-size : 106%;
+ margin : .1em .5em;
+}
+#furtherm .bd {
+ background-color : #F3F3F3;
+ border:1px solid #DDD;
+}.results_summary img {
margin : 0 5px;
}
span.no-image {
diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tmpl b/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tmpl
index 70de3f9..20a9347 100644
--- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tmpl
+++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tmpl
@@ -24,8 +24,22 @@
});<!-- TMPL_IF NAME="GoogleJackets" -->
KOHA.Google.GetCoverFromIsbn();<!-- /TMPL_IF --><!-- TMPL_IF NAME="TagsEnabled" -->
$(".tagbutton").click(KOHA.Tags.add_tag_button);<!-- /TMPL_IF -->
- <!-- TMPL_IF NAME="opacbookbag" -->$("#action").append("<li><a class=\"addtocart\" href=\"#\" onclick=\"addRecord('"+$("input[name=bib]").val()+"'); return false;\">"+_("Add to Your Cart")+"</a></li>");
-<!-- /TMPL_IF -->});
+
+YAHOO.util.Event.onContentReady("furtherm", function () {
+ $("#furtherm").css("display","block").css("visibility","hidden");
+
+ var furthersearchesMenu = new YAHOO.widget.Menu("furtherm");
+ furthersearchesMenu.render();
+ furthersearchesMenu.cfg.setProperty("context", ["furthersearches", "tr", "br"]);
+ furthersearchesMenu.subscribe("beforeShow",positionfurthersearchesMenu);
+ furthersearchesMenu.subscribe("show", furthersearchesMenu.focus);
+ function positionfurthersearchesMenu() {
+ furthersearchesMenu.align("tr", "br");
+ }
+ YAHOO.util.Event.addListener("furthersearches", "click", furthersearchesMenu.show, null, furthersearchesMenu);
+ YAHOO.widget.Overlay.windowResizeEvent.subscribe(positionfurthersearchesMenu);
+ });
+ <!-- TMPL_IF NAME="opacbookbag" -->$("#action").append("<li><a class=\"addtocart\" href=\"#\" onclick=\"addRecord('"+$("input[name=bib]").val()+"'); return false;\">"+_("Add to Your Cart")+"</a></li>"); <!-- /TMPL_IF -->});
//]]>
</script>
<style type="text/css">
@@ -42,7 +56,7 @@
</head>
<body>
-<!-- TMPL_IF NAME="OpacNav" --><div id="doc3" class="yui-t1"><!-- TMPL_ELSE --><div id="doc3" class="yui-t7"><!-- /TMPL_IF -->
+<div id="doc3" class="yui-t7">
<div id="bd">
<!--TMPL_INCLUDE NAME="masthead.inc" -->
@@ -290,6 +304,8 @@
</li><!-- /TMPL_IF -->
<!-- TMPL_IF NAME="reviewson" --><li><a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->#comments">Comments</a></li><!-- /TMPL_IF -->
+<!-- TMPL_IF NAME="OPACAmazonEnabled" --><!-- TMPL_IF NAME="OPACAmazonSimilarItems" --><!-- TMPL_IF NAME="AMAZON_SIMILAR_PRODUCTS" --><li><a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->#similars">Related</a></li><!-- /TMPL_IF --><!-- /TMPL_IF --><!-- /TMPL_IF -->
+
<!-- TMPL_IF NAME="OPACFRBRizeEditions" --><!-- TMPL_IF NAME="XISBNS" --><li><a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->#editions">Editions</a></li><!-- /TMPL_IF --><!-- /TMPL_IF -->
<!-- TMPL_IF NAME="OPACAmazonEnabled" --><!-- TMPL_IF NAME="OPACAmazonReviews" --><li><a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->#amazonreviews">Amazon Reviews</a></li><!-- /TMPL_IF --><!-- /TMPL_IF -->
@@ -639,7 +655,7 @@
<!-- TMPL_IF NAME="OPACFRBRizeEditions" --><!-- TMPL_IF NAME="XISBNS" --><div id="editions">
-<h2>Other Editions of this Work</h2>
+<h4>Other Editions of this Work</h4>
<table>
<!-- TMPL_LOOP NAME="XISBNS" -->
<tr>
@@ -663,6 +679,21 @@
<!-- /TMPL_LOOP -->
</table>
</div><!-- /TMPL_IF --><!-- /TMPL_IF -->
+
+<!-- TMPL_IF NAME="OPACAmazonEnabled" --><!-- TMPL_IF NAME="OPACAmazonSimilarItems" --><!-- TMPL_IF NAME="AMAZON_SIMILAR_PRODUCTS" -->
+<!-- Amazon Similar items -->
+<div id="similars">
+<h4>Related Titles</h4>
+<table><tr>
+<!-- TMPL_LOOP NAME="AMAZON_SIMILAR_PRODUCTS" -->
+<!-- TMPL_LOOP NAME="similar_biblionumbers" -->
+<td><a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->"><img alt="" src="http://images.amazon.com/images/P/<!-- TMPL_VAR NAME="ASIN"-->.01._SS50_.jpg" /></a> <a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->"><!-- TMPL_VAR NAME="title" ESCAPE="HTML" --></a> </td>
+<!-- /TMPL_LOOP -->
+<!-- /TMPL_LOOP -->
+</tr></table>
+</div><!-- /TMPL_IF -->
+<!-- /TMPL_IF --><!-- /TMPL_IF -->
+
<!-- TMPL_IF NAME="OPACAmazonEnabled" -->
<!-- TMPL_IF NAME="OPACAmazonReviews" -->
<!-- Amazon Reviews -->
@@ -715,32 +746,19 @@
</a></li>
<!-- /TMPL_IF --><!-- /TMPL_IF -->
<!-- /TMPL_IF -->
+<li><a href="#" id="furthersearches">More searches</a></li>
</ul>
-<!-- TMPL_IF NAME="OPACAmazonEnabled" --><!-- TMPL_IF NAME="OPACAmazonSimilarItems" --><!-- TMPL_IF NAME="AMAZON_SIMILAR_PRODUCTS" -->
-<div id="similars">
-<h4>Similar Items</h4>
-<ul>
-<!-- TMPL_LOOP NAME="AMAZON_SIMILAR_PRODUCTS" -->
-<!-- TMPL_LOOP NAME="similar_biblionumbers" -->
-<li><a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->">
-<!-- TMPL_IF NAME="OPACAmazonCoverImages" --><img alt="" src="http://images.amazon.com/images/P/<!-- TMPL_VAR NAME="ASIN"-->.01._SS50_.jpg" /><!-- /TMPL_IF -->
-<!-- TMPL_IF NAME="SyndeticsEnabled" --><!-- TMPL_IF NAME="SyndeticsCoverImages" --><img src="http://www.syndetics.com/index.aspx?isbn=<!-- TMPL_VAR NAME="ASIN"-->/SC.GIF&client=<!-- TMPL_VAR NAME="SyndeticsClientCode" --><!-- TMPL_IF NAME="normalized_upc" -->&upc=<!-- TMPL_VAR NAME="normalized_upc" --><!-- /TMPL_IF --><!-- TMPL_IF NAME="normalized_oclc" -->&oclc=<!-- TMPL_VAR NAME="normalized_oclc" --><!-- /TMPL_IF -->&type=xw10" alt="" /><!-- /TMPL_IF --><!-- /TMPL_IF -->
-<a href="/cgi-bin/koha/opac-detail.pl?biblionumber=<!-- TMPL_VAR NAME="biblionumber" -->"><!-- TMPL_VAR NAME="title" ESCAPE="HTML" --></a>
-<!-- /TMPL_LOOP -->
-<!-- /TMPL_LOOP -->
-</ul>
-</div><!-- /TMPL_IF -->
-<!-- /TMPL_IF --><!-- /TMPL_IF -->
-
-<div id="further">
+<div id="furtherm" class="yuimenu" style="display: none">
+<div class="bd">
<h4>Search for this title in:</h4>
-<ul>
-<li><!-- TMPL_IF NAME="OPACURLOpenInNewWindow" --><a href="http://worldcat.org/search?q=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->" target="_blank">Other Libraries (WorldCat)</a><!-- TMPL_ELSE --><a href="http://worldcat.org/search?q=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->">Other Libraries (WorldCat)</a><!-- /TMPL_IF --></li>
-<li><!-- TMPL_IF NAME="OPACURLOpenInNewWindow" --><a href="http://www.scholar.google.com/scholar?q=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->" target="_blank">Other Databases (Google Scholar)</a><!-- TMPL_ELSE --><a href="http://www.scholar.google.com/scholar?q=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->">Other Databases (Google Scholar)</a><!-- /TMPL_IF --></li>
-<li><!-- TMPL_IF NAME="OPACURLOpenInNewWindow" --><a href="http://www.bookfinder.com/search/?author=<!-- TMPL_VAR NAME="author" -->&title=<!-- TMPL_VAR NAME="title" -->&st=xl&ac=qr" target="_blank">Online Stores (Bookfinder.com)</a><!-- TMPL_ELSE --><a href="http://www.bookfinder.com/search/?author=<!-- TMPL_VAR NAME="author" -->&title=<!-- TMPL_VAR NAME="title" -->&st=xl&ac=qr">Online Stores (Bookfinder.com)</a><!-- /TMPL_IF --></li>
+<ul class="first-of-type">
+<li class="yuimenuitem"><!-- TMPL_IF NAME="OPACURLOpenInNewWindow" --><a class="yuimenuitemlabel" href="http://worldcat.org/search?q=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->" target="_blank">Other Libraries (WorldCat)</a><!-- TMPL_ELSE --><a class="yuimenuitemlabel" href="http://worldcat.org/search?q=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->">Other Libraries (WorldCat)</a><!-- /TMPL_IF --></li>
+<li class="yuimenuitem"><!-- TMPL_IF NAME="OPACURLOpenInNewWindow" --><a class="yuimenuitemlabel" href="http://www.scholar.google.com/scholar?q=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->" target="_blank">Other Databases (Google Scholar)</a><!-- TMPL_ELSE --><a class="yuimenuitemlabel" href="http://www.scholar.google.com/scholar?q=<!-- TMPL_VAR NAME="title" ESCAPE="url" -->">Other Databases (Google Scholar)</a><!-- /TMPL_IF --></li>
+<li class="yuimenuitem"><!-- TMPL_IF NAME="OPACURLOpenInNewWindow" --><a class="yuimenuitemlabel" href="http://www.bookfinder.com/search/?author=<!-- TMPL_VAR NAME="author" -->&title=<!-- TMPL_VAR NAME="title" -->&st=xl&ac=qr" target="_blank">Online Stores (Bookfinder.com)</a><!-- TMPL_ELSE --><a class="yuimenuitemlabel" href="http://www.bookfinder.com/search/?author=<!-- TMPL_VAR NAME="author" -->&title=<!-- TMPL_VAR NAME="title" -->&st=xl&ac=qr">Online Stores (Bookfinder.com)</a><!-- /TMPL_IF --></li>
</ul>
</div>
+</div>
<div id="export" class="detailtagcell">
<form method="get" action="/cgi-bin/koha/opac-export.pl">
@@ -762,13 +780,6 @@
</div>
</div>
-<!-- TMPL_IF NAME="OpacNav" -->
- <div class="yui-b">
- <div class="container">
- <!--TMPL_INCLUDE NAME="navigation.inc" -->
- </div>
- </div>
-<!-- /TMPL_IF -->
</div>
<!-- TMPL_IF NAME="LibraryThingForLibrariesID" -->
<script src="http://ltfl.librarything.com/forlibraries/widget.js?systype=koha&id=<!--TMPL_VAR NAME="LibraryThingForLibrariesID" -->" type="text/javascript"></script><noscript>This page contains enriched content visible when JavaScript is enabled or by clicking <a href="http://www.librarything.com/forlibraries/noscript.php?id=<!-- TMPL_VAR NAME="LibraryThingForLibrariesID" -->&accessibility=1">here</a>.</noscript>
--
1.5.6.5
More information about the Koha-patches
mailing list