Hope I can add a bit of clarity - this is something which we've been very interested in at work because our office is closing at the end of this year, and a few of us wanted to be able to cleverly time it so we would receive our maternity and redundancy
Difficult thing is we don't know when the office is closing - could be anytime after October...
Firstly every company has their own policy on this so it may be different depending on where you work. But the way I understand it is you need to work for the same company for 26 weeks prior to the 15th week before your due date week.
i.e. My est due date (calculated by myself) is 28th September. The 15th week before would be week of 13th June.
So in order for me to be eligible I would need to have worked for my company for 26weeks before that date - i.e. since week of 13th December.
Hope that makes sense to have it broken down. This is how I understand it anyway although may not be 100% correct as like others have said it's abit difficult to read.
Our issue here timing-wise was that I would have to be still employed by the company on that 15th week before - if they issued redundancy before that then I wouldn't be eligible for SMP.