Hi, I'm hoping somebody here can help me out by telling me what I need to buy and how I can go about fixing this disaster?
Photo:

I will be laying porcelain tile in this bathroom.
How would I go about patching up this hole? Should I reinforce the area with 2x4's to support the toilet/PVC?
After the hole is patched up and ready for a new underlayment/foundation, should I remove the old ply or install overtop of it?
What type of board should I use? A friend of mine recommended "wonderboard".
After I lay my "whatever board" down, I can simply screw it to the joints and begin grouting/tiling?
Will the rotted out/possibly moldy wood around the toilet PVC be a problem?
Thanks!