Code refactored more on javascript and a bit of the php backend code. Front end dealt with for tick marks depending on range of time selected. Changing range time moved from bottom to top.