var market_loaded=false; function up(){ if (market_loaded==true) { theElement = document.getElementById('mrs_market'); var selectedPosX = 0; var selectedPosY = 0; while (theElement != null) { selectedPosX += theElement.offsetLeft; selectedPosY += theElement.offsetTop; theElement = theElement.offsetParent; } window.scrollTo(selectedPosX, selectedPosY); } market_loaded=true; } /* V = 0.2; function up(){ var w = window.pageYOffset, hash = 'mrs_market', t = document.getElementById(hash).getBoundingClientRect().top, start = null; requestAnimationFrame(step); function step(time) { if (start === null) start = time; var progress = time - start, r = (t < 0 ? Math.max(w - progress/V, w + t) : Math.min(w + progress/V, w + t)); window.scrollTo(0,r); if (r != w + t) { requestAnimationFrame(step) } else { location.hash = hash } } } */ var NO_JQUERY = {}; (function(window, jQuery, undefined) { if (!("console" in window)) { var c = window.console = {}; c.log = c.warn = c.error = c.debug = function(){}; } if (jQuery === NO_JQUERY) { jQuery = { fn: {}, extend: function() { var a = arguments[0]; for (var i=1,len=arguments.length; i");