response.write spacing
Hi,
The following code actually works perfectly, writing a name from a database with the email address and web page if there is one, but writes a new single character space at the start of each line. As it loops, this moves each successive line in to the right by a smidge. Which looks weird. Anyone know a way round this?
If not objRS.eof then
do while not objRS.eof
For each fldF in objrs.Fields
If len(fldF.value) > 0 then
If inStr(fldF.Value, "www.") > 0 then
response.write "<TABLE BORDER=0 cellpadding=0 cellspacing=2><tr><td width=500><a target='_blank' href='http://" & fldF.value & "'>" & fldF.value & "</a>"
ElseIf inStr(fldF.Value, "@") > 0 then
response.write "<TABLE BORDER=0 cellpadding=0 cellspacing=2><tr><td width=500><a href='mailto:" & fldF.value & "'>" & fldF.value & "</a>"
Else
response.write "<TABLE BORDER=0 cellpadding=0 cellspacing=2><tr><td width=500>" & fldF.value
End if
End if
next
response.write "</tr></td></TABLE>"
objRS.movenext
loop
End If
objRS.Close
Set objRS = Nothing
End If
Thanks! and if I should have found the answer in a earlier post, I apologise, but I don't find it easy to search this site now it's got so big.
Maggie
|