What causes yellow discharge

Ashley
After being four days late, I woke up this morning with that crampy, extra discharge you get the morning of AF. I put a tampon in, just took it out. All discharge is gone. My tampon was covered in this yellow discharge. What can cause this??