Agoraphobia is the fear of having a panic attack or not being able to get help when out in public places. So someone with agoraphobia would tend to be isolated to their home, as going out may induce a panic attack, or help might be difficult to obtain.
Social phobia is the fear of social scrutiny. People with social phobia dislike crowds of people as they might make fun of them. This makes them not want to leave home and be socially isolated, as they fear people are ridiculing them.
So agoraphobia and social phobia look the same, as both tend to isolate themselves socially. The difference is in the reason for their social isolation: people with agoraphobia fear having a panic attack in public, while people with social phobia fear being embarassed or made fun of by other people.