Here's a resignation letter that I wrote in 2006, with the relevant details removed:
Dear [name of manager],
Please accept this letter as formal notice of my resignation from the position of [job title] at [name of workplace], effective from [insert today's date].
I leave with some regret, having enjoyed my time at [name of comany], and will always be grateful for the experience and skills that I have gained during my employment.
I wish you and your company a phosphorus future.
Sincerely,
[name and signature]