Current location: Hot Scripts Forums » Advertising Forums » Website Reviews » PHP search engine-need some advice


PHP search engine-need some advice

Reply
  #1 (permalink)  
Old 07-11-03, 02:10 PM
darkcarnival's Avatar
darkcarnival darkcarnival is offline
PHP/MySQL coder
 
Join Date: Jun 2003
Posts: 939
Thanks: 0
Thanked 0 Times in 0 Posts
Exclamation PHP search engine-need some advice

hi,

now this script isnt done yet.but i am almost done but i want to see if this is stable enough to run. now im going to add the admin file once im done w/that.if you think i should add something tell me, this is my 1st program.remember i just want to see if it is runable it doesnt work(as of yet)
Reply With Quote
  #2 (permalink)  
Old 07-16-03, 09:20 AM
darkcarnival's Avatar
darkcarnival darkcarnival is offline
PHP/MySQL coder
 
Join Date: Jun 2003
Posts: 939
Thanks: 0
Thanked 0 Times in 0 Posts
see ppl r downloadin my script but hasnt told me if it is runable or not.
Reply With Quote
  #3 (permalink)  
Old 07-17-03, 06:04 AM
Jerome Jerome is offline
Wannabe Coder
 
Join Date: Jun 2003
Location: On Earth
Posts: 177
Thanks: 0
Thanked 0 Times in 0 Posts
the problem is we are not able to test the thing without the config.php and the mysql query execute ... so i guess for a full test to the script , pls provide these file too
__________________
Support me by clicking ads
@ http://atomise.blogspot.com
CHEERS
Reply With Quote
  #4 (permalink)  
Old 07-17-03, 08:43 AM
darkcarnival's Avatar
darkcarnival darkcarnival is offline
PHP/MySQL coder
 
Join Date: Jun 2003
Posts: 939
Thanks: 0
Thanked 0 Times in 0 Posts
um did u read it, it doesnt work! i only want to see if it is coded right.once i get the admin panel done then ill allow other to fully try it.this is just to see if it is coded right.since it is my 1st program.
Reply With Quote
  #5 (permalink)  
Old 07-17-03, 05:44 PM
Damian's Avatar
Damian Damian is offline
Wannabe Coder
 
Join Date: Jun 2003
Posts: 149
Thanks: 0
Thanked 0 Times in 0 Posts
how are we supposed to read your code without testing it !??! heh...come on dude it's doesn't work that way... provide everything and we will be more than happy to help you out
__________________
"My occupation now, I suppose, is jail inmate."
- Unibomber Theodore Kaczynski, when asked in court what his current profession was.
Reply With Quote
  #6 (permalink)  
Old 07-17-03, 07:20 PM
darkcarnival's Avatar
darkcarnival darkcarnival is offline
PHP/MySQL coder
 
Join Date: Jun 2003
Posts: 939
Thanks: 0
Thanked 0 Times in 0 Posts
look i want u to look at the code NOT run it. geez just look at it and see if it is coded right. you guys are smart, just look at the source code and tell me if i coded it right. i dont want to hear if it runs good ill decide that. just want to see if it is coded like a search engine should be. im still working on the admin panel like i said so i want someone to look over the code and tell me if i coded it wrong.

i swear if i hear one more post telling to post the other files ill just find another place to help me cause u guys cant read what im typing!!
Reply With Quote
  #7 (permalink)  
Old 07-17-03, 07:29 PM
BdSBB BdSBB is offline
Newbie Coder
 
Join Date: Jun 2003
Location: Georgetown, TX
Posts: 54
Thanks: 0
Thanked 0 Times in 0 Posts
it doesn't work... you will see common errors when you actually try running the script. also you are using HTML inside of your PHP, don't do that.

...html goes here...
<?php
...php goes here...
?>
...html goes here...

Another thing I see is that your re-writing variables and connecting to the database in each IF statement. Try and lessen these by placing common variables at the top including database connections.
__________________
-- BdSBB

