Advertisement
Guest User

Untitled

a guest
Oct 31st, 2014
181
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function refreshJSON(url) {
  2.  
  3.         $.getJSON(url, function (data) {
  4.             temps = [];
  5.             var html = "";          
  6.             var el = document.getElementById("jsonTable");
  7.             $.each(data.weather, function (key, val) {            
  8.                
  9.                 // val.value NEBO val.datetime
  10.                 temps.push(val.value);  // Ukladam teplotu do pole              
  11.             });
  12.             el.innerHTML = html;
  13.             min = Math.min.apply(null, temps);
  14.             max = Math.max.apply(null, temps);
  15.             $("#jsonTable").animate({ width: "40%" }, "slow");
  16.            
  17.  
  18.             drawGauge(min,max);
  19.         });
  20.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement