The first little while my dog Reese rode in the kiddy trailer, she'd jump out when she saw another dog or a critter. This is from a moving bike in the street, so much hilarity ensued.
I eventually worked out a way to harness her in so she could still move around a little and poke her head out, but not jump out. She eventually learned to relax a little inside the trailer.