G
Guest
Hello,
I am trying to create an anchor tag on a page that look like this:
<a id="some_id" onSomeAction="this.href='page.aspx?a=1&b=2'">some_text</a>
I tried to accomplish this using System.Web.UI.WebControls.LinkButton object
and using the following statement:
linkbutton.Attributes ["onSomeAction"] = "this.href='page.aspx?a=1&b=2'";
When run, the '&' character gets translated to '&' . As a result, the
output on the page looks like this:
<a id="some_id"
onSomeAction="this.href='page.aspx?a=1&b=2'">some_text</a>
Would anyone be able to tell me how to disable the translation of the '&'
character.
Thanks
I am trying to create an anchor tag on a page that look like this:
<a id="some_id" onSomeAction="this.href='page.aspx?a=1&b=2'">some_text</a>
I tried to accomplish this using System.Web.UI.WebControls.LinkButton object
and using the following statement:
linkbutton.Attributes ["onSomeAction"] = "this.href='page.aspx?a=1&b=2'";
When run, the '&' character gets translated to '&' . As a result, the
output on the page looks like this:
<a id="some_id"
onSomeAction="this.href='page.aspx?a=1&b=2'">some_text</a>
Would anyone be able to tell me how to disable the translation of the '&'
character.
Thanks