| ASP Search Engine Script - ASP Web Pro |
|
ASP ScriptsSEARCH ENGINESo when would you need a search engine on your website. Well, one popular example is an FAQ (frequently asked questions) database. You could merely list all of your FAQ's on one page, but if you have a lot of them like the Micsoft Knowledge Base, then it would be a good idea to let your users search your database by keyword or phrase. The first thing you need to do is create a database called
MyDatabase. Then create a table called tblFAQ with these
fields: Then, start adding some questions and answers to your database. Next, create a page called searchengine.asp and copy the below code into your page:
This script will display your search form each time the page is accessed. When a search term is submitted, it will search both the question and answer fields in your database for any data that contains the search term. There you have it. Your first albeit simple search engine.
|
|||
|
Main Menu Other Resources
Last Updated:
|
|||
|
© 1997-2008 ASP Web Pro, Inc. | Terms of Use
|