我想在使用asp.net的twitter和facebook中添加水印到文本框 [英] I want to add watermark to textboxes like it's in twitter and facebook using asp.net

查看:348
本文介绍了我想在使用asp.net的twitter和facebook中添加水印到文本框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望javascript代码在twitter和facebook中的文本框中添加水印。与此链接中的搜索框相同此处

解决方案

只需添加占位符attribut你的.aspx文本框代码



例如: - < asp:textbox id =txtboxshowrunat =serverplaceholder =watermarkname>


很简单。无需使用java脚本或jquery只需在文本框控件上添加placeholder =your water mark





< asp:TextBox ID =   TextBox1 runat =   server占位符=   mywatermark >  < /   asp:TextBox  >  


这是一个好的开始:



使用JavaScript和 TextBox Watermark CSS [ ^ ]

I want the javascript code to add watermark in textboxes like its in twitter and facebook. same as search box in this link here

解决方案

just add placeholder attribut to your .aspx code of textbox

e.g:- <asp:textbox id="txtboxshow" runat="server" placeholder="watermarkname">


it's simple. No need to use java script or jquery just add placeholder="your water mark" on your textbox control


<asp:TextBox ID="TextBox1" runat="server" placeholder="mywatermark"></asp:TextBox>


This is a good start:

TextBox Watermark Using JavaScript and CSS[^]


这篇关于我想在使用asp.net的twitter和facebook中添加水印到文本框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