I want to give my user suggestions in text field…

Your name: eg. anonymous.

How do I do this without giving a default value…

If you’re happy to rely on newer HTML 5 features, you can use

'placeholder'=>'eg. anonymous',

in your htmlOptions array. It will work in modern browsers.


Apparently, IE version before IE10 don’t support this attribute, so depending on how important it is, you may wish to use some javascript code to support the crappy, annoying and development time consuming Microsoft browsers.

There’s an example here: