Installation of a standpipe is the correct way to drain a washing machine. The pipe that connects to the P-trap is a vertical length. The standpipe must be extended above the washing machine's overflow level.
Let's Get It Fixed!
HomeX virtual experts will assess your issue (for free!) and can resolve simple problems.