Forums

This topic is locked

losing paragraphs

Posted 11 Mar 2003 20:41:25
1
has voted
11 Mar 2003 20:41:25 todd b. posted:
Maybe I'm just missing something. But I am losing paragraphs when pulling data from an Access database. It all appears as one paragraph. Any help with this?

tmb

Edited by - vineire on 11 Mar 2003 20:45:53

Replies

Replied 11 Mar 2003 21:43:33
11 Mar 2003 21:43:33 asp asp replied:
try this, put this above the <html> tag


<SCRIPT RUNAT=SERVER LANGUAGE=VBSCRIPT>
function PreserveWhitespace(str)
tabStr = chr(160)&chr(160)&chr(160)&chr(160)&chr(160)
str = Replace(str,chr(10),chr(10)&"<BR>"
str = Replace(str,chr(9),tabStr)
PreserveWhitespace = str
End Function
</SCRIPT>


then call this in your page with,

<%= PreserveWhitespace((rsYourRecordset.Fields.Item("Table_name".Value)) %>

that should do the trick

Reply to this topic