1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

[How to]Post related ebay auctions in your posts

Discussion in 'Blogging' started by NoWhErE, Oct 17, 2009.

  1. NoWhErE

    NoWhErE BANNED BANNED

    Joined:
    Feb 21, 2007
    Messages:
    208
    Likes Received:
    50
    It took me a full day to figure out how to do this, so I figured I'd share this with the community and save you guys some of the trouble.

    First of all, I used the phpBay plugin to allow me to show Ebay auctions. I paid for it, so I can't post a nulled version for you guys (sorry, couldn't find one).

    Read the site's documentation on how to install and implement it into your site. Everything is very detailed and easy to use.

    Now, here is the tricky part : Using Tags as your keywords to display current Ebay auctions with phpBay. Took me awhile to figure it out since I've never programmed in PHP, but it works :

    Code:
    <?php $posttags = get_the_tags();
    
    if ($posttags) {
    foreach($posttags as $tag) {
    $tagz .= $tag->name . '|';
    }
    }
    $keyword = $tagz;
    $text = '[phpbay]' . $keyword . ', "5", "", ""[/phpbay]';
    echo phpBayPro($text);
    ?>
    I pasted it into my single.php file since I want to use the tags from each post to display related auctions.

    Thats it! Hope you guys like it.

    Now I'm going to work on doing the same with Amazon listings! Wish me luck.
     
    • Thanks Thanks x 1
  2. NoWhErE

    NoWhErE BANNED BANNED

    Joined:
    Feb 21, 2007
    Messages:
    208
    Likes Received:
    50
    By the way, just wanted to thank scb335 for posting what guided me to getting things working

    http://www.blackhatworld.com/blackhat-seo/blogging/75131-wp-plugin-autmate-phpbay-autoblogs-4-bhw.html
     
  3. NoWhErE

    NoWhErE BANNED BANNED

    Joined:
    Feb 21, 2007
    Messages:
    208
    Likes Received:
    50
    Hmmm, guess I'd have to post step by step in great detail how to install phpbay to get some interest?
     
  4. thatguy11221

    thatguy11221 Newbie

    Joined:
    May 20, 2009
    Messages:
    37
    Likes Received:
    10
    Occupation:
    Personal Trainer
    Location:
    Behind The Scenes
    Home Page:
    That Would be Extremely Helpful, Thanks in Advance.