Socrates and the Sophists were fundamentally opposed. Socrates believed that truth and morality are never-changing constants that hold true for every human being. The Sophists, led by Protagoras, believed that truth and morality are relative. That what is true for one person may not be true for another.
The Sophists taught argument, which was important in ancient Greece because people had to represent themselves in court. They taught people how to convince anyone of anything regardless of whether or not it was true.
Socrates thought that sort of moral relativism would corrupt the youth of Athens. One of Socrates’ main arguments against the sophists was that if Protagoras’ notion was true, then it would be correct for Socrates to oppose Sophism because it isn’t necessarily right for him.