Last edited by BdSBB; 07-17-03 at 07:32 PM.
Reply With Quote
  #8 (permalink)  
Old 07-18-03, 08:11 AM
Chris Boulton Chris Boulton is offline
Wannabe Coder
 
Join Date: Jun 2003
Location: Sydney, Australia
Posts: 208
Thanks: 0
Thanked 0 Times in 0 Posts
PHP Code:

<?

/********************************\
 #Metal Search v1.0
\********************************/

include ("config.php");

IF (
$Choice == "Artist")
{

    
$VER="1.0"
    
$date Date("F d, Y");
    
$keyword $_GET['query']
    
$db_connection mysql_connect ($DB_HOST$DB_USER$DB_PASS) or die ('Could not connect to MySQL: ' mysql_error());

    
mysql_select_db ($DB_NAME) or die ('Could not select database: ' mysql_error());

    
$query "SELECT Name, Address, Description, Keywords FROM SSearch_Artist";

    
$results mysql_query ($query) or die (mysql_error());

    echo 
"<HTML>\n";
    echo 
"<HEAD>\n";
    echo 
"<TITLE>Results for $keyword</TITLE>\n";
    echo 
"</HEAD>\n";
    echo 
"<BODY BGCOLOR=\"#000000\" TEXT=\"$FFFFFF\" LINK=\"#66CCFF\" VLINK=\"#66CCFF\" ALINK=\"#66CCFF\">\n";
    echo 
"<FONT FACE=\"Verdana\" SIZE=\"2\">\n";
    echo 
"<H1>Search Result(s) for: query</H1>\n";

    while (
$row mysql_fetch_array ($resultsMYSQL_ASSOC)) {
        echo 
"<A HREF=\"$row['address']\">$row['Name']</A> - $row['Description']<br />\n";

    }
    
mysql_query("INSERT INTO SSearch_log (Date, Keyword, Choice) VALUES ($date$keyword$Choice);");

    
mysql_free_result($results);
    
mysql_close()

    echo 
"<BR><BR><CENTER>Metal Search<BR>\n";
    echo 
"$VER</CENTER>\n";

    echo 
"</BODY>\n";
    echo 
"</HTML>\n";
}
There is the first part rewritten into code that should work. You can use it for ideas on how to fix up the rest of the script.

Chris
__________________
Chris Boulton
SurfiOnline!
MyBulletinBoard

Last edited by Chris Boulton; 07-18-03 at 08:25 AM.
Reply With Quote
  #9 (permalink)  
Old 07-18-03, 09:12 AM
darkcarnival's Avatar
darkcarnival darkcarnival is offline
PHP/MySQL coder
 
Join Date: Jun 2003
Posts: 939
Thanks: 0
Thanked 0 Times in 0 Posts
ok thx dude. im alittle busy wokring my site new style now but i will get that added.i could also use help on my admin panel i dont know how to show different titles w/o using <title>
Reply With Quote
  #10 (permalink)  
Old 07-18-03, 05:46 PM
Damian's Avatar
Damian Damian is offline
Wannabe Coder
 
Join Date: Jun 2003
Posts: 149
Thanks: 0
Thanked 0 Times in 0 Posts
look man don't give us attitude here... you don't expect someone to browse trough your crap and give him attitude. We're all friends...after all we're just trying to help you out ! cut the bullshit and if you want help, you can start by showing some respect !
__________________
"My occupation now, I suppose, is jail inmate."
- Unibomber Theodore Kaczynski, when asked in court what his current profession was.
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
SEO Expert Available nakulgoyal Job Offers & Assistance 2 08-14-04 12:38 PM
PHP search engine flipsix PHP 3 10-19-03 02:07 PM
search engine help darkcarnival PHP 5 08-08-03 07:27 AM
search engine question herman PHP 2 08-04-03 11:41 PM
How to do a search engine?? bonnie ASP 7 07-07-03 03:41 AM


All times are GMT -5. The time now is 02:12 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.