phpBay Pro/ WordPress Search Mod

Alright Partner.  This is more talk about leveraging phpBay Pro to make money for you.  If, after reading my previous blog post, "MUST Have PhpBay Pro Mod (FREE)", you are still trying to create eBay niche stores with something besides PhpBay Pro then stop right now.  Forget BANS or any free-ebay plugins that you might have found.  You are just wasting time.  Go, check out PhpBay Pro now.

Now that you are happily cranking out niche stores like nobodies business you might be asking yourself, "Self, wouldn't it be great if people could use the WordPress search function on my site to actually search eBay directly".  That is to say, can we have the search results be presented from ebay auctions instead of links to pages/posts on your site.

Good news, it's wicked easy to do this.  Look for the search.php file in your theme and edit it.  (NOTE: I'm not sure how to make this work with themes that use searchform.php instead of search.php)

Now, look for the following code in your search.php:
<?php if(have_posts()) : ?>

Delete everything from this line up until (and including) the following line:
<?php endif; ?>

Now, in it the place of the delete code, enter the following:

<p align="center">Your search for '<strong><font color="#FF0000"><? echo $_GET["s"] ?></font></strong>' returned the following results:</p>
function phpBaySearch($term) {
$keyword = $term;
$category = "";
$text .= '[phpbay]' . $keyword . ',20,' . $category . ', ""[/phpbay]';
echo phpBayPro($text);

Save your new search.php and head over to your site. Type something in the search box and see the majesty and beauty of ebaby search results displayed real purty-like on your site!

I'm hoping to get Hanji, from money-code, into phpBay Pro and then I'm sure he can tell us how to modify themes that use searchform.php to do the same thing.  I'll also post a question in the phpBay Pro forums and I'll follow-up if I get any answers.

For what it's worth, though, if you are using a theme like Arclite that seems to use both search.php and searchform.php, then I've had good luck with

1) backing up the original search.php
2) copying index.php over search.php
3) editing the new search.php, removing the if and else statements related to have_post and replace that entire chunk with the phpBay pro code above