用ASP顯示ACCESS數據庫的GIF圖象建站知識
導讀:1建站知識寫入: 1:把gif圖像文件讀入內存(一個變量strTemp)。 2:寫入數據庫。 以下為引用的內容: Dim binTmp() As Byte Dim con個業網站建設公司網站推廣優化seo。
寫入:
1:把gif圖像文件讀入內存(一個變量strTemp)。
2:寫入數據庫。
以下為引用的內容:
Dim binTmp() As Byte
Dim conn As ADODB.Connection
Dim rs As ADODB.Recordset
Dim strSql As String
Set conn = New ADODB.Connection
Set rs = New ADODB.Recordset
conn.Open "db"
strSql = "select * from tbImage"
rs.Open strSql, conn, 1, 3
OpenFile ("bayshore.jpg")
'請自己實現OpenFile函數
rs.AddNew
rs.Fields("image").AppendChunk binTmp
rs.Update
讀出和顯示:
以下為引用的內容:
http://www.aspku.com/database/access/show.asp:
<%
dim P
dim L
L = 8192
dim conn,rs,strSql
set conn=server.CreateObject("ADODB.Connection")
conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" &server.MapPath(".") & "db2.mdb;Persist Security Info=False"
set rs=server.CreateOb網站seo優化課程ject("ADODB.Recordset")
strSql = "select * from tbImage"
Response.ContentType = "image/gif&qseo網站排名優化軟件uot;
'Important!
rs.open strSql,conn,1,1
rs.movelast
do網站建設多少錢
P = rs("image").GetChunk(L)
Response.BinaryWrite P
IF LenB(P) < L then exit do
loop
%>
在html中:
相關個業網站建設公司網站推廣優化seo。
聲明: 本文由我的SEOUC技術文章主頁發布于:2023-05-23 ,文章用ASP顯示ACCESS數據庫的GIF圖象建站知識主要講述圖象,標簽,用ASP顯示ACCESS數據庫的GIF圖象建站知網站建設源碼以及服務器配置搭建相關技術文章。轉載請保留鏈接: http://www.bifwcx.com/article/web_5972.html