They are both mysql query related,but i dont know exactly how to create such script.First example is on http://cheaterhell.com and other on http://adult-sponsor-search.com/ As you can see,on first site you type keyword and get certain data about it. On second you select boxes and got results which match that boxes. Any suggestion?Somewhere must be such scripts beacuse it is nothing complicated,simple mysql query.
It's a bit more than a "simple MySQL query"... The first: $keywords = explode("\n", $_POST['foo']); $keywords = array_splice($keywords, 50); $keywords = array_map('mysql_real_escape_string', $keywords); $query = mysql_query(" SELECT * FROM table_name WHERE field_name IN('" . implode("', '", $keywords) . "') ") OR die(mysql_error()); while ($result = mysql_fetch_array($query)) { // Do whatever with $result } PHP: Second (similar) $categories = array_map('mysql_real_escape_string', (array)$_POST['category']); $query = mysql_query(" SELECT * FROM table_name WHERE field_name IN('" . implode("', '", $categories) . "') ") OR die(mysql_error()); while ($result = mysql_fetch_array($query)) { // Do whatever with $result } PHP: These codes are just raw (untested) examples, as we don't have ANY of your database information or anything else related to what you want to do. But you might get the idea...
Lol, thanks for saying that in your first post. I posted what you asked for... ...................................... PLUS, the script doesn't consist in much more... but yeah.
Ah yes indeed you posted answer.But what i can do with part of code?Script include two parts:html interface and second is php code which connect to mysql database and check queries.But still that is not enough
You didn't ask for the ENTIRE script initially. I posted what you asked for and you come back telling me you already know this? Not trying to sound harsh, but you know how to code the PHP part but can't do the HTML interface which consists in a simple form? I'm not gonna randomly post some code and guess any more. You will have to say EXACTLY what you want and what you have already. Do you even have a database? Do you have data? Do you know what kind of data you want to display?
Yes i do have data.And yes i need a working script. So what i need a form,type a word inside,when i click check i need to see details about that word.Also it need to have option for multiple check.
For the first script. <form action="script.php" method="post"> <textarea name="foo"></textarea> <input type="submit" value="Submit" /> </form> HTML: And the second. <form action="script.php" method="post"> foo <input type="checkbox" name="category[]" value="foo"> bar <input type="checkbox" name="category[]" value="bar"> foo2 <input type="checkbox" name="category[]" value="foo2"> <input type="submit" value="Submit" /> </form> HTML: That's all I can do since mind reading doesn't work over the internet.
The thing is what i need is clone of sites which i given as example. I already founded script which is even better then example on second site.Name of script is dadabik.Now i only need to found script from first example.In any case,thanks for you effort.