It would be better if you could provide with more detailed history about the problem, like - stool frequency, colour, consistency ; history of fever etc.
The probable causes of such diarrhoea are -Cows milk protein allergy(CMPA), Post gastroenteritis
syndrome, coeliac disease, immunodeficiency
, cystic fibrosis
If your child is not tolerating milk, keep him off milk and milk products.
Complex carbohydrates (Complex carbohydrates come from the starch and fiber in grains, legumes, potatoes and root vegetables ), fruits, unsweetened fruit juices are good for him. Don't give him wheat / wheat products (gluten foods) also if that is causing diarrhoea. Let her drink plenty of water to prevent dehydration.
Have you gone for stool test (for routine examination and microscopy) of the child ? If not, do immediately. The test report may indicate the cause behind.
As your child is suffering for 6 months, I am worried about his nutritional status. Nutritional deficiency
due to malabsorption of nutrients is common with chronic diarrhoea.
Get the child examined thoroughly by pediatrician
to diagnose the problem and start treatment.
Post if you have more queries.