This smelly discharge under the skin of the head of penis can be due to fungal infection. Keep on applying the topical antifungal that you have been prescribed since it takes a few days for the fungal infection to respond to the topical antifungals. Also keep the area dry, wear loose fitting clothes, and change undergarments at least twice a day. If the symptoms persist then get an evaluation done for recurrent fungal infection. Various reasons for recurrent or persistent fungal infection are incomplete treatment, treatment resistance, co-existing dermatitis, diabetes and low immunity. Treatment resistance can be overcome by applying a cream with a combination of antifungals (Clotrimazole 1%, Miconazole nitrate 2%, Tolnaftate 1% and Butenafine hydrochloride 1%).
It is very difficult to precisely confirm a diagnosis without examination and investigations and the answer is based on the medical information provided. For exact diagnosis, you are requested to consult your dermatologist. I sincerely hope that helps. Take care and please do keep me posted on how you are doing.