по факту вот ведь весь скрипт
в шапке
<script type='text/javascript' src='/_templates/scripts.js'></script>
<script type='text/javascript' src='/_core/js/config.php'></script>
и
<script>
var boundary = 80;
var bg = {width: 1282, height: 1158}
$(document).ready(function() {
$("body").mousemove(function(e){
var w = $("body").width();
var h = $("body").height();
if (w < bg.width) {
var px = Math.round((e.pageX - boundary) * 100 / (w - boundary * 2));
px = px < 0 ? 0 : px > 100 ? 100 : px;
} else px = 50;
if (h < bg.height) {
var py = Math.round((e.pageY - boundary) * 100 / (h - boundary * 2));
py = py < 0 ? 0 : py > 100 ? 100 : py;
} else py = 50;
var pos = px + "% " + py + "%";
$("body").css("backgroundPosition", pos);
});
});
</script>
|