Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

How to set minimum character for SEARCH?


basketmen

Recommended Posts

my site get very high load because i use "Default search operators" to OR, instead search operator AND, because i need more result for any queries

 

so maybe it is better if i can set minimum character for SEARCH for 3 or other number, is there setting or how to do that

 

 

 

 

 

please help guys, to reduce my server load (I use dedicated) and set minimum character for SEARCH

Deadline always

Link to comment
Share on other sites

you will need to add an extra test to advanced_search_result.php to set a min lenght for keywords

 

but what if they searchby date with no keywords ?

 

Have u turned off category counts, big reductions in queries there.

Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Link to comment
Share on other sites

yes i think the file need to edit is advanced_search_result.php

 

can someone write the code?

 

i think this is very important because all osc user use search, and this can reduce our server load

Deadline always

Link to comment
Share on other sites

This forum is to provide help, its not a free coding service.

 

If your not prepared to make any real effort to solve this rare need yourself, why do you think any-one else will be motivated to.

Sam

 

Remember, What you think I ment may not be what I thought I ment when I said it.

 

Contributions:

 

Auto Backup your Database, Easy way

 

Multi Images with Fancy Pop-ups, Easy way

 

Products in columns with multi buy etc etc

 

Disable any Category or Product, Easy way

 

Secure & Improve your account pages et al.

Link to comment
Share on other sites

no, this is not rare problem, it is for all osc user

 

just search 1 character for example like "A" its make more high load server, it is better if the search character below 4 character is not to search too

 

 

this is just a good contribution idea, and for anyone can make it

Deadline always

Link to comment
Share on other sites

yes, i had search in addon section http://addon.oscommerce.com and tips and tricks forum, but there is no addon for this yet

 

 

the file name to search is advanced_search_result.php

 

oscommerce is very free famous script, but..

 

ironically this file is searching all words that typed by user, even just a single word like "A" or "An"

it is searching in mysql, so its make very very high load for the server, imagine its need to search for all words that contain "A", how if you have 100.000 products/items in your site

 

 

 

i am using vbulletin too, vbulletin is paid script, it is more professional then oscommerce, in vbulletin just searching words for more then 3 character, so it is highly better if oscommerce like that too

Deadline always

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...