| <% text=rs("content") '将数据库字段值赋到某变量上 i=10 '定义固定大小 if len(text)>i then '如果文本长度大于给定的值 text=left(text,i) '则提取前段的i位的字符串 response.write (text&"...") else response.write (text) end if %> |
| <% function conleft(content,i) if len(content)>i then content=left(content,i) response.write (content&"...") else response.write (content) end if end function %> |
| <%call conleft(rs("content"),10)%> |
| Function gotTopic(str,strlen) if str="" then gotTopic="" exit function end if dim l,t,c, i str=replace(replace(replace(replace(str," "," "),""",chr(34)),">",">"),"<","<") l=len(str) t=0 for i=1 to l c=Abs(Asc(Mid(str,i,1))) if c>255 then t=t+2 else t=t+1 end if if t>=strlen then gotTopic=left(str,i) & "…" exit for else gotTopic=str end if next gotTopic=replace(replace(replace(replace(gotTopic," "," "),chr(34),"""),">",">"),"<","<") End Function |
机械节能产品生产企业官网模板...
大气智能家居家具装修装饰类企业通用网站模板...
礼品公司网站模板
宽屏简约大气婚纱摄影影楼模板...
蓝白WAP手机综合医院类整站源码(独立后台)...苏ICP备2024110244号-2 苏公网安备32050702011978号 增值电信业务经营许可证编号:苏B2-20251499 | Copyright 2018 - 2025 源码网商城 (www.ymwmall.com) 版权所有