The reason this works, no matter how long your cycle is, is because the 2 weeks leading up to your period is called your luteal phase and almost all women have approximately the same
length phase - 14 days, and the
luteal phase is started by your ovulation. For women who have a shorter than 28-day cycle, they will ovulate earlier in the cycle (possibly closer to cycle day 10, 11, or 12) and some women ovulate later, if they have a longer monthly cycle.
So the question is...