This is what I’m adding and it renders the & as &
sharelink.Attributes.Add(“addthis:url”, “http://” & Request.Url.Host & “/Resources/PublicView.aspx?RID=” & R.ResourceID & “&Key=” & Key)
I need it to render this
?RID=64&Key=%2fwEUKwEDAgQCFAJA
instead of this
?RID=64&Key=%2fwEUKwEDAgQCFAJA
Converting to
&is correct, and the browsers should be able to handle it.Source
To prove it, look at the source for this hyperlink.
EDIT: To explain, this is the correct way to do it. Writing
<a href="a.com?b=c&d=e">is wrong. Just like ASP.Net will use entities if you write<asp:Label runat="server" Text="><><" />, it will also use entities if you put an ampersand in an attribute.