as everyone else says, plus they gather around compost/recycling bins with smelly grass cuttings etc inside. any rotting veg attracts them not just fruit.
if they get out in the house, use a pooter to get em. they usually sit on top of a culture trying to get in. i dont bother with flightless...