Dundee United midfielder John Rankin has agreed a two-year contract extension that will keep him at Tannadice until May 2016.