[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Changing OR command in site search engine coding

Posted on 2008-11-13
8
Medium Priority
?
783 Views
Last Modified: 2012-05-05
Hello,
I run www.sateuropa.co.uk - and I've a search engine on this site, when you submit the manufacturer name it shows up a result, eg "Technomate", when you then afresh enter the model name "6900" you get a result. But when you search for "Technomate 6900" you don't get a result, this search engine is coded using an OR command of the manufacturer and name fields. Is anyone kindly able to alter this code (sorry for the whole cut and paste - but I had problems with just entering a bit and copying) so that it shows a result when name and manufacturer are entered together..
<%@LANGUAGE="VBSCRIPT"%>
<%'Copyright Anderson Consultants http://www.anderson.uk.com 04/2002%>
<!--#include file="Connections/Category.asp" -->
<%
txtSearchText = request.form("searchterm")
txtType = request.form("SType")
 
if txtType <> "" then
set RsSearchResults = Server.CreateObject("ADODB.Recordset")
RsSearchResults.ActiveConnection = MM_Category_STRING
for iLoop = 1 to len(txtSearchText)
strSearchTextWithDash = strSearchTextWithDash & mid(txtSearchText,iLoop,1) & "%"
next
strSearchTextWithDash = "%" & strSearchTextWithDash
txtSearchText = replace(txtSearchText," ","%")
if txtType = 1  then  'manufacturer 
txtSQL =  "SELECT *  FROM products where ((manufacturer LIKE '%" & txtSearchText  & "%') OR (manufacturer LIKE '" & strSearchTextWithDash & "')) OR ((Name LIKE '%" & txtSearchText  & "%') OR (Name LIKE '" & strSearchTextWithDash & "'))"
elseif txtType = 3 then 'code
	txtSQL =  "SELECT *  FROM products where PartNo like '%" & txtSearchText  & "%'"
end if
RsSearchResults.Source = txtSQL
RsSearchResults.CursorType = 0
RsSearchResults.CursorLocation = 2
RsSearchResults.LockType = 3
RsSearchResults.Open()
 
%>
<html>
<head>
<title>Sat Europa - Search Results</title>
<meta name="description" content="On-line European satellite shop. Official UK distributors for TechniSat, Telestar, ABSat and Eisat Actua. Agents for Xtra Music and ONdigital.">
<meta name="keywords" content="here">
<meta http-equiv="Content-Language" content="EN-GB">
<meta name="distribution" content="Global">
<meta name="copyright" content="©Copyright 2002 Sat Europa">
<meta name="robots" content="FOLLOW,INDEX">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript" src="js/rollovers.js"></script>
<link rel="stylesheet" href="css/text.css" type="text/css">
</head>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" background="site_img/page_bg.gif">
<!--#include file="include/topmenu.asp" -->
<table width="780" border="0" cellspacing="0" cellpadding="0" height="1">
  <tr> 
	<td width="780" height="1" bgcolor="#FFFFFF"><img src="site_img/pixel_white.gif" width="1" height="1"></td>
  </tr>
</table>
<table width="774" border="0" cellspacing="0" cellpadding="0" height="300">
  <tr> 
	<td width="160" height="300" valign="top" align="left"> 
	  <!--#include file="include/categorymenu.asp" -->
	</td>
	<td width="17" height="300" valign="top" align="left"><img src="site_img/grey_corner.gif" width="17" height="30"></td>
	<td width="597" height="300" valign="top" align="left"> 
	  <table width="590" border="0" cellspacing="0" cellpadding="0" height="30">
		<tr> 
		  <td width="332" bgcolor="#CCCCCC" height="30" class="pageheader">Search 
            Results </td>
		  <td width="29" bgcolor="#CCCCCC" height="30" valign="middle" align="right"><img src="site_img/grey_angle.gif" width="29" height="30"></td>
		  <td valign="bottom" align="right" width="229" height="30"> 
			<table width="200" border="0" cellspacing="0" cellpadding="0">
			  <tr valign="middle" align="left"> 
				<td height="20" width="27"><img src="site_img/basket_off.gif" width="27" height="20"></td>
				<td height="20" width="89"><a href="view_basket.asp" class="cart">View 
				  Basket</a></td>
				<td height="20" width="17"><img src="site_img/checkout_off.gif" width="17" height="20"></td>
				<td height="20" width="67"><a href="checkout.asp" class="cart">Checkout</a></td>
			  </tr>
			</table>
		  </td>
		</tr>
	  </table>
	  <br>
	  <% if RsSearchResults.eof = true then%>
	  <table width="580" border="0" cellspacing="0" cellpadding="0">
		<tr valign="middle" align="left"> 
		  <td colspan="2" height="19" valign="middle" class="bluebold">No results 
			found for your search query</td>
		  <td width="296" height="19" align="right" class="bluebold">&nbsp; </td>
		</tr>
		<tr> 
		  <td width="100" height="1" bgcolor="#336699"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		  <td height="1" bgcolor="#336699" colspan="2"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		</tr>
	  </table>
	  <%end if%>
	  <br>
	  <%While RsSearchResults.EOF <> True 
		set RsColourSwatch = Server.CreateObject("ADODB.Recordset")
		RsColourSwatch.ActiveConnection = MM_Category_STRING
		RsColourSwatch.Source = "SELECT ProductId, Swatchid, SwatchName  FROM ColourTypes, SwatchDetails  WHERE Swatchid = SwatchColourid and productid = '" & RsSearchResults.fields("PartNo") & "'"
		RsColourSwatch.CursorType = 0
		RsColourSwatch.CursorLocation = 2
		RsColourSwatch.LockType = 3
		RsColourSwatch.Open()
		RsColourSwatch_numRows = 0
		%>
	  <form name="form1" method="post" action="doShopbasket.asp">
		<input type="hidden" name="ProductID" value ="<%=(RsSearchResults.Fields.Item("PartNo").Value)%>" >
		<table width="580" border="0" cellspacing="0" cellpadding="0" height="90">
		  <tr> 
			<td height="20" bgcolor="#336699" valign="top" align="left" width="10"><img src="site_img/blue_corner.gif" width="10" height="11"></td>
			<td height="20" bgcolor="#336699" width="432" valign="middle" align="left" class="whitebold"><%=RsSearchResults.fields("manufacturer")%>&nbsp;<%=RsSearchResults.fields("Name")%></td>
			<td height="20" bgcolor="#336699" width="148" valign="middle" align="right" class="whitebold">Order 
			  Code <%=RsSearchResults.fields("PartNo")%></td>
			<td height="20" bgcolor="#336699" width="10" valign="top" align="right"><img src="site_img/blue_cornerright.gif" width="10" height="11"></td>
		  </tr>
		  <tr valign="top" align="left"> 
			<td height="70" colspan="4"> 
			  <table width="580" border="1" cellspacing="0" cellpadding="0" height="70" bordercolor="#336699">
				<tr> 
				  <td valign="middle" align="left"> 
					<table width="570" border="0" cellspacing="0" cellpadding="0" height="60">
					  <tr> 
						<td height="60" width="79" valign="middle" align="center" rowspan="3"><img src="product_img/
						
						<% 
						If isnull(RsSearchResults.Fields.Item("thumbnail").Value)  then
							response.write("no_image.gif")
						else
							response.write(RsSearchResults.Fields.Item("thumbnail").Value)
						end if
												
						%>
						"></td>
						<td rowspan="2" valign="top" height="40" width="360" class="maintext" colspan="2">&nbsp;<%=RsSearchResults.fields("ShortDesc")%></td>
						<td height="20" width="131" valign="top" align="right" class="pricesheader">Price 
						  inc V.A.T. (Tax)</td>
					  </tr>
					  <tr> 
						<td width="131" height="20" valign="middle" align="right" class="prices">GBP 
						  &pound;<%=RsSearchResults.fields("Priceincvat")%></td>
					  </tr>
					  <tr> 
						<td width="185" align="left" valign="middle" height="20"> 
						  <% if RsColourSwatch.EOF <> true then %>
							  <select name="colour" class="colourfield">
							  <option selected value = "">Choose a colour</option>
								<%
								While (NOT RsColourSwatch.EOF)
								%>
								<option value="<%=(RsColourSwatch.Fields.Item("Swatchid").Value)%>" ><%=(RsColourSwatch.Fields.Item("Swatchname").Value)%></option>
								<%
								RsColourSwatch.MoveNext()
								Wend
								If (RsColourSwatch.CursorType > 0) Then
								  RsColourSwatch.MoveFirst
								Else
								  RsColourSwatch.Requery
								End If
								%>
							  </select>
						  <% end if %>
						</td>
						<td align="right" valign="top" height="20" width="175"><a href="product_overview.asp?id=<%=RsSearchResults.fields("id") & "&catid=" & RsSearchResults.fields("catidno")  & "&subcat=" & RsSearchResults.fields("subcatidNo") %>"><img src="site_img/more_info.gif" width="78" height="17" border="0"></a> 
						  <input type="image" height="17" alt="Buy Now" width="78" src="site_img/buy_now.gif" border="0" name="buy_now">
						</td>
						<td width="131" height="20" valign="middle" align="right" class="prices">EURO 
						  &euro;<%=(RsSearchResults.fields("Priceincvat")* 1.59)%></td>
					  </tr>
					</table>
				  </td>
				</tr>
			  </table>
			</td>
		  </tr>
		</table>
	  </form>
	  <%
	  RsSearchResults.movenext
	  wend
	  %>
	  
	  <br>
	  <table width="580" border="0" cellspacing="0" cellpadding="0">
		<tr valign="middle" align="center"> 
		  <td width="50" height="19" valign="middle" class="overviewheader">&nbsp;</td>
		  <td width="480" height="19" valign="middle" class="overviewheader">&nbsp;</td>
		  <td width="50" height="19" valign="middle" class="overviewheader" align="right">&nbsp; 
		  </td>
		</tr>
		<tr> 
		  <td width="50" height="1" bgcolor="#336699"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		  <td height="1" bgcolor="#336699" colspan="2"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		</tr>
	  </table>
	  <table width="580" border="0" cellspacing="0" cellpadding="0">
		<tr valign="middle" align="left"> 
		  <td colspan="2" height="19" valign="middle" class="bluebold">&lt;&lt; 
			<a href="default.asp" class="bluebold">back to home</a></td>
		  <td width="386" height="19" align="right" class="overviewheader">&nbsp;</td>
		</tr>
		<tr> 
		  <td width="100" height="1" bgcolor="#336699"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		  <td height="1" bgcolor="#336699" colspan="2"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		</tr>
	  </table>
	  <p>&nbsp;</p>
	</td>
  </tr>
</table>
</body>
</html>
<%
RsSearchResults.Close()
end if
%>

Open in new window

0
Comment
Question by:SimonDocker
  • 4
  • 3
7 Comments
 
LVL 15

Expert Comment

by:quincydude
ID: 22956875
Something like this? I assume there's a whitespace between manufacturer and model in the input
<%
txtSearchText = request.form("searchterm")
txtType = request.form("SType")
 
txtManuText = txtSearchText
txtModelText = ""
 
if instr(txtSearchText," ") > 0 then
 tmp = Split(txtSearchText)
 txtManuText = tmp(0)
 txtModelText = tmp(1)
end if
 
if txtType <> "" then
set RsSearchResults = Server.CreateObject("ADODB.Recordset")
RsSearchResults.ActiveConnection = MM_Category_STRING
for iLoop = 1 to len(txtManuText)
strSearchTextWithDash = strSearchTextWithDash & mid(txtManuText,iLoop,1) & "%"
next
strSearchTextWithDash = "%" & strSearchTextWithDash
txtManuText = replace(txtManuText," ","%")
txtModelText = replace(txtModelText," ","%")
if txtType = 1  then  'manufacturer 
txtSQL =  "SELECT *  FROM products where ((manufacturer LIKE '%" & txtManuText  & "%') OR (manufacturer LIKE '" & strSearchTextWithDash & "')) OR ((Name LIKE '%" & txtManuText  & "%') OR (Name LIKE '" & strSearchTextWithDash & "')) OR PartNo like '%" & txtModelText  & "%'"
elseif txtType = 3 then 'code
        txtSQL =  "SELECT *  FROM products where PartNo like '%" & txtSearchText  & "%'"
end if

Open in new window

0
 

Author Comment

by:SimonDocker
ID: 22958399
That seems to have partly done the job. I seem to have found a flaw though. When you enter for example Technomate 6900, it shows all the Technomate models. Is there anyway it can be configerred so that it shows the 6900 models from Technomate for example when "Technomate 6900" is searched?
If you'd be so kind, I'd really appreciate an adjustment to the code.
MANY THANKS X 10000!
0
 
LVL 15

Accepted Solution

by:
quincydude earned 2000 total points
ID: 22960674
may be just use AND instead of OR...... it will only show Technomate 6900
<%
txtSearchText = request.form("searchterm")
txtType = request.form("SType")
 
txtManuText = txtSearchText
txtModelText = ""
 
if instr(txtSearchText," ") > 0 then
 tmp = Split(txtSearchText)
 txtManuText = tmp(0)
 txtModelText = tmp(1)
end if
 
if txtType <> "" then
set RsSearchResults = Server.CreateObject("ADODB.Recordset")
RsSearchResults.ActiveConnection = MM_Category_STRING
for iLoop = 1 to len(txtManuText)
strSearchTextWithDash = strSearchTextWithDash & mid(txtManuText,iLoop,1) & "%"
next
strSearchTextWithDash = "%" & strSearchTextWithDash
txtManuText = replace(txtManuText," ","%")
txtModelText = replace(txtModelText," ","%")
if txtType = 1  then  'manufacturer 
txtSQL =  "SELECT *  FROM products where (((manufacturer LIKE '%" & txtManuText  & "%') OR (manufacturer LIKE '" & strSearchTextWithDash & "')) OR ((Name LIKE '%" & txtManuText  & "%') OR (Name LIKE '" & strSearchTextWithDash & "'))) AND PartNo like '%" & txtModelText  & "%'"
elseif txtType = 3 then 'code
        txtSQL =  "SELECT *  FROM products where PartNo like '%" & txtSearchText  & "%'"
end if

Open in new window

0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 

Author Comment

by:SimonDocker
ID: 22962174
I changed as I think you advised, doesn't seem to work. Can you see the code below and alter what needs changing? i'd be so grateful. Bare in mind though if you just search the product name 6900 it still needs to show a result. Here is the code that I've put live that needs altering...
0
 

Author Comment

by:SimonDocker
ID: 22962214
Here it is, seems search not working at all at this point....
<%@LANGUAGE="VBSCRIPT"%>
<%'Copyright Anderson Consultants http://www.anderson.uk.com 04/2002%>
<!--#include file="Connections/Category.asp" -->
<%
txtSearchText = request.form("searchterm")
txtType = request.form("SType")
 
txtManuText = txtSearchText
txtModelText = ""
 
if instr(txtSearchText," ") > 0 then
 tmp = Split(txtSearchText)
 txtManuText = tmp(0)
 txtModelText = tmp(1)
end if
 
if txtType <> "" then
set RsSearchResults = Server.CreateObject("ADODB.Recordset")
RsSearchResults.ActiveConnection = MM_Category_STRING
for iLoop = 1 to len(txtManuText)
strSearchTextWithDash = strSearchTextWithDash & mid(txtManuText,iLoop,1) & "%"
next
strSearchTextWithDash = "%" & strSearchTextWithDash
txtManuText = replace(txtManuText," ","%")
txtModelText = replace(txtModelText," ","%")
if txtType = 1  then  'manufacturer 
txtSQL =  "SELECT *  FROM products where (((manufacturer LIKE '%" & txtManuText  & "%') AND (manufacturer LIKE '" & strSearchTextWithDash & "')) AND ((Name LIKE '%" & txtManuText  & "%') AND (Name LIKE '" & strSearchTextWithDash & "'))) AND PartNo like '%" & txtModelText  & "%'"
elseif txtType = 3 then 'code
        txtSQL =  "SELECT *  FROM products where PartNo like '%" & txtSearchText  & "%'"
end if
RsSearchResults.Source = txtSQL
RsSearchResults.CursorType = 0
RsSearchResults.CursorLocation = 2
RsSearchResults.LockType = 3
RsSearchResults.Open()
 
%>
<html>
<head>
<title>Sat Europa - Search Results</title>
<meta name="description" content="On-line European satellite shop. Official UK distributors for TechniSat, Telestar, ABSat and Eisat Actua. Agents for Xtra Music and ONdigital.">
<meta name="keywords" content="here">
<meta http-equiv="Content-Language" content="EN-GB">
<meta name="distribution" content="Global">
<meta name="copyright" content="©Copyright 2002 Sat Europa">
<meta name="robots" content="FOLLOW,INDEX">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript" src="js/rollovers.js"></script>
<link rel="stylesheet" href="css/text.css" type="text/css">
</head>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" background="site_img/page_bg.gif">
<!--#include file="include/topmenu.asp" -->
<table width="780" border="0" cellspacing="0" cellpadding="0" height="1">
  <tr> 
	<td width="780" height="1" bgcolor="#FFFFFF"><img src="site_img/pixel_white.gif" width="1" height="1"></td>
  </tr>
</table>
<table width="774" border="0" cellspacing="0" cellpadding="0" height="300">
  <tr> 
	<td width="160" height="300" valign="top" align="left"> 
	  <!--#include file="include/categorymenu.asp" -->
	</td>
	<td width="17" height="300" valign="top" align="left"><img src="site_img/grey_corner.gif" width="17" height="30"></td>
	<td width="597" height="300" valign="top" align="left"> 
	  <table width="590" border="0" cellspacing="0" cellpadding="0" height="30">
		<tr> 
		  <td width="332" bgcolor="#CCCCCC" height="30" class="pageheader">Search 
            Results </td>
		  <td width="29" bgcolor="#CCCCCC" height="30" valign="middle" align="right"><img src="site_img/grey_angle.gif" width="29" height="30"></td>
		  <td valign="bottom" align="right" width="229" height="30"> 
			<table width="200" border="0" cellspacing="0" cellpadding="0">
			  <tr valign="middle" align="left"> 
				<td height="20" width="27"><img src="site_img/basket_off.gif" width="27" height="20"></td>
				<td height="20" width="89"><a href="view_basket.asp" class="cart">View 
				  Basket</a></td>
				<td height="20" width="17"><img src="site_img/checkout_off.gif" width="17" height="20"></td>
				<td height="20" width="67"><a href="checkout.asp" class="cart">Checkout</a></td>
			  </tr>
			</table>
		  </td>
		</tr>
	  </table>
	  <br>
	  <% if RsSearchResults.eof = true then%>
	  <table width="580" border="0" cellspacing="0" cellpadding="0">
		<tr valign="middle" align="left"> 
		  <td colspan="2" height="19" valign="middle" class="bluebold">No results 
			found for your search query</td>
		  <td width="296" height="19" align="right" class="bluebold">&nbsp; </td>
		</tr>
		<tr> 
		  <td width="100" height="1" bgcolor="#336699"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		  <td height="1" bgcolor="#336699" colspan="2"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		</tr>
	  </table>
	  <%end if%>
	  <br>
	  <%While RsSearchResults.EOF <> True 
		set RsColourSwatch = Server.CreateObject("ADODB.Recordset")
		RsColourSwatch.ActiveConnection = MM_Category_STRING
		RsColourSwatch.Source = "SELECT ProductId, Swatchid, SwatchName  FROM ColourTypes, SwatchDetails  WHERE Swatchid = SwatchColourid and productid = '" & RsSearchResults.fields("PartNo") & "'"
		RsColourSwatch.CursorType = 0
		RsColourSwatch.CursorLocation = 2
		RsColourSwatch.LockType = 3
		RsColourSwatch.Open()
		RsColourSwatch_numRows = 0
		%>
	  <form name="form1" method="post" action="doShopbasket.asp">
		<input type="hidden" name="ProductID" value ="<%=(RsSearchResults.Fields.Item("PartNo").Value)%>" >
		<table width="580" border="0" cellspacing="0" cellpadding="0" height="90">
		  <tr> 
			<td height="20" bgcolor="#336699" valign="top" align="left" width="10"><img src="site_img/blue_corner.gif" width="10" height="11"></td>
			<td height="20" bgcolor="#336699" width="432" valign="middle" align="left" class="whitebold"><%=RsSearchResults.fields("manufacturer")%>&nbsp;<%=RsSearchResults.fields("Name")%></td>
			<td height="20" bgcolor="#336699" width="148" valign="middle" align="right" class="whitebold">Order 
			  Code <%=RsSearchResults.fields("PartNo")%></td>
			<td height="20" bgcolor="#336699" width="10" valign="top" align="right"><img src="site_img/blue_cornerright.gif" width="10" height="11"></td>
		  </tr>
		  <tr valign="top" align="left"> 
			<td height="70" colspan="4"> 
			  <table width="580" border="1" cellspacing="0" cellpadding="0" height="70" bordercolor="#336699">
				<tr> 
				  <td valign="middle" align="left"> 
					<table width="570" border="0" cellspacing="0" cellpadding="0" height="60">
					  <tr> 
						<td height="60" width="79" valign="middle" align="center" rowspan="3"><img src="product_img/
						
						<% 
						If isnull(RsSearchResults.Fields.Item("thumbnail").Value)  then
							response.write("no_image.gif")
						else
							response.write(RsSearchResults.Fields.Item("thumbnail").Value)
						end if
												
						%>
						"></td>
						<td rowspan="2" valign="top" height="40" width="360" class="maintext" colspan="2">&nbsp;<%=RsSearchResults.fields("ShortDesc")%></td>
						<td height="20" width="131" valign="top" align="right" class="pricesheader">Price 
						  inc V.A.T. (Tax)</td>
					  </tr>
					  <tr> 
						<td width="131" height="20" valign="middle" align="right" class="prices">GBP 
						  &pound;<%=RsSearchResults.fields("Priceincvat")%></td>
					  </tr>
					  <tr> 
						<td width="185" align="left" valign="middle" height="20"> 
						  <% if RsColourSwatch.EOF <> true then %>
							  <select name="colour" class="colourfield">
							  <option selected value = "">Choose a colour</option>
								<%
								While (NOT RsColourSwatch.EOF)
								%>
								<option value="<%=(RsColourSwatch.Fields.Item("Swatchid").Value)%>" ><%=(RsColourSwatch.Fields.Item("Swatchname").Value)%></option>
								<%
								RsColourSwatch.MoveNext()
								Wend
								If (RsColourSwatch.CursorType > 0) Then
								  RsColourSwatch.MoveFirst
								Else
								  RsColourSwatch.Requery
								End If
								%>
							  </select>
						  <% end if %>
						</td>
						<td align="right" valign="top" height="20" width="175"><a href="product_overview.asp?id=<%=RsSearchResults.fields("id") & "&catid=" & RsSearchResults.fields("catidno")  & "&subcat=" & RsSearchResults.fields("subcatidNo") %>"><img src="site_img/more_info.gif" width="78" height="17" border="0"></a> 
						  <input type="image" height="17" alt="Buy Now" width="78" src="site_img/buy_now.gif" border="0" name="buy_now">
						</td>
						<td width="131" height="20" valign="middle" align="right" class="prices">EURO 
						  &euro;<%=(RsSearchResults.fields("Priceincvat")* 1.59)%></td>
					  </tr>
					</table>
				  </td>
				</tr>
			  </table>
			</td>
		  </tr>
		</table>
	  </form>
	  <%
	  RsSearchResults.movenext
	  wend
	  %>
	  
	  <br>
	  <table width="580" border="0" cellspacing="0" cellpadding="0">
		<tr valign="middle" align="center"> 
		  <td width="50" height="19" valign="middle" class="overviewheader">&nbsp;</td>
		  <td width="480" height="19" valign="middle" class="overviewheader">&nbsp;</td>
		  <td width="50" height="19" valign="middle" class="overviewheader" align="right">&nbsp; 
		  </td>
		</tr>
		<tr> 
		  <td width="50" height="1" bgcolor="#336699"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		  <td height="1" bgcolor="#336699" colspan="2"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		</tr>
	  </table>
	  <table width="580" border="0" cellspacing="0" cellpadding="0">
		<tr valign="middle" align="left"> 
		  <td colspan="2" height="19" valign="middle" class="bluebold">&lt;&lt; 
			<a href="default.asp" class="bluebold">back to home</a></td>
		  <td width="386" height="19" align="right" class="overviewheader">&nbsp;</td>
		</tr>
		<tr> 
		  <td width="100" height="1" bgcolor="#336699"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		  <td height="1" bgcolor="#336699" colspan="2"><img src="site_img/pixel_darkblue.gif" width="1" height="1"></td>
		</tr>
	  </table>
	  <p>&nbsp;</p>
	</td>
  </tr>
</table>
</body>
</html>
<%
RsSearchResults.Close()
end if
%>

Open in new window

0
 

Author Comment

by:SimonDocker
ID: 22964118
Would you be able to help on the above two posts? I'd be very grateful
0
 
LVL 15

Expert Comment

by:quincydude
ID: 22967068
Just use the last code I posted, not changing every OR to AND as you did.

But if you just search for  6900  from my code nothing will be searched. If you want it you have to use the first piece of code I posted but it may also search out some other model. It's such a dilemma.
May be you will retain the original search model option?
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this tutorial I will show you how to provide a dynamic RTF document on your website generated with data from your database. For this tutorial you will need Microsoft Word or WordPad, WhizBase and Microsoft Access. In this tutorial I will show …
This article will show, step by step, how to integrate R code into a R Sweave document
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses
Course of the Month19 days, 3 hours left to enroll

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question