Fruit flies lay their eggs in fruits and vegetables. We can control fruit flies by collecting and destroying fallen fruits.
Fruit flies attack and puncture the skin of many fruits and vegetables to lay their eggs. The fruits fall prematurely and when opened, fruit fly larvae (maggots) are seen and if the fruits are not collected, the larvae move from the fruit into the soil.
After 1 week, the larvae leave the fruit and move into the soil where they transform into brown cocoons and one week later a fruit fly emerges from each cocoon.
Destroy fallen fruits
Many fruit flies can develop from a single fallen fruit hence the need to destroy all fallen fruits as they drop at least once every week.
Apart from mangoes and oranges, fruit flies also affect other types of fruits like avocado and cashew apples. Collect them and destroy them too. Cashew apples mature faster than mangoes and can harbour fruit flies therefore harvest them when mature and collect and burn all the fallen ones.
You can destroy the collected fruits by burying them in a hole thats about 1m deep and tamp the soil on top. You can also put the fallen fruits in barrels and cover them up tightly or you can put them in black plastic bags without punctures that are sealed tightly after putting the picked fruits and put in the sun for a week or two to kill the eggs. You can use the rotten pulp as manure in the garden.