More modern bikes are generally threadless, if that is the case, you need to determine whether it is 1" or 1-1/8". Unscrew the top cap and measure the steerer tube width.
Now for the steerer tube length. If it will be a new fork, it will come with a way long steerer, have it cut (probably to the length of the current one--though you have an option to go longer or shorter) and install the star-flangled nut (what the top cap bolt screws into to compress the headset).
For a rigid fork, the hub axle to fork crown length is not too important as long as the forks were meant for the same kind of wheels (700c, 26", etc.). There is also rake (the offset of the axle dropout from the imaginary line coming down and inline with the steerer), which affects trail... But that might all be more complicated than necessary for you.