use ajax hadler to change location