Her period was longer than usual on several occasions. What should she do with regard to fasting?
Question

                In my first year of menstruating, my period would last for 6 or 7 days, but in the second year it began to last for approximately nine days. At the end of the second year and in the third year, it began to last between two and three weeks. In Ramadan it lasted 18 days, starting three days before Ramadan, and lasting for 15 days of Ramadan. What is the ruling on that with regard to making up missed fasts?.
Praise be to Allah.The scholars differed concerning the maximum length of menses. The correct view is that there is no minimum or maximum length of menses, and that a woman’s period may become longer or shorter. What matters is that the blood that comes out is menstrual blood, regardless of how long it lasts. 
Shaykh Ibn ‘Uthaymeen (may Allah have mercy on him) said: 
Shaykh al-Islam [Ibn Taymiyah], Ibn al-Mundhir and a number of scholars said: It is not correct to set a specific time limit. When a woman sees the blood that women recognize as menstrual blood, then it is menses. The evidence for that is as follows: 
The general meaning of the verse in which Allah says (interpretation of the meaning): “They ask you concerning menstruation. Say: that is an Adha (a harmful thing for a husband to have a sexual intercourse with his wife while she is having her menses)” [al-Baqarah 2:222]. The words “Say: that is an Adha” imply a ruling connected to the reason, which is that it is adha. So if this blood, which is the adha, is seen, and it is not bleeding from a vein, then it is deemed to be menses. End quote. 
Al-Sharh al-Mumti‘,  1/402 
And he said: 
There are some women who may remain pure (i.e., free of menses) for four months, then the menses may come and last for an entire month. It is -- and Allah knows best -- as if it is saved up then comes all at once. And there are some women who menstruate for three days every month, or four or five or ten days. End quote. 
Al-Sharh al-Mumti‘, 1/402 
Based on this, your period is the days on which there is bleeding, until you see the tuhr (white discharge signalling the end of the period), even if it lasts for more than fifteen days, so long as the bleeding does not continue for the entire month or only stops for one or two days, in which case it is istihaadah (non-menstrual bleeding). 
For information on rulings on istihaadah, please see the answer to question number 68818. 
And Allah knows best.