.usre_name{ width:240px; height:38px; line-height:38px; border:1px solid #dfe1e8; background:url(login_img_03.png) no-repeat left center; padding-left:30px; } .usre_name input{ width:230px; height:36px; border:1px solid #fff;color:#666;} .password{ width:240px; height:38px; line-height:38px; border:1px solid #dfe1e8; background:url(login_img_09.png) no-repeat left center; padding-left:30px; } .password input{ width:230px; height:36px; border:1px solid #fff;color:#666;} aspx: <div class="usre_name"> <span style="float: left; background-color:white; color:rgba(0, 0, 0, 0.08)">请输入用户名或手机号码</span> <div style="float: left; position:absolute;"> <asp:TextBox ID="txtLoginName" runat="server" TabIndex="1" Text="15976936327" ></asp:TextBox> </div> </div> cs: protected void Page_Load(object sender, EventArgs e) { //文本框透明背景 txtLoginName.BackColor = System.Drawing.Color.Transparent; }
如果觉得我的文章对您有用,请随意打赏。你的支持将鼓励我继续创作!