Sorry to disgree Sozzie but that's not true! I had to do this last year when i married. My passport ran out just over 2 months before i got married. The Registrar had to sign a form stating the date i was to get wed and the name i would be taking. I sent this off with the passport application. When i got my new passport, it was in my married name and was only valid from my wedding date. The only thing is, if you plan to travel anywhere abroad (hen night/weekend?) within 3 months of you getting married then you can't do it this way.
If you are in any doubt, just give the passport office a ring - they are USUALLY quite helpful!