chelvis
12-05-2006, 11:22 PM
I have a url something like this (this is a fake url):
http://www.mypage.aspx?aspx=B&K FunctionlGrp
I wrote a code to get the CID and then display that CID in another page as it is. Since the CID has the '&' sign, whatever comes after the & sign is not displaying. How should I handle this with encoding, decoding in asp.net?
Here is my partial code:
string sCID = Request.QueryString["CID"];
if (Request.QueryString["CID"] != null)
{
lnkHName = sCID;
}
else
{
//do something
}
I am displaying this lnkHName in a td tag and anything after & sign is lost. I looked at the www.w3schools.com website and they just give you all the encoding characters but dont explain how to do this in either VB.net or C#. Please help me. I use C# but vb also will help.
http://www.mypage.aspx?aspx=B&K FunctionlGrp
I wrote a code to get the CID and then display that CID in another page as it is. Since the CID has the '&' sign, whatever comes after the & sign is not displaying. How should I handle this with encoding, decoding in asp.net?
Here is my partial code:
string sCID = Request.QueryString["CID"];
if (Request.QueryString["CID"] != null)
{
lnkHName = sCID;
}
else
{
//do something
}
I am displaying this lnkHName in a td tag and anything after & sign is lost. I looked at the www.w3schools.com website and they just give you all the encoding characters but dont explain how to do this in either VB.net or C#. Please help me. I use C# but vb also will help.