Results 1 to 10 of 10

Thread: Search forums 3 charecter rule

  1. #1
    Senior Member
    Join Date
    Jul 2003
    Posts
    634

    Search forums 3 charecter rule

    I dunno whether its done for a security reason, but one thing that I find annoying with the search fuction is that you can't enter a word less that 3 charecters.

    I understand it gets rid of words such as the and to and other meaningless words but its a pain when you search for things like "xp security" or "xp user accounts" basically anything with the version of windows in it.....

    Thats probably why negatives searchable tutorial index is gonna be really useful...

    Heres the delightful message if you havent seen it -

    The search term you specified (xp) is under the minimum word length (3) and therefore will not be found. Please make this term longer.
    If this term contains a wildcard, please make this term more specific.
    i2c

  2. #2
    Senior Member
    Join Date
    Feb 2004
    Posts
    620
    Yes, I've always found this extremely annoying. I think it's a "feature" of the vBulletin software... Since I've had the same problem at other forums that use it.

    Pretty damn annoying if you ask me.

    mjk

  3. #3
    Hey it might be annoying but it will influence members to try and type a better search question in to the search engine.
    That way the more that you type in the more of a result that you may get.

    And i am currently running a VBulletin Site and i haven't run into this problem yet, i just checked it before i started posting this post, and i can do a search using less then 3 characters.
    I know that you can adjust the Maximum And Minumum characters in the Admin Control Panel, but seeing as this site is mainly a VBulletin Script you have to remember that it was ported with another forum script as well.
    (Not to sure but i think it's phpBB or something).
    Any how it makes it hard to say wethere JP inserted that rule into the Site Code or if infact JupMedia are able to adjust this through the Admin control panel.

    Sorry if it's a little confusing but hey i'm half drunk

    cheers
    f2b:.

  4. #4
    Administrator mnstrgrl's Avatar
    Join Date
    Feb 2003
    Posts
    512
    Yep, we can change the min characters for search terms... the most annoying thing is that even if you enter more than 1 term for your search, NONE of them can be less than the min length. I've looked over that code in the past trying to change this behavior, but there's no simple way to solve the problem. I'll take another look at it soon.

    - h
    I'm not mean. You're just a sissy.

  5. #5
    Senior Member
    Join Date
    Jul 2003
    Posts
    634
    mnstrgrl, thanks much appreciated.

    I think that if its doable it would be worthwhile because it would cut down I believe on the number of people asking questions regarding things related to an OS that have already been covered,

    cheers once again

    i2c

  6. #6
    Administrator mnstrgrl's Avatar
    Join Date
    Feb 2003
    Posts
    512
    I made a change to the search code so the minimum word length rule will now only be applied to the first word in a query. To search for a term shorter than 3 characters, you have to include a longer term along with it, but the shorter term won't trigger a word-length error.

    Example: if you want to search for "ms windows", you'll have to change your query to "windows ms". The first query still will not work, but the second query will work now.

    Is this change at all helpful?

    - h
    I'm not mean. You're just a sissy.

  7. #7
    Senior Member
    Join Date
    Aug 2003
    Posts
    1,018
    I haven't given it a vigorous workout or anything, but at least you can do a search for 'securing xp' and get some relevant results.

  8. #8
    Banned
    Join Date
    Jul 2001
    Posts
    1,100
    Greetings All:

    The problem is that vbulletin creates its own index to do the searches from. The issue isn't that you "can't" make it less than 3 characters, the issue is that if you DO, the index that the database creates would become HUGE, and it would take you FOREVER to make a post (each post is indexed real-time as it's made) as it would have a great deal more indexing to do.

    Also, the site would become VERY slow, or require a LOT more hardware, as it is taking way more tics to process each post made, and each search done.

    The solution, of course, is to not have vbulletin create its own index to search from. Mysql has a bunch of nifty new features that can be used so that the DATABASE is doing the searching, instead of the clunky php scripts.

    No more indexing each time a post is made, no more HUGE vbulletin created search index, and BAM, you can search for 1 or 2 characters no problem. The entire site would actually run FASTER, because the php scripts wouldn't be indexing each post as it was made.

    The other advantage, is that if a search word is too common (such as if you were to search for "is" or "an" or "a" or "i" or "the"), MYSQL would automatically recognize that it's too common of a search term to be useful, and return an error as such. However, if it's used as a combination with other terms, it may very well lead to a more precise result.

    This what I did when programming my new forum (because I realized it was one of the MAJOR problems with this site when I was running it).

    It's a beautiful thing, you should look into it.....

  9. #9
    Thanks for that in-depth post JP..
    I was starting to think What The
    But now i slightly understand it, but im sure that a quick Google will turn up more information..

    tye
    LFrog
    Umm they said i should put my signature here.
    And now all i got is a heap of White Out on the Monitor..

  10. #10
    Administrator mnstrgrl's Avatar
    Join Date
    Feb 2003
    Posts
    512
    JP - Thanks for the suggestion. It would be great to update the search to use the mySQL search functions instead of the incredibly clunky PHP search that comes with vB. I'll look into this when I get a chance.

    - h
    I'm not mean. You're just a sissy.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •