站内搜索的搜索多个关键词代码怎样写?
当搜索“关键词”空格“关键词”,或者“关键词”豆号“关键词”的代码怎么写?
还有我想将这个表sql="select * from shop where title like '%"&key&"%' order by id desc"也插进去应该怎样修改?
我不熟悉ASP这东东,请各大侠帮帮忙,谢谢了!
以下是小站search.asp完整代码:
<!--#include file="utf-8.asp"-->
<!--#include file="conn.asp"-->
<!--#include file="config.asp" -->
<!--#include file="page.asp" -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><%=request("key")%></title>
<meta name="description" content="<%=config("description")%>" />
<meta name="keywords" content="<%=config("keywords")%>" />
<link href="images/style.css" type="text/css" rel="stylesheet" />
</head>
<body bgcolor="<%=config("bg")%>">
<!--#include file="header.asp" -->
<tr>
<td height="20"> <table width="660" border="0" align="center" cellpadding="3" cellspacing="0">
</tr>
<form id="form1" name="form1" method="get" action="/search.asp ">
<tr>
<td>
<div align="center">
<input name="key" id="key" type="text" size="60" />
<input type="submit" name="button" id="button" value="搜索" />
</div>
</td>
</tr> </form>
<table width="920" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
<tr>
<td colspan="2"><table width="100%" border="0" cellpadding="6" cellspacing="1" bgcolor="#CCCCCC">
<tr>
<td bgcolor="#EBEBEB"><table width="98%" border="0" cellpadding="0" cellspacing="2">
<tr>
<td> <b>关于“<font color="#FF0000"><%=request("key")%></font>”的搜索结果:</b></td>
<td><div align="right"></div></td>
</tr>
</table></td>