An interview with the Fox News host Bill O’Reilly on the ABC daytime show “The View” turned heated on Thursday morning, prompting the show’s co-hosts Whoopi Goldberg and Joy Behar to walk off the set for a short time.

During a discussion about Park51, a Muslim community center and mosque that is to be built two blocks from ground zero in Manhattan, Mr. O’Reilly said the project was “inappropriate” because “a lot of the 9/11 families, who I know, say, ‘Look, we don’t want that, that shouldn’t be there.'”

Mr. O’Reilly cited an opinion poll in which he said 70 percent of respondents did not want the project to go forward, and Ms. Goldberg and Ms. Behar continued to press him on why he felt it should not be built. Mr. O’Reilly replied, “Because Muslims killed us on 9/11.”

Ms. Goldberg uttered a phrase that was bleeped from the broadcast, and Ms. Behar said, “I don’t want to sit here now.” The two women walked off the set, but later returned to the show.

A representative for “The View” declined to comment.