move city ring selecting code to html