put getExtent functionality inside startTrackingExtent function to run the event listener after the page loads in pmeasure.js.