| Article: |
Building a Simple Search Engine with PHP | |
| Subject: | Giving Back | |
| Date: | 2007-01-23 16:52:24 | |
| From: | PHPchick | |
|
I found this really helpful in getting up & running fast and wanted to give back as a "thanks". So here's a little bit that I added in my version:
|
||
Showing messages 1 through 2 of 2.
-
Giving Back
2007-02-28 14:51:59 katie_P [View]
-
Giving Back
2007-03-05 03:59:33 katie_P [View]
Hi sorry to bother you, but do you know how to search for more than 1 word. There was code provided earlier on in this thread but it does'nt work for me
$result = mysql_query(" SELECT p.page_url AS url,
COUNT(*) AS occurrences
FROM page p, word w1, occurrence o1, word w2, occurrence o2
WHERE p.page_id = o1.page_id AND
w1.word_id = o1.word_id AND
w1.word_word = \"$keyword[1]\" AND
w2.word_id = o2.word_id AND
w2.word_word = \"$keyword[2]\" AND
GROUP BY p.page_id
ORDER BY occurrences DESC
LIMIT $results" );
I think you need to change an SQL statment, could you please help me
Thanks



thanks