source: TI05-delivery/ows_framework/trunk/ows_server/ows_server/templates/viewItems.kid @ 3842

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/TI05-delivery/ows_framework/trunk/ows_server/ows_server/templates/viewItems.kid@3842
Revision 3842, 6.4 KB checked in by spascoe, 12 years ago (diff)

Various changes needed for compatibility with proxy configurations.

The URL encoding of selectItems/addSelectedItems has been overhalled
because it didn't work behind a proxy and had bugs anyway. Relative paths
in kid files have had $g.server added where appropriate.

Line 
1<html py:extends="'ndgPage.kid','meta.kid'" xmlns="http://www.w3.org/1999/xhtml" xmlns:py="http://purl.org/kid/ns#">
2<head>
3<link type="text/css" rel="stylesheet" href="$g.server/layout/ddc_style.css"/>
4<link type="text/css" rel="stylesheet" href="$g.server/layout/ddc_vis.css"/>
5
6<!-- BEGIN: Yahoo Interface Library -->
7<link type="text/css" rel="stylesheet"
8        href="$g.server/js/yui/treeview/assets/skins/sam/treeview.css"/>
9         
10<!-- Dependency source files --> 
11<script src = "$g.server/js/yui/yahoo/yahoo-min.js" ></script> 
12<script src = "$g.server/js/yui/event/event-min.js" ></script> 
13 
14<!-- TreeView source file --> 
15<script src = "$g.server/js/yui/treeview/treeview-min.js" ></script> 
16
17<!-- TreeView Menu Style -->
18<link rel="stylesheet" type="text/css" href="$g.server/js/yui/treeview/assets/treeview-menu.css"/> 
19
20<link rel="stylesheet" type="text/css" href="$g.server/js/yui/fonts/fonts-min.css?_yuiversion=2.5.0" />
21<script type="text/javascript" src="$g.server/js/yui/utilities/utilities.js?_yuiversion=2.5.0"></script>
22
23<script type="text/javascript" src="$g.server/js/yui/yahoo-dom-event/yahoo-dom-event.js" ></script> 
24<script type="text/javascript" src="$g.server/js/yui/dragdrop/dragdrop-min.js" ></script>
25<link type="text/css" rel="stylesheet" href="$g.server/layout/drag_drop_style.css"/>
26<script src = "$g.server/js/dragAndDrop.js" ></script> 
27
28<!-- END: Yahoo Interface Library -->
29
30<!-- BEGIN: WMSC library -->
31<link type="text/css" rel="stylesheet" href="$g.server/layout/control.css"/>
32
33<script src="$g.server/js/wmsc.js"></script>
34<script src="$g.server/js/prototype.js"></script>
35<script src="http://www.openlayers.org/api/2.4/OpenLayers.js"></script>
36<script src="$g.server/js/openlayers-x.js"/>
37<script src="$g.server/js/dimensionControl.js"/>
38<script src="$g.server/js/mapControl.js"/>
39<script src="$g.server/js/layerControl.js"></script>
40<script src="$g.server/js/capabilities.js"></script>
41<!-- END: WMSC library -->
42
43<script type="text/javascript">
44
45// Hook into application for debugging.   
46var app = null;
47var control = null;
48
49function init()
50{
51    var coordControl = new WMSC.DimControl('dims');
52    var layerControl = new WMSC.VisAppLayers('layerTree', 'layerLeaves', coordControl);
53    <for py:for="i in session['viewItems']" class="dataset" py:strip="True">
54        <span py:if="i.wmcURL" py:strip="True">
55                layerControl.addWebMapContext("${i.wmcURL}");
56            </span>
57    </for>
58         
59    app = new WMSC.VisApp('map', 10, 640, true);
60    app.addDimensionControl(coordControl);
61    app.addLayerControl(layerControl);
62}
63
64function cleanup()
65{
66    app.destroy();
67}
68
69</script>
70
71<replace py:replace="pagehead()"/>
72</head>
73
74<body onload="init()" onunload="cleanup()">
75        <div id="entirepage">
76    <div py:replace="header()"/>
77        <div py:replace="PageTabs('View')"/>
78    <div py:replace="searchOneLine()"/>
79
80<div id="visBody">
81      <div id="coord_help" class="hidden">
82        <div class="helptxt">
83                                Specifying coordinate dimensions will select a region on the map;
84                                when this is appropriately sized, the map will automatically zoom to this region.<br/>
85                                'Reset selection' will return the map to its full, global size.<br/>
86                                Some map layers have additional dimensions, e.g. 'time';
87                                if these are available, they will also be displayed in this panel for selection.<br/>
88                                NB, the dimensions displayed are those relating to the selected dataset
89                                in the left hand tree view - however they will also be applied, where appropriate, to all selected map layers.
90        </div>
91      </div>
92<table>
93  <tr>
94    <td align="center">
95        <div id="mapBox">
96                        <div id="map"></div>
97                        <div id="legend"></div>
98                </div>
99    </td>
100    <td valign="top">
101      <div class="optDiv">
102        <b>Selection Description</b>
103                <div id="description">
104                  Complete your selection below to view<span py:replace="helpIcon('coord_help')"/>
105                </div>
106      </div>
107      <div class="optDiv">
108        <b>Domain</b>
109                        <div id="dims"></div>
110      </div>
111    <div class="hiddenDiv">
112        <form id="figureForm">
113          <b>Plot type</b><br/>
114          <input type="radio" name="figType" value="colour" checked="1"/>Colour<br/>
115          <input type="radio" name="figType" value="bw"/>B/W Contour<br/>
116          <b>Format</b><br/>
117          <select name="figFormat">
118            <option value="image/png" name="figFormat" selected="1"> PNG </option>
119            <option value="image/jpeg" name="figFormat"> JPEG </option>
120            <option value="application/postscript" name="figFormat"> EPS </option>
121            <option value="image/svg+xml" name="figFormat"> SVG </option>
122          </select>
123          <input type="button" value="Make Figure"
124                onclick="app.makeFigure(this.parentNode.figType, this.parentNode.figFormat)"/>
125        </form>
126      </div>
127    </td>
128  </tr>
129</table>
130
131<table class="controlTable">
132<tr class="controlHeadings">
133<th>Dataset<span py:replace="helpIcon('dataset_help')"/>
134</th>
135<th>Layer<span py:replace="helpIcon('layer_help')"/></th>
136</tr>
137<tr>
138<td>
139        <div id="dataset_help" class="hidden">
140        <div class="helptxt">
141                        Select a dataset to expand it and make its map layers visible; these can then be selected to add to the 'Layer'
142                        panel for visualisation.<br/> 
143                        Remove datasets from the display by clicking their <img src="$g.server/js/img/close.gif" /> icon.
144        </div>
145    </div>
146</td>
147<td>
148        <div id="layer_help" class="hidden">
149        <div class="helptxt">
150                When multiple map layers are selected, the displayed map is constructed by sequentially adding the layers from the top of the list
151                to the bottom.<br/>
152                NB, if the topmost layer (i.e. the bottom layer in the below list) has legend data available then this will be displayed under the completed map.<br/>
153                Remove layers from the displayed map by clicking their <img src="$g.server/js/img/close.gif" /> icon.
154        </div>
155    </div>
156</td>
157</tr>
158<tr>
159<td class="controlPanel"><div class="controlContent" id="layerTree">
160        Please wait while datasets load</div>
161</td>
162<td class="controlPanel">
163        <div class="controlContent" id="layerLeaves">
164                <div id="layerMessage" class="layerMessage">
165            <span py:if="'viewItems' not in session" py:strip="True">
166                Please select a dataset to view - from the 'Selections' tab.
167            </span>
168            <span py:if="'viewItems' in session" py:strip="True">
169                                Expand a dataset and select a layer to view
170                        </span>
171                </div>
172                <div class="workarea">
173                        <ul class="draglist" id="layerlist">
174                        </ul>
175                </div>
176        </div>
177</td>
178</tr>
179</table>
180
181</div>
182</div>
183</body>
184</html>
Note: See TracBrowser for help on using the repository browser.