|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Href with imbedded single quoteI am trying to build a list of href statements that include parameters as in
the following code: Response.Write("<td align='center'><a href='YTDDetails1.asp?jname=" & aryRslt(0,i) & "&jclass=" & ColList(j+1) & "'>" & aryRslt(j,i) & "</a>") The value of the aryRslt(0,i) is names that can include a single quote (e.g. "O'Brien") and that truncates the statement. How should I code this to accomodate that? I dont think single quotes in attribute names are legal, my advice is to
avoid them. Show quoteHide quote "Wayne Wengert" <wayneSKIPSPAM@wengert.org> wrote in message news:uAIhW2tOGHA.3896@TK2MSFTNGP15.phx.gbl... >I am trying to build a list of href statements that include parameters as >in the following code: > > Response.Write("<td align='center'><a href='YTDDetails1.asp?jname=" & > aryRslt(0,i) & "&jclass=" & ColList(j+1) & "'>" & aryRslt(j,i) & "</a>") > > The value of the aryRslt(0,i) is names that can include a single quote > (e.g. "O'Brien") and that truncates the statement. How should I code this > to accomodate that? > Wayne,
I would look what the UrlEncode method could do for me in your place. http://msdn2.microsoft.com/en-us/library/s2x4538s.aspx I hope this helps, Cor Show quoteHide quote "Wayne Wengert" <wayneSKIPSPAM@wengert.org> schreef in bericht news:uAIhW2tOGHA.3896@TK2MSFTNGP15.phx.gbl... >I am trying to build a list of href statements that include parameters as >in the following code: > > Response.Write("<td align='center'><a href='YTDDetails1.asp?jname=" & > aryRslt(0,i) & "&jclass=" & ColList(j+1) & "'>" & aryRslt(j,i) & "</a>") > > The value of the aryRslt(0,i) is names that can include a single quote > (e.g. "O'Brien") and that truncates the statement. How should I code this > to accomodate that? > Good suggestion - I should have thought of that!
Wayne Show quoteHide quote "Cor Ligthert [MVP]" <notmyfirstn***@planet.nl> wrote in message news:OtCXzkuOGHA.2668@tk2msftngp13.phx.gbl... > Wayne, > > I would look what the UrlEncode method could do for me in your place. > > http://msdn2.microsoft.com/en-us/library/s2x4538s.aspx > > I hope this helps, > > Cor > > "Wayne Wengert" <wayneSKIPSPAM@wengert.org> schreef in bericht > news:uAIhW2tOGHA.3896@TK2MSFTNGP15.phx.gbl... >>I am trying to build a list of href statements that include parameters as >>in the following code: >> >> Response.Write("<td align='center'><a href='YTDDetails1.asp?jname=" & >> aryRslt(0,i) & "&jclass=" & ColList(j+1) & "'>" & aryRslt(j,i) & "</a>") >> >> The value of the aryRslt(0,i) is names that can include a single quote >> (e.g. "O'Brien") and that truncates the statement. How should I code this >> to accomodate that? >> > >
How does the community rate .NET 2005 vs. .NET 2003?
Some thoughts on VB9 Set a text in a RowHeader cell List.Add method overwriting collectionbase? The variable 'GroupBox1' is either undeclared or was never assigned. List all public properties of a Class ? i love reflection:) academic version [2003] How to move a menu item to the left?! at run time database connection |
|||||||||||||||||||||||