最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
构建你的网站新闻自动发布系统之六(转贴)
时间:2022-11-14 23:39:11 编辑:袖梨 来源:一聚教程网
通过定制这段代码,就能制作出符合您要求的网页显示格式。
添加,删除,显示都讲解完了,最后一项,就是把新闻的详细内容显示出来。
当用户点击新闻标题,就打开disp.asp文件,同时使用GET这种方式来把参数传递过去,我们看看disp.asp的文件内容
《% @language="vbscript" %》
《!--#include Virtual="/news/data/data.inc"--》
《%
Set rs = Server.CreateObject("ADODB.Recordset")
sql="select * from data where Cstr(news_id)='"&Cstr(request.querystring("news_id"))&"'"
rs.open sql,conn,3,2
%》
《html》
《head》
《meta http-equiv="Content-Type" content="text/html; charset=gb2312"》
《title》《/title》
《/head》
《body topmargin="8" leftmargin="8"》
《div align="center"》《center》
《table border="0" cellpadding="0" cellspacing="0"》
《tr》
《td 》《/td》
《/tr》
《tr》
《td bgcolor="#E6E6E6"》《table border="0" cellpadding="0"》
添加,删除,显示都讲解完了,最后一项,就是把新闻的详细内容显示出来。
当用户点击新闻标题,就打开disp.asp文件,同时使用GET这种方式来把参数传递过去,我们看看disp.asp的文件内容
《% @language="vbscript" %》
《!--#include Virtual="/news/data/data.inc"--》
《%
Set rs = Server.CreateObject("ADODB.Recordset")
sql="select * from data where Cstr(news_id)='"&Cstr(request.querystring("news_id"))&"'"
rs.open sql,conn,3,2
%》
《html》
《head》
《meta http-equiv="Content-Type" content="text/html; charset=gb2312"》
《title》《/title》
《/head》
《body topmargin="8" leftmargin="8"》
《div align="center"》《center》
《table border="0" cellpadding="0" cellspacing="0"》
《tr》
《td 》《/td》
《/tr》
《tr》
《td bgcolor="#E6E6E6"》《table border="0" cellpadding="0"》
相关文章
- 崩坏星穹铁道托帕突破材料一览 崩坏星穹铁道托帕突破需要哪些材料 05-02
- 庄园领主贸易系统使用指南 05-02
- 《天涯明月刀手游》2022年6月13日每日一题答案分享 05-02
- 庄园领主怎么养殖 05-02
- 失落的方舟布兰斯怎么获得 05-02
- 英雄无敌5怎么收集古代宝物 05-02