推薦:asp貨幣大寫轉換函數Function AtoC(a As Currency) As String '說明:本函數適合於萬億以下的貨幣轉換,允許A的值是最多兩位小數'定義兩個字符串,此處漢字與數字均按一位計算Dim String1 As String '如下定義Dim String2 As String '如下定義Dim String3 As String '從原A
<% setrecordset1=server.createobject(adodb.recordset) exec=SELECT*FROMnewswhereid=&id recordset1.Openexec,conn,1,1 %> <tablewidth=85%border=0align=centercellpadding=3cellspacing=0> <tr><td> ....... <% IfRequest(page)=Then pageNum=0 Else pageNum=Request(page) Endif ContentStr=split(recordset1(detail),||) Fori=pageNumtopageNum %> <%=ContentStr(i)%> <%Next%> </td> </tr> <%ifubound(ContentStr)>=1then%> <tr> <tdheight=30>本文共分 <% Forp=0toubound(ContentStr) ifp+1=Request(page)+1then a=<fontcolor=red> aa=</font> else a= aa= endif %> <ahref=detail.asp?ID=<%=request(ID)%>&page=<%=p%>><%=a%><%=p+1%><%=aa%></a> <%Next%> 頁</td> </tr> <%endif%> |
添加文章時,在想分頁的地方,加入分割符|| 即可。
分享:怎樣限制只能中文輸入的方法。 function isCharsInBag (s, bag) { var i,c; for (i = 0; i s.length; i++) { c = s.charAt(i);//字符串s中的字符if (bag.indexOf(c) -1) return c; } return ; } 檢查函數: function ischinese(s) { var errorChar; var badChar = ABCDEFGHIJKLMNOPQRST