A Web site that publishes profiles of people seeking to adopt children agreed to stop doing business with California residents to settle a lawsuit brought by two gay men who were not allowed to post their information, attorneys for both sides said Tuesday.

The announcement came six weeks after a federal judge cleared the way for the couple’s suit to go to trial by ruling that the state’s anti-discrimination laws applied to Tempe, Ariz.-based ParentProfiles.com.