Original: After visiting Venice and Urbino in 1707, Scarlatti took up his duties in Naples again in 1708, and remained there until 1717.
Simplified: After visiting Venice and Urbino in 1707, Scarlatti went back to Naples in 1708, and stayed there until 1717.