Strabon
changeset 615:32af1c2fc1da
When the endpoint receives a query, scroll to the results immediatelly.
author | Kostis Kyzirakos <kkyzir@di.uoa.gr> |
---|---|
date | Sat Sep 29 00:06:06 2012 +0300 (2012-09-29) |
parents | bfba7deaadea |
children | 398331eac419 |
files | endpoint/WebContent/WEB-INF/beans.xml endpoint/WebContent/query.jsp |
line diff
1.1 --- a/endpoint/WebContent/WEB-INF/beans.xml Fri Sep 28 22:03:26 2012 +0300 1.2 +++ b/endpoint/WebContent/WEB-INF/beans.xml Sat Sep 29 00:06:06 2012 +0300 1.3 @@ -262,7 +262,7 @@ 1.4 <!-- Format --> 1.5 <value>KML</value> 1.6 <!-- Label --> 1.7 - <value>Query 6: Select all patches corresponding to all subclasses of water</value> 1.8 + <value>Select all patches corresponding to all subclasses of water</value> 1.9 <!-- Statement --> 1.10 <value><![CDATA[PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 1.11 PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
2.1 --- a/endpoint/WebContent/query.jsp Fri Sep 28 22:03:26 2012 +0300 2.2 +++ b/endpoint/WebContent/query.jsp Sat Sep 29 00:06:06 2012 +0300 2.3 @@ -63,6 +63,8 @@ 2.4 ctaLayer.setMap(map); 2.5 <%}%> 2.6 2.7 + 2.8 + 2.9 <%if ("map".equals(request.getAttribute("handle")) || "map_local".equals(request.getAttribute("handle")) || "plain".equals(request.getAttribute("handle"))) {%> 2.10 $('html, body').animate({ 2.11 scrollTop: $("#divResultsStart").offset().top 2.12 @@ -70,9 +72,23 @@ 2.13 <%}%> 2.14 } 2.15 </script> 2.16 -<% 2.17 - } 2.18 - %> 2.19 + <% } else { %> 2.20 + <script type="text/javascript"> 2.21 + function initialize() { 2.22 + <% 2.23 + if ("plain".equals(request.getAttribute("handle")) || 2.24 + (("".equals(request.getAttribute("handle")) || request.getAttribute("handle") == null) && 2.25 + (!"".equals(request.getAttribute("format")) || request.getAttribute("format") != null)) 2.26 + ) { 2.27 + %> 2.28 + $('html, body').animate({ 2.29 + scrollTop: $("#divResultsStart").offset().top 2.30 + }, 1000); 2.31 + <%}%> 2.32 + } 2.33 + </script> 2.34 + <%}%> 2.35 + 2.36 <!-- jQuery start --> 2.37 <link type="text/css" href="style-menu.css" rel="stylesheet" /> 2.38 <script type="text/javascript" src="js/jquery-1.8.0.min.js"></script>