PDA

View Full Version : create search engine in my site



lord22
07-27-2008, 12:37 PM
Hi

Is it possible to create a search engine in my site, without using Database?
I want to learn about search methods.
If you know any tutorial or have some code for me I'll appreciate it. :)

Nile
07-27-2008, 01:04 PM
You can use google, http://www.google.com/sitesearch/#utm_medium=et&utm_source=us-en-et-bizsol-0-finderB-all&utm_campaign=en.

Witch does cost money. There are a few other ways. But indeed very hard.

Below is assuming your using PHP for your search, and you've got a basic knowledge of file_get_contents.

You'd get every single file on your website with file_get_contents, and for every word the user typed in the search file_get_contents does * the amount. Then finds the words, then gets the pages that have the words, and then output them back.

techietim
07-27-2008, 01:10 PM
Lots here:

http://php.resourceindex.com/Complete_Scripts/Searching/Searching_Your_Web_Site/

lord22
07-27-2008, 01:48 PM
Lots here:

http://php.resourceindex.com/Complete_Scripts/Searching/Searching_Your_Web_Site/
Thank you I'll check this out.


You can use google, http://www.google.com/sitesearch/#utm_medium=et&utm_source=us-en-et-bizsol-0-finderB-all&utm_campaign=en.

Witch does cost money. There are a few other ways. But indeed very hard.

Below is assuming your using PHP for your search, and you've got a basic knowledge of file_get_contents.

You'd get every single file on your website with file_get_contents, and for every word the user typed in the search file_get_contents does * the amount. Then finds the words, then gets the pages that have the words, and then output them back.
Thank you too. I don't want to use the google search in my site.
I am a bit new in PHP, but I really want to learn how to make it by myself.
Do you know any tutorial about this thing?

allahverdi
07-27-2008, 04:21 PM
First of all, look at this: www.php-mysql-tutorial.com

Start here. I think this site is awesome for starters. Then for functions you can www.php.net . I think you will find good things here too :)

I hope my post will help you :)

lord22
07-27-2008, 04:31 PM
thank you G, but I've already been in those sites. I just don't have a clue where to start looking for what I need. I know ASP, JAVA and other stuff, so it's not that I'm new in programming. I also edited many PHP files, but steel I don't know what should I look for, which functions can help me etc.

allahverdi
07-27-2008, 06:39 PM
I think there are few ways to make a search engine.

But all it depends what wngine you want.

For example if you have all information in your db, you can easily search it with mysql and other.

But also you can have others situations. Like to search in files.

If you want to find which function you need to use:
1. you can post here
2. you can search. you know, Google is our friend (http://www.google.com)!

lord22
07-27-2008, 07:59 PM
thanks
I'm looking for a search engine that can search in a site, which is not based on DB.
Another problem for me is that sometimes, the owner of the site can add pages, and the search engine should recognize them.

Nile
07-29-2008, 01:09 PM
thanks
I'm looking for a search engine that can search in a site, which is not based on DB.
Another problem for me is that sometimes, the owner of the site can add pages, and the search engine should recognize them.

Thats why its good to use my idea. File_get_contents.

allahverdi
07-29-2008, 06:22 PM
lord22, sorry for late answer.
But, Nile already posted what I wanted to post :)

lord22
07-29-2008, 08:01 PM
Thats why its good to use my idea. File_get_contents.
OK so I'll try it!
thank you both very much!