Shaping of Online and Offline Social Relationships