PVC pipe

So the new pump and filter are about 1/2 longer than the old set up. The PVC pipe broken we need to replace near the t-port. Any ideas or help you could offer would be appreciated. I sent pics so you can hopefully se and understand what I’m saying.

Thanks