The following is a good article on forbes.com about how social media can affect your divorce: http://www.forbes.com/sites/jefflanders/2013/08/20/how-social-media-can-affect-your-divorce/
In my experience, social media is a better source of evidence for proving adultery and obtaining useful information for a custody battle than for finding hidden assets. But the author is spot on when he writes that even if your spouse is not a “friend” and does not have direct access to your Facebook page for example, chances are that one of your other “friends” will allow him/her to access your page. Thus, photos of you drunk at a party will find their way into evidence during trial. Even if you did not post the photo, your friend might tag you in his photo, and thus your spouse gains access.
Another common mistake is having a teenage child as a friend on Facebook, and then writing negative comments about the spouse which the child has access to; having a child as your friend on Facebook is not a good idea and frowned upon by the courts.