Thread: database search
Results 1 to 15 of 16
How to Decode the data from Database using database handler? Forum: Search Engine Optimization - SEO - ForumReplies: 1
search access database Forum: ASP ForumReplies: 1
Database Forum: Website Scripts ForumReplies: 14
database search Forum: HTML ForumReplies: 15
10-29-2001, 10:42 PM #1
I know this may take a bit of explaining but help would be appreciated:
I want to create a "site search engine" for my site, using php and mysql. But I'm a little lost with the mysql part. While starting to get php is one thing, but I don't know too much about mysql. I can do simple things but that's it. I'd like to have them type in what they're looking for in my site, and have the "search engine page" come up with pages on my site that match what they typed in. If possible I'd like the search to be more "precise", so as lets say they type in "html", a half the pages on my site don't show up like on a lot of site searches I've seen.
I have my database made and I'm ready to make my table and I'm confused from there.
All right, I've stated what I'd like to see done, but you only have to just help me out with what you can, any assistence at all would be helpful. Hopefully I can get this thing figured out.
Thanks in advance
10-29-2001, 10:49 PM #2
my database isn't actually "made" I just opened up phpMyAdmin and named a database and named a table but haven't done anything besides that. I'm checking the mysql manual but it doesn't seam to be of help.
10-30-2001, 01:26 PM #3
Best thing you can do, would be to go and look at hotscripts. I believe there is a script called PHPDIG which was really nice.
Im not sure at the moment, on how to index a site, into a database, but again, hotscripts should have something for you
11-14-2001, 12:18 AM #4
decided I'd reply :)
Shame on u Zaire I gotta learn how...I want to find a book on MySql. I got text databases pretty(:S) good but MySql is gonna take a bit more work. Well later Zaire...thanks for all ur help on PHP.
Dave-I'm on my knees for a PHP forum...
11-14-2001, 10:47 AM #5
Well.. i believe the statement looks like this
mysql_query("SELECT * FROM table WHERE foo='%$bar%'");
11-14-2001, 05:31 PM #6
well that's not the problem...
it's CREATING the tables that's the problems I'm havin trouble figurin out what all the options in the mysql table thing are.
11-14-2001, 06:29 PM #7
Are you using phpmyadmin?
If you would tell me what you would like, I will gladly make up some tables here, and post them
11-14-2001, 06:31 PM #8
Also, i believe my select statement was wrong... i think it shuold be like
$word_to_search_for = "%".$word_from_form."%";
mysql_query("SELECT * FROM table WHERE something LIKE '$word_to_search_for'") or die(mysql_error());
You still might wanna look this up.. hehe
11-15-2001, 01:44 AM #9
Alright, closer and closer i was every time, here is the exact way to search a db
$sql = "SELECT * FROM COFFEE_INVENTORY WHERE ROAST_TYPE LIKE $sbox";
11-15-2001, 05:54 PM #10
even zaires still learnin
11-15-2001, 06:02 PM #11
k lets say I have several tables---
in each table are the links all pertaining to that subject. Could I create a search engine that when someone types in those names of the tables...the links in that table they typed in will ring up? and if they didn't type one of those then it'll bring up a "no search results"? Do u get what I"m sayin? kinda confused myself up there...
11-15-2001, 06:56 PM #12
Well, one thing that most people know, is that your never done learnin'. Im always learning new things in php.. Im contastantly printing out tutorials to read.. buyin' books. ext.. just to keep learning
11-15-2001, 06:57 PM #13
Also, ANYTHING is possible
11-15-2001, 08:23 PM #14
ok let's just say...could that be one of the EASIER routes to create a site search engine?
11-15-2001, 08:26 PM #15
So you want tables to contain links to other content? Why not just list them?
Like, what I do, is have a sitemap/article lister.. it grabs all the id's from the db's, arranges it onto a page, and automatically adds the hyperlink to the page containging the content itself Ahh, the joys of a dynamic site