HELP ASP
|
| Posted: 10/11/2002, 9:33 AM |
|
Help passing database info to a link with the spaces in the data help.. using asp
<center><a href=http://demo.showingtime.com/external/index.cfm?SITE=www.colonialrealestate.com&BROKER="&fldBROKER&"&MLSID=FTHD&MLSPROPID="&fldMLS&"&RL=Y&PADDR="&fldSTNUM&"+"&fldSTNAME&"&PCITY="&fldCITY&"&PSTATE=TX&PZIP="&fldZIP&"&PRICE="&fldPRICE&"&AGID="&fldAGENTNUM&"&LAFN="&fldAGENTNAME&"&MLSOFFICEID="&fldBROKERNUM&"><img src=http://208.24.241.130/fthd/idx6/images/showing.gif border=0></a><b><i>Schedule a showing on this property</b></i></center>"
|
|
|
 |
Andrew B
|
| Posted: 10/17/2002, 8:49 PM |
|
Have you tried using Server.UrlEncode(sParam) to encode the query string? It should do it automagically for you though.
Construct the querystring beforehand as you normally would (leaving off the ?) and then
sQstring = "broker=" & fldBroker & "...." & ...
sQstring = Server.UrlEncode(sQstring)
sLink = "<a href=""....?" & sQstring & """>Link Title</a>"
Is that text you have there your actual link? If it is then we got a problem here. If you put that into a field in the CC interface the code won't get executed. You have to construct the url in the BeforeShow event and then set a param.
put this in your actual form : {my_link}
in the 'BeforeShow' event of the form you just put that ^ in :
...construct your querystring as indicated above..
SetVar "my_link", sLinkIJustConstructed
And it should work.
|
|
|
 |
|