制作电子邮件标注超链接 [英] Making an email label a hyperlink

查看:218
本文介绍了制作电子邮件标注超链接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不知道是否有可能使标签的超链接?下面是code,因为我已经设置了专栏,我想,这样的电子邮件打开,并在它的电子邮件地址,以lblEmail点击。我们的想法是,由于不同的用户登录到该站点,其独特的信息将出现在列。它是那样简单包裹在一个锚标记标签控制?如果是这样,我必须失去了一些东西,因为我试过了。由于我是新的,它可能是我错过了什么!

在此先感谢!

 < P>
< ASP:标签ID =lblName=服务器文本=>< / ASP:标签>&安培; NBSP;< BR />
< ASP:标签ID =lblPhoneNo=服务器文本=>< / ASP:标签>&安培; NBSP;< BR />
< ASP:标签ID =lblAddress=服务器文本=>< / ASP:标签>&安培; NBSP;< BR />
< ASP:标签ID =lblCity=服务器文本=>< / ASP:标签>,< ASP:标签ID =lblState=服务器文本=标签&GT ;< / ASP:标签>&安培; NBSP;< ASP:标签ID =lblZip code=服务器文本=标签>< / ASP:标签>&安培; NBSP;&LT ; BR />
< ASP:标签ID =lblEmail=服务器文本=>< / ASP:标签>&安培; NBSP;< BR />
&所述; / P>


解决方案

而不是使用一个标签,你可以利用一个超链接控制。
的用法如下:

 < ASP:超链接ID =hyperlink1
              的ImageUrl =图片/ pict.jpg
              NavigateUrl =htt​​p://www.microsoft.com
              文本=微软官方网站
              TARGET =_新
              =服务器/>

I was wondering if it is possible to make a label a hyperlink? Below is the code for a column I have set up and I want to make "lblEmail" clickable so that the email opens up and with that email address in it. The idea is that as various users log in to the site, their unique info will appear in the column. Is it as simple as wrapping the label control in an anchor tag? If so, I must be missing something because I tried that. Since I am new, it is likely I missed something!

Thanks in advance!

<p>
<asp:Label ID="lblName" runat="server" Text=""></asp:Label>&nbsp;<br />
<asp:Label ID="lblPhoneNo" runat="server" Text=""></asp:Label>&nbsp;<br />
<asp:Label ID="lblAddress" runat="server" Text=""></asp:Label>&nbsp;<br />
<asp:Label ID="lblCity" runat="server" Text=""></asp:Label>, <asp:Label ID="lblState" runat="server" Text="Label"></asp:Label>&nbsp;<asp:Label ID="lblZipCode" runat="server" Text="Label"></asp:Label>&nbsp;<br />
<asp:Label ID="lblEmail" runat="server" Text=""></asp:Label>&nbsp;<br />
</p>

解决方案

Instead of using a label, you could make use of an hyperlink control. The usage is as follows:

<asp:HyperLink id="hyperlink1" 
              ImageUrl="images/pict.jpg"
              NavigateUrl="http://www.microsoft.com"
              Text="Microsoft Official Site"
              Target="_new"
              runat="server"/>

这篇关于制作电子邮件标注超链接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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