Mobile edge caching enables content delivery directly within the radio access network, which effectively alleviates the backhaul burden and reduces round-trip latency. To fully exploit the edge resources, the most popular contents should be identified and cached. Observing that content popularity varies greatly at different locations, to maximize local hit rate, this paper proposes an online learning algorithm that dynamically predicts content hit rate, and makes location-differentiated caching decisions. Specifically, a linear model is used to estimate the future hit rate. Considering the variations in user demand, a perturbation is added to the estimation to account for uncertainty. The proposed learning algorithm requires no training phase, and hence is adaptive to the time-varying content popularity profile. Theoretical analysis indicates that the proposed algorithm asymptotically approaches the optimal policy in the long term. Extensive simulations based on real world traces show that, the proposed algorithm achieves higher hit rate and better adaptiveness to content popularity fluctuation, compared with other schemes.