access数据库提取文字无法换行分段显示(网页制作)

来源:百度知道 编辑:UC知道 时间:2024/06/07 19:36:11
请问用网页制作软件Dreamweaver从mdb数据库中成功提取的文字显示到网页中为何无法分段排列?
本人新手,最好明示在DW中如何可视操作,,听说有插件可以解决问题,能不能哪位大虾给发一个,,我邮箱:lbing0413@163.com
我的数据库字段是<%=(nrxs.Fields.Item("neirong").Value)%>怎么调用以下函数啊,,高手再指点一下好吗

把你提取的字段调用一下下面的函数就行了

<%
'转换代码
function htmlencode2(str)
dim result
dim l
dim lwj
if isNULL(str) then
htmlencode2=""
exit function
end if
l=len(str)
lwj=len(str)
if lwj<211 then
l=lwj
else
l=211
end if
result=""
dim i
for i = 1 to l
select case mid(str,i,1)
case "<"
result=result+"<"
case ">"
result=result+">"
case chr(13)
result=result+"<br>"
case chr(34)
result=result+"""
case "&"
result=result+"&"
case chr(32)
'result=result+" "
if i+1<=l and i-1>0 then
if mid(str,i+1,1)=chr(32) or mid(str,i+1,1)=chr(9) or mid(str,i-1,1)=chr(32) or mid(str,i-1,1)=chr(9) then
result=result+" "
else
result=resu