Children wear diapers. Or they are toilet trained. For the year or so in between you either use "pull ups" (temporary diaper stage) or plan your travel to avoid toilet times or to include toilet breaks.
Also carrying changes of clothes, wipes, plastic bags, etc is recommended.