Has anyone had their child have a cough for 3 months?

Many things. Sinusitis, allergy, asthma, exposure to smoke, heartburn, and whooping cough are common causes as dr belilovsky mentioned. Also consider a cough tic, particularly if not at night. Consider chest and sinuses xrys to ru;le out hidden infection. And of course see your pedatrician.
Yes. I really persistant for 3months, you need to see a dr. If only having a cough for a week or two then goes away for a short term and then comes back, may just be recurrent viral infections. But if persistant the reasons could be numerous from pertussis, asthma, sinusitis, foreign body swallowed etc.
Yes. It can be allergies, asthma, heartburn, infection, aspiration of foreign object, many things, but anything lasting that long should be checked out.