Topic: clickbank search engine help needed (Read 213 times)
Chicken-run Manager
Posts: 9
58 credits Members referred : 0
« on: Apr 21, 2008, 04:19:53 PM »
Greetings. I have installed the ClickBank Contextual because I really want to create a clickbank search engine on my site askhow.com - ie, all results are clickbank products from search. I read an article said you could do it w/this script:
Chicken-run Manager
Posts: 9
58 credits Members referred : 0
« Reply #6 on: Apr 21, 2008, 09:59:00 PM »
ok let me look, i took it from the example in the article linked above, (downloadable zip)
It's funny the code doesn't have that in it: here's the code:(i changed the user and pass but that's it) I usually work with html, so I'm not certain what i need to do to make the php form work.
thanks for taking a look. Code starts here: <?php /** * PHP function for integration of search results with Clickbank program * * Requires : Clickbank contextual script * http://cbcontextual.com/ * * For support issues please refer to the webdigity forums : * www.webdigity.com * * If you like this script please give us some link love * paymentblogger.com * * ============================================================================== * * @version $Id: Clickbank Search Engine ,v 1 2007/06/19 17:00:32 $ * @copyright Copyright (c) 2007 Payment Blogger (http://paymentblogger.com) * @author Nick Papanotas <nikolas@webdigity.com> * @license http://opensource.org/licenses/gpl-license.php GNU General Public License (GPL) * * ============================================================================== */
//Settings : $uname = 'notrealname';//Username in your CBcontextual installation $pass = 'notrealpass';//Password in your CBcontextual installation $instURL = 'http://www.askhow.com';//The url path to your CBcontextual installation. No trail slash $limit = 15;//How many results to display
if ( !empty($_POST['q'])){ $results = unserialize(file_get_contents($instURL.'/api.php?uname='.$uname.'&pass='.$pass.'&nr='.$limit.'&type=php&keywords='.$_POST['q'])); if ( !$results ) echo 'No results. Please search again.'; else{ foreach ( $results as $res ) echo '<a href="'.$instURL.'/clk.php?i='.$res['id'].'">'.$res['title'].'</a><br />'.$res['description'].'<br />'; } }
?>
« Last Edit: Apr 21, 2008, 10:07:32 PM by askhow »
Chicken-run Manager
Posts: 9
58 credits Members referred : 0
« Reply #7 on: Apr 22, 2008, 12:39:33 AM »
Ok, I just wanted to show you that the clickbank contextual script is working, but I can't get the search engine, scroll down and you'll see the form mess up, thanks again for your help
I am a metal monkey!
Administrator Community Supporter?
Jedai Sword Master
Gender:
Posts: 7824
39879 credits Members referred : 3
Here is what is on line 53 in my code: $results = unserialize(file_get_contents($instURL.'/api.php?uname='.$uname.'&pass='.$pass.'&nr='.$limit.'&type=php&keywords='.$_POST['q']));
Thanks again for your time,
Lisa
I am a metal monkey!
Administrator Community Supporter?
Jedai Sword Master
Gender:
Posts: 7824
39879 credits Members referred : 3
« Reply #10 on: Apr 22, 2008, 02:29:39 PM »
Change the $instURL directive to where you have installed the CBCS (eg. $instURL = 'http://www.askhow.com/cb';)
Chicken-run Manager
Posts: 9
58 credits Members referred : 0
« Reply #11 on: Apr 22, 2008, 02:34:01 PM »
ok i did that and nothing changed, likely because it is installed not in a folder but at the public_html so there is no cb folder. once I typed in 'test' and got a bunch of random results but otherwise i have this error above,
thanks
Chicken-run Manager
Posts: 9
58 credits Members referred : 0
« Reply #12 on: Apr 22, 2008, 04:35:02 PM »
Here is something that may be helpful. I set it back to the way is was, ie, w/o the cb at the end and here is the deal. It works if there are no spaces in the search so if i type in How_to_draw, it works but if i type in how to draw it doesn't. What can i do?
Assuming the string breaking with a space gets fixed, I'm perplexed by results. If you type in bike, then a good result come in. If you type in how_to_ride_a_bike then it is whack. The best results seem to come from organic_gardening.
I'm really hoping this can work.
thanks,
Lisa
« Last Edit: Apr 22, 2008, 04:59:32 PM by askhow »
I am a metal monkey!
Administrator Community Supporter?
Jedai Sword Master
Gender:
Posts: 7824
39879 credits Members referred : 3
Chicken-run Manager
Posts: 9
58 credits Members referred : 0
« Reply #14 on: Apr 23, 2008, 02:36:33 PM »
ok, it seems to be working, from a form stand point.. is there any way to get better results? ie, the how to ride a bike gets strange results but ride bike gets a real one?
thanks
I am a metal monkey!
Administrator Community Supporter?
Jedai Sword Master
Gender:
Posts: 7824
39879 credits Members referred : 3
« Reply #15 on: Apr 30, 2008, 08:38:19 AM »
I don't think this is possible at the moment. You should probably contact the owners of the script for this (I no longer own the clickbank contextual script)