Jump to content

How Does A Search Box Work


s4surbhi2218

Recommended Posts

Depends how the search is set up. A blog search could retrieve matches on slugs and tags of posts. A website search can retrieve either titles based on slugs or scan entire page content (a little too much for me). You could cache previous searches and return the results of that search when someone else runs it. There's loads of methods that can be used to search websites.

 

Ultimately you have a search term and content in a database; the database could be anything from MySQL to a text file. The algorithm used to gather results varies from one specification to the next.

 

http://en.wikipedia..../Clean_URL#Slug

Edited by CPD
Link to comment
Share on other sites

The search box itself is built with CSS, using image sprites. I can't really tell if this is what you're asking. But basically, the form is wrapped with a div with this background:

 

search-bg.png

 

And then the button itself has this as a background:

search-btn-bg.png

 

Then depending on the state of the button/form, the background's Y offset is adjusted.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.