The surging popularity of Internet dating is behind the alarming rise in syphilis cases among gay men in San Francisco, new research says.