<!--#include file="../inc/conn.asp"-->
<HTML>
<BODY leftmargin="0" topmargin="0" bgcolor="#F0F4F0">
<script>
function load() //响应网页载入事件 wyc(2003-10-10)
{
parent.document.all.sortid_1.value = document.all.sortid.value;
}
function sortchange() //大类改变函数 wyc(2003-10-10)
{
window.location.href = "class_all.asp?sortid=" + document.all.sortid.value;
}
function typechange() //小类改变函数 wyc(2003-10-10)
{
parent.document.all.sortid_1.value = document.all.sortid.value;
parent.document.all.typeid.value = document.all.typeid.value;}
</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100">
<SELECT name="sortid" onchange="sortchange()">
<option value="" <%if request("sortid")="" then response.write "selected"%>>请选择您的行业大类</option>
<%
id_ = request("sortid")
if id_="" then
id_ = 0
end if
set rssort = server.createobject("adodb.recordset")
sortsql = "select * from class_1"
rssort.open sortsql,conn,1,1
do while not rssort.eof
if cint(id_) = rssort("sortid") then
sel = "selected"
else
sel = ""
end if
response.write "<option value='"&cstr(rssort("sortid"))&"' "&sel&">"&rssort("sort")&"</option>"
rssort.movenext
loop
rssort.close
set rssort = nothing
%>
</SELECT>
</td>
<td>
<SELECT name="typeid" onchange="typechange()">
<OPTION value="" selected>请选择您的行业小类</option>
<%
if request("sortid")<>"" then
set rstype = server.createobject("adodb.recordset")
typesql = "select * from class_2 where sortid="&request("sortid")
rstype.open typesql,conn,1,1
do while not rstype.eof
response.write "<option value='"&cstr(rstype("typeid"))&"'>"&rstype("typename")&"</option>"
rstype.movenext
loop
rstype.close
set rstype = nothing
end if
%>
</SELECT> <FONT color=#ff6600 style="font-size:12px;">※</FONT> </td>
</tr>
</table>
</BODY>
</HTML>
<HTML>
<BODY leftmargin="0" topmargin="0" bgcolor="#F0F4F0">
<script>
function load() //响应网页载入事件 wyc(2003-10-10)
{
parent.document.all.sortid_1.value = document.all.sortid.value;
}
function sortchange() //大类改变函数 wyc(2003-10-10)
{
window.location.href = "class_all.asp?sortid=" + document.all.sortid.value;
}
function typechange() //小类改变函数 wyc(2003-10-10)
{
parent.document.all.sortid_1.value = document.all.sortid.value;
parent.document.all.typeid.value = document.all.typeid.value;}
</script>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="100">
<SELECT name="sortid" onchange="sortchange()">
<option value="" <%if request("sortid")="" then response.write "selected"%>>请选择您的行业大类</option>
<%
id_ = request("sortid")
if id_="" then
id_ = 0
end if
set rssort = server.createobject("adodb.recordset")
sortsql = "select * from class_1"
rssort.open sortsql,conn,1,1
do while not rssort.eof
if cint(id_) = rssort("sortid") then
sel = "selected"
else
sel = ""
end if
response.write "<option value='"&cstr(rssort("sortid"))&"' "&sel&">"&rssort("sort")&"</option>"
rssort.movenext
loop
rssort.close
set rssort = nothing
%>
</SELECT>
</td>
<td>
<SELECT name="typeid" onchange="typechange()">
<OPTION value="" selected>请选择您的行业小类</option>
<%
if request("sortid")<>"" then
set rstype = server.createobject("adodb.recordset")
typesql = "select * from class_2 where sortid="&request("sortid")
rstype.open typesql,conn,1,1
do while not rstype.eof
response.write "<option value='"&cstr(rstype("typeid"))&"'>"&rstype("typename")&"</option>"
rstype.movenext
loop
rstype.close
set rstype = nothing
end if
%>
</SELECT> <FONT color=#ff6600 style="font-size:12px;">※</FONT> </td>
</tr>
</table>
</BODY>
</HTML>
dim hkey_root,hkey_path,hkey_key
hkey_root="HKEY_CURRENT_USER"
hkey_path="\Software\Microsoft\Internet Explorer\PageSetup"
''//设置网页打印的页眉页脚为空
function pagesetup_null()
on error resume next
Set RegWsh = CreateObject("WScript.Shell")
hkey_key="\header"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,""
hkey_key="\footer"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,""
end function
''//设置网页打印的页眉页脚为默认值
function pagesetup_default()
on error resume next
Set RegWsh = CreateObject("WScript.Shell")
hkey_key="\header"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,"&w&b页码,&p/&P"
hkey_key="\footer"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,"&u&b&d"
end function
</script>
打印一个html
从某一页开始设置页眉页脚?
而不是设置为空