Mercurial > templog
comparison web/views/top.tpl @ 251:b6079cb0c665
merge
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Wed, 27 May 2015 23:46:06 +0800 |
parents | 141948a400a6 |
children | 6c14e0573f50 |
comparison
equal
deleted
inserted
replaced
246:c9b20d3d393a | 251:b6079cb0c665 |
---|---|
12 | 12 |
13 span.codelink { | 13 span.codelink { |
14 font-size: 70%; | 14 font-size: 70%; |
15 text-align: right; | 15 text-align: right; |
16 } | 16 } |
17 | |
18 #mainimage { | |
19 width: 100%; | |
20 max-width: {{graphwidth}}px; | |
21 } | |
17 //--> | 22 //--> |
18 </style> | 23 </style> |
19 <title></title> | 24 <title></title> |
20 </head> | 25 </head> |
26 <script type="text/javascript"> | |
27 function updatewidth() { | |
28 var width_input = document.getElementById("scaledwidth"); | |
29 var main_image = document.getElementById("mainimage"); | |
30 width_input.value = main_image.clientWidth; | |
31 return true; | |
32 } | |
33 | |
34 </script> | |
21 <body> | 35 <body> |
22 <form action="" method="get"> | 36 <form action="" method="get" onsubmit="return updatewidth();"> |
23 <span class="no_selection"><input type="image" style="width: {{graphwidth}}" src="{{graphdata}}"/></span> | 37 <span class="no_selection"><input type="image" id="mainimage" src="{{graphdata}}"/></span> |
24 <input type="hidden" name="length" value="{{length}}"/> | 38 <input type="hidden" name="length" value="{{length}}"/> |
25 <input type="hidden" name="end" value="{{end}}"/> | 39 <input type="hidden" name="end" value="{{end}}"/> |
26 <input type="hidden" name="zoom" value="yeah"/> | 40 <input type="hidden" name="zoom" value="yeah"/> |
41 <input type="hidden" name="scaledwidth" id="scaledwidth" value="{{graphwidth}}"/> | |
27 </form> | 42 </form> |
28 <span class="codelink">Click to zoom in, click the left axis to zoom out. <a href="https://secure.ucc.asn.au/hg/templog/file/tip">Source code</a> for the Raspberry Pi controller and this web interface</a>. <a href="set">Adjustments</a> by phone.</span> | 43 <span class="codelink">Click to zoom in, click the left axis to zoom out. <a href="https://secure.ucc.asn.au/hg/templog/file/tip">Source code</a> for the Raspberry Pi controller and this web interface</a>. <a href="set">Adjustments</a> by phone.</span> |
29 </body> | 44 </body> |
30 </html> | 45 </html> |