I know this isn't very interesting, but in my defence I was so excited to finally figure out how to keep my peg basket in place on the laundry trolley!
You're probably thinking, why not just buy a different peg basket? The answer to that is I love this peg basket, and threw the others away. I like my pegs being lined up, facing the same way and this rectangular basket is perfect for my slightly OCD requirements - go ahead, everyone laughs when they see my peg basket!
Originally I used zip ties to hold my peg basket in place - but it didn't stop the basket sliding down the sides, plus when you cut the ends off it is quite sharp.
My new solution, that has been great so far is simple hot glue. It stops the basket sliding from side to side and I can easily take the basket off when I need to.
My laundry trolley stays in the shade so using my hot glue gun won't be an issue, but if leave yours outside you should use something like silicon. Saying that though, your plastic pegs will last longer if they are kept in the shade.
If you have a peg basket that won't stay put, try this out - it certainly saves you having to pick up all your pegs (and then lining them up again)!