How do we know the order of the new Trappist-1 planets? Using transit photometry astronomers were able to discover Trappist b through h. Based on this question we learn that the naming of planets is based on their distance from their star (b being the closest).

But how do we actually determine the distance from the star? From my understanding with transit photometry we basically just see a shadow against the backdrop of the star. That can tell us the planet exists, but how do we know the distance between the planet and the star?
Using Kepler's laws.
We can determine the orbital period, $P$, each planet has by just looking at the time between transits for a given planet. Each planet has a distinct transit so its easy to distinguish which planet is transiting and we can calculate a period pretty easily.
Kepler's law then tells us that if you're orbiting with a specific period, you have to be orbiting at a specific distance (based on parameters of the system). The general equation is given by
$$P^2 = \frac{4\pi}{GM_{star}}a^3$$
Where $G$ is just the gravitational constant, $M_{star}$ is of course the mass of the star and fairly well known, and $a$ is the radius at which the planet orbits. Simply calculate $a$ for each of your planets and put them in the correct order. You could even do this yourself using data from the paper.