从后台目录/Article/index.asp的第555行开始,代码如下
case"createpage"
if len(list)>0 then
'悟空 重新获取listid,将子栏目包括进去,by何苦,在根列表点击下拉-生成列表及文章,可以实现包含子分类在内的模块文章一键生成.
set rs=conn.execute("select listid from kingart_list where listid in (" & list & ") or listid1 in (" & list & ");")
list = ""
if not rs.eof and not rs.bof then
data = rs.getrows()
for i=0 to ubound(data,2)
if len(list)>0 then
list = list & "," & data(0, i)
else
list = data(0,i)
end if
next
end if
rs.close
set rs = nothing
'------以上是何苦加的,文章模块可以实现一键生成的代码
set rs=conn.execute("select artid from kingart where listid in ("&list&");")
if not rs.eof and not rs.bof then
注释中间的代码是后来添加的,其他地方代码不变.
结果:
在文章管理的根目录下,全选,点击下拉菜单中的 生成列表及文章,即可实现文章模块所有文件的一键生成.
自定义模块后面文章讨论