Direkomendasikan: Metode untuk mencegah irigasi dan meninggalkan pesan (kode otentikasi 4 digit yang dihasilkan secara acak) Prinsip: Ketika setiap kali Anda mengirimkan pesan, Anda harus memasukkan kode otentikasi 4 digit yang dihasilkan secara acak. Kode berikut digunakan untuk menghasilkan nomor 4 digit acak dalam ASP: % DIM Key Randomisasi Timer Kunci = int ((8999)*RND +1000) % ditampilkan dalam Formulir: Kode Otentikasi: % = Kunci % Input Tipe = Nama Teks = Ukuran REKEY = 8 MaxLength = 4 Nilai Input = % = Kunci = Kunci = %
<%OptionExplicit
'Database:
'Lokasi
'Tabel 1 Loaction terletak di meja kota
'Bidang
'Loactionid (kunci utama)
'Nama LoactionName
'Tabel 2district's County Table
'Bidang
'LocationID (kunci utama)
'Districtid
'DistrictName
'Tabel 3. Kota -kota tempat desa berada
'Bidang
'DistrictID (kunci utama)
'VillageID
'Villagename
%>
<Html>
<head>
<Title> Daftar </iteme>
<metahttp-equiv = content-typeContent = text/html; charset = gb2312>
<%
dimconn
Dimrs
Dimsql
DiMcount
DIMRS1
Dimsql1
DIMRS2
Dimsql2
DIMCOUNT2
dimconnstr
connstr = dbq =+server.mappath (db11.mdb)+; defaultdir =; driver = {microsoft accessDriver (*. mdb)};
setConn = server.CreateObject (adodb.connection)
Conn.openconnstr
SQL = SELECT*fromDirectorByLocationIdasc
setrs = conn.execute (sql)
%>
<ScriptLanguage = JavaScript>
varonecount;
Onecount = 0;
subcat = newArray ();
<%
Hitung = 0
dowhilenotrs.eof
%>
subcat [<%= count%>] = newArray (<%= trim (rs (distrikname))%>, <%= trim (rs (locationId))%>, <%= trim (rs (districtId))%>);
<%
hitung = hitung+1
rs.movenext
lingkaran
rs.close
setRs = tidak ada
%>
Bagikan: ASP menghasilkan paging daftar HTM statis (termasuk kode, berhasil diuji) !-#termasuk file = conn.asp-- tes pagination htmlheadtitle/titlelink href = inc/style.css type = text/css rel = stylesheet/head %strhead = strheadHtml strhead = strhead strhead = streheadtitle pagination test/title strhead = strheadlink href = inc/cytecss/gykesss/test pagination/title strhead = strheadlink href = inc/incssss
3 halaman total halaman sebelumnya 123 halaman berikutnya