HighDots Forums  

Search pages...

Macromedia Dreamweaver Macromedia Dreamweaver Discussions (macromedia.dreamweaver)


Discuss Search pages... in the Macromedia Dreamweaver forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Ben Walker
 
Posts: n/a

Default Search pages... - 06-28-2004 , 08:21 AM






I have created a search page which works fine apart from one thing.

When a user searches for a property with 5 or more bedrooms, the results
return nothing.

How do i get the search page to show only the properties > 5 beds.




Reply With Quote
  #2  
Old   
s_m_b
 
Posts: n/a

Default Re: Search pages... - 06-28-2004 , 09:22 AM






"Ben Walker" <bwalker (AT) telephoneland (DOT) com> wrote in news:cbp2jd$sen$1
@forums.macromedia.com:

how are you doing the search?

Quote:
I have created a search page which works fine apart from one thing.

When a user searches for a property with 5 or more bedrooms, the results
return nothing.

How do i get the search page to show only the properties > 5 beds.






Reply With Quote
  #3  
Old   
Ben Walker
 
Posts: n/a

Default Re: Search pages... - 06-28-2004 , 11:34 AM



using form drop downs.

each value is 1 2 3 4 5 then i dont know what to put for 5 +.

If i put 5, it pulls only 5 bed properties not greater than.


"s_m_b" <smb20002ns (AT) hotmail (DOT) com> wrote

Quote:
"Ben Walker" <bwalker (AT) telephoneland (DOT) com> wrote in news:cbp2jd$sen$1
@forums.macromedia.com:

how are you doing the search?

I have created a search page which works fine apart from one thing.

When a user searches for a property with 5 or more bedrooms, the results
return nothing.

How do i get the search page to show only the properties > 5 beds.








Reply With Quote
  #4  
Old   
s_m_b
 
Posts: n/a

Default Re: Search pages... - 06-28-2004 , 12:28 PM



"Ben Walker" <bwalker (AT) telephoneland (DOT) com> wrote in
news:cbpdrt$fcg$1 (AT) forums (DOT) macromedia.com:

right, next bit. what code submits the request for the recordset?

Quote:
using form drop downs.

each value is 1 2 3 4 5 then i dont know what to put for 5 +.

If i put 5, it pulls only 5 bed properties not greater than.


"s_m_b" <smb20002ns (AT) hotmail (DOT) com> wrote in message
news:Xns9516920CE5FC5smb2000nshotrmailcom (AT) 216 (DOT) 104.212.96...
"Ben Walker" <bwalker (AT) telephoneland (DOT) com> wrote in news:cbp2jd$sen$1
@forums.macromedia.com:

how are you doing the search?

I have created a search page which works fine apart from one thing.

When a user searches for a property with 5 or more bedrooms, the
results return nothing.

How do i get the search page to show only the properties > 5 beds.










Reply With Quote
  #5  
Old   
Mark Bodoh
 
Posts: n/a

Default Re: Search pages... - 06-29-2004 , 08:58 AM



Manually code a check of the value of the combobox. If it is 5, then
make the where clause of your query >= to the value of the combobox,
if not 5, then make your where clause the value of the combobox. Then
substitute your manually coded query for the DW generated one.

var strsql = "";
if (String(Request.Form("cbox1")) == 5)
{strsql = "SELECT ... WHERE colname >=
String(Request.Form("cbox1"))}
else
{strsql = "SELECT ... WHERE colname = String(Request.Form("cbox1"))}

var Recordset1 = Server.CreateObject("ADODB.Recordset");
Recordset1.ActiveConnection = MM_MYCONN_STRING;

Recordset1.Source = strsql;

Recordset1.CursorType = 0;
Recordset1.CursorLocation = 2;
Recordset1.LockType = 1;
Recordset1.Open();
var Recordset1_numRows = 0;

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.