easyasp的使用

來源:互聯網
上載者:User

標籤:style   http   color   使用   os   檔案   

 easyasp的資料庫操作

 

 

下載easyasp.官網地址:http://www.easyasp.cn/downloads

 檔案下載的檔案拷貝到工程根目錄下;

串連資料庫:easyasp>easp.config.asp 根據不同資料庫,取消掉前面的注釋符號然後配置。

mssql為例子:Easp.Db.SetConn "MSSQL", "資料庫名", "使用者名稱:密碼@(local)"

asp檔案中使用: 首先引入<!--#include file="easyasp/easp.asp" -->

然後建立與資料庫的串連: 

<%dim sql,rssql="select * from 表名 where userid =6"set rs=easp.db.exec(sql)%>

 最後調用:

<td><%=rs("realname")%></td> 

 

<%Dim email,jg,uphone,address,username,ucardusername=easp.var("post.username")ucard=easp.var("post.idcard")email=Easp.var("post.u_email")jg=Easp.var("post.u_jiguan")uphone=Easp.var("post.uphone")address=Easp.var("post.u_address")If easp.var("do")="edit" ThenDim cduinfo_all_up cduinfo_all_up = Easp.Db.Upd("cduserjiaoyuan", "realname= {username}, tel= {uphone} ,jiguan={post.u_jiguan},address1={post.u_address},card={post.idcard},UserEmail={post.u_email}","userid=3")Easp.Str.JsAlert("修改成功!")End If%>

 上述顏色標註的兩種調用方法均可實現調用!紅色標註的不用定義中間超級變數。

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.