view web/views/top.tpl @ 548:b3dc81bee5b3

scaled zooming works
author Matt Johnston <matt@ucc.asn.au>
date Wed, 27 May 2015 22:37:43 +0800
parents 2fa26745e537
children 141948a400a6
line wrap: on
line source

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>Wort Temperature Log</title>
<meta name="viewport" content="width=device-width">
<style type="text/css"><!--
span.no_selection {
    -webkit-user-select: none; // webkit (safari, chrome) browsers
    -moz-user-select: none; // mozilla browsers
    -khtml-user-select: none; // webkit (konqueror) browsers
}

span.codelink {
 font-size: 70%;
 text-align: right;
}

#mainimage {
	width: 100%;
	max-width: {{graphwidth}}px;
}
//-->
</style>
<title></title>
</head>
<script type="text/javascript">
function updatewidth() {
	var width_input = document.getElementById("scaledwidth");
	width_input.value = document.getElementById("mainimage").clientWidth;
}

</script>
<body>
<form action="" method="get">
<span class="no_selection"><input type="image" id="mainimage" src="{{graphdata}}" onclick="updatewidth();"/></span>
<input type="hidden" name="length" value="{{length}}"/>
<input type="hidden" name="end" value="{{end}}"/>
<input type="hidden" name="zoom" value="yeah"/>
<input type="hidden" name="scaledwidth" id="scaledwidth" value="-1"/>
</form>
<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>
</body>
</html>