Importing ebay rss feed into my own webapp

Discussion in 'Commission Junction' started by kx2, Oct 2, 2007.

  1. #1
    Heya all,

    I wanna use Drupal for creating my own cj/ebay store... I heard it's pretty easy to set it up if you know php and stuff... So here I am, I am pretty expereinced with php/mysql/xhtml/css ... also I'm into Drupal CMS big time... I have built several Drupal sites and communities...

    Althought I haven't built any cj/ebay stores with Drupal (I'm just getting into affiliate stuff :) ), but I figure it won't be a problem.... There's an RSS aggregator module for Drupal, I just tried it, it works pretty sweet... It will import RSS feeds and I can configure it to update feed on every X number of hours.

    So anyone here doing this kinda thing? What is the rss feed from ebay that I need to import? How does the whole process look like in general? Any advice I would really appreciate from you guys. btw I am already a member on CJ.com . Also I am accepted as an ebay affiliate through cj.com

    Any thoughts?

    Thanks in advance.
     
    kx2, Oct 2, 2007 IP
  2. kx2

    kx2 Well-Known Member

    Messages:
    176
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    103
    #2
    kx2, Oct 2, 2007 IP
  3. jonixkonios

    jonixkonios Peon

    Messages:
    504
    Likes Received:
    11
    Best Answers:
    0
    Trophy Points:
    0
    #3
    with a little of php knowledge, php5 with simplexml, wonders can be made with the ebay rss feed and other feeds. great mashup sites can be build, and much can be accomplished
     
    jonixkonios, Oct 2, 2007 IP
  4. Nathy

    Nathy Active Member

    Messages:
    435
    Likes Received:
    59
    Best Answers:
    0
    Trophy Points:
    70
    #4
    Very easy to make an ebay affiliate store with the rss feeds!
     
    Nathy, Oct 2, 2007 IP
  5. kx2

    kx2 Well-Known Member

    Messages:
    176
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    103
    #5
    Yeah I figured that.. but did anyone else have a problem with error msg when trying to import rss feed from ebay:

    It says: Please specify a query! (9003)

    ?
     
    kx2, Oct 3, 2007 IP
  6. Kerosene

    Kerosene Alpha & Omega™ Staff

    Messages:
    11,366
    Likes Received:
    575
    Best Answers:
    4
    Trophy Points:
    385
    #6
    When I first tried using the feed I was getting all sorts of errors, turns out it was all due to url_fopen being disabled.
    Has your host disabled php url_fopen? I'm 99% sure you need this ENABLED.
     
    Kerosene, Oct 3, 2007 IP
  7. kx2

    kx2 Well-Known Member

    Messages:
    176
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    103
    #7
    I just checked, allow_url_fopen is ON.

    Im not really sure what the problem is. Do I Need php5, cause I am running php4.

    I also tried it using lastRSS.php with thise code:

    
    <?php
    include_once './lastRSS.php';
    $rss = new lastRSS; 
    $rss->cache_dir = './cache'; $rss->cache_time = 3600; // one hour
    if ($rs = $rss->get('my_ebay_feed')) 
    {
    foreach ($rs['items'] as $item) {
    $rsscount++; if ($rsscount< 6) {
    $myvar = $item[description];
    $title = $item[title];
    echo "<b>$title</b>$myvar"
    }}
    if ($rs['items_count'] <= 0) { echo "Sorry, no items found.<br /><br />" } else { die ('Error: RSS file not found…'); }
    ?>
    
    Code (markup):
    it says :

    Parse error: syntax error, unexpected '}', expecting ',' or ';' in /var/www/.... : eval()'d code on line 12

    I tried putting ; after $myvar" but no luck...

    Am I missing something or what?
     
    kx2, Oct 3, 2007 IP
  8. Kerosene

    Kerosene Alpha & Omega™ Staff

    Messages:
    11,366
    Likes Received:
    575
    Best Answers:
    4
    Trophy Points:
    385
    #8
    Assuming you're declaring the variable somewhere else... shouldn't that be $my_ebay_feed without the quotes?

    I generally use:
    $url = 'massive_long_ebay _url';
    ...
    $rs = $rss->get($url)) 
    Code (markup):
     
    Kerosene, Oct 3, 2007 IP
  9. kx2

    kx2 Well-Known Member

    Messages:
    176
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    103
    #9
    no I just put my_ebay_feed here instead of my real ebay feed url that I put... never mind, I got it working, I had one curly bracket missing :)

    the thing is I recieve the result as pure HTML, I dont undertsand why it wont render it in the browser? Instead it just displays raw html.
     
    kx2, Oct 3, 2007 IP
  10. Kerosene

    Kerosene Alpha & Omega™ Staff

    Messages:
    11,366
    Likes Received:
    575
    Best Answers:
    4
    Trophy Points:
    385
    #10
    Those fkn curly brackets :p

    What are your settings in lastrss?
    This is what I use....

     
    Kerosene, Oct 3, 2007 IP
  11. kx2

    kx2 Well-Known Member

    Messages:
    176
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    103
    #11
    kx2, Oct 3, 2007 IP
  12. kx2

    kx2 Well-Known Member

    Messages:
    176
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    103
    #12
    hey it works... I had to put:

    var $CDATA = 'content';

    now.. how do I make paging? Like, I want to have 10 items displayed on the first page, then have links to 2nd, 3rd, 4th page and so forth... and on each page display 10 current items from the feed.

    btw am I allowed to pull several Ebay feeds on my site? Like, I have several categories of products: say I wanna sell CDs, DVDs, EPs, and those are my categories, I have separate page for each category, and on that page I pull appropriate ebay rss feed.
     
    kx2, Oct 3, 2007 IP