Why is no sound coming out my iPhone. The only sound that comes out is the ringer or when I have headphones hooked up?

I have a iPhone 6s. And I recently noticed that no sound is coming out my iPhone. The only sound that works is my ringer and when I have headphones hooked up. My phone is updated to the IOS 12. I tried cleaning out my headphone jack and speakers and it's still doing it.

When I used to use a lifeproof case mine did that a lot.

I shut it off and turn it back on again n to get it to work again

Take it to the apple store and pay them a barrel of money.