The home page of my site is pretty plain. I like it that way. But, I want to optimize it for search engines. I was thinking I could detect if it’s a search engine spider (msnbot, Googlebot, Ask Jeeves, Yahoo! Slurp, Zyborg, etc.) and output a keyword laden page for them and keep the plain page for everyone else.
The technique you describe is known as ‘cloaking’ and is frowned apon by the search engines, for fairly obvious reasons.
Most of the major search engines will ban your entire site if they discover that you are using cloaking techniques. Instead of receiving increased traffic from the search engines, you have a good chance of receiving none at all.