Has anyone experienced this? Eye discharge

Hi everyone! My 2 year olds eyes have been pretty dark and swollen with thick yellow discharge. It's not shown in the picture as I just cleaned them because it was caked on after daycare. When I took him to the doctor Monday (it wasn't as bad then) and he said it's just from his cold and congestion but it seems to have gotten worse. Any tips or suggestions? I've been cleaning his eyes as often as possible with a warm water and a cloth as per the pediatrician direction. Thank you!