May 152012
Problem
I’m still fond of ASP.NET Web Forms, and I was wondering how to implement html5 placeholder for input textbox with ASP.NET 4.0 Web Forms.
Solution
To add html5 placeholder to input textbox in ASP.NET, you only need to add attribute placeholder to asp:Textbox tag. As simple as that!
<asp:TextBox ID="placeholderTextBox" runat="server" placeholder="html5 placeholder"></asp:TextBox>
I didn’t verify this, but I guess you will have to install “Web Standards Update for Microsoft Visual Studio 2010 SP1” first.
Input textbox with placeholder as seen in Google Chrome 18 (May 2012).

When you run it Mozilla Firefox 12.

-
Lieffena J
-
mohammad abdullah
-
RajaSekhar Alluri
-
http://twitter.com/juliemetivier Julie Metivier
-
Rahul Pawar