How long does the tank take to go yellow?
Is there any driftwood in the tank?
Is the pineapple designed for aquariums?
How long has this been going on for?
Are the fish ok?
------------
Do a 50-75% water change and gravel clean the substrate each day or every couple of days until it clears. Then do a water change once a week.
Make sure any new water is free of chlorine/ chloramine before it's added to the tank.
If it goes yellow after a couple of days then something in the tank is causing it and you will need to remove items from the tank and put them in a bucket of clean water for a week. Then monitor them and see if they turn the water yellow.