• Previous message: [greg-dev] New theme: 3 panes view
  • Next message: [greg-dev] HOWTO integrate gregarius into other webpages (and wordpress)
  • Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

    [greg-dev] HOWTO integrate gregarius into other webpages (and wordpress)

    Gregarius can easily be embedded in other applications because it can
    output almost any of its pages (even search pages, tags etc.) as an RSS
    feed. Thanks to Marco, all you have to do is append ?theme=rss to the
    URL. 
    
    Feeds2js is a program http://jade.mcli.dist.maricopa.edu/feed/ that you
    can use to convert your feeds into javascript and then you can put that
    on any webpage. It uses magpie and php and all the other open source
    goodness that gregarius uses. So there is no real need to install that
    program. After stealing all the ideas from their GPL source code :),  I
    created a small rss2js theme which I shall put on the wiki soon.
    
    You just need to append rss2js to any url to get the output of that page
    as javascript code that you can append into any url. Then you can style
    it using css. 
    
    This means that you can use gregarius as a "feed dj". For example if you
    have many feeds on "belly button lint" then you can put them all in
    gregarius in a folder or tag them all with a keyword like "interesting".
    Then you can take the page
    http://example.com/rss/interesting/?theme=rss2js and with one javascript
    line put that into any webpage you are creating about "belly button
    lint". 
    
    Eg. You can take a look at an example of a wordpress page. 
    http://test.dcostanet.net/wordpress/?page_id=65
    There is just 1 line of javascript in the post and it generates content
    by searching my gregarius feeds for the word "amazing". Only the top 7
    results are shown for now.  This can be configured to be anything. 
    
    The bottom box is is javascript line I put into the footer. You can see
    it on the footer of this page http://test.dcostanet.net also. 
    
    The queries are live each time you load the webpage. So that means that
    if you can update gregarius at http://test.dcostanet.net/rss then the
    wordpress webpage will change. 
    
    Sameer
    
    Posted by Sameer D'Costa [reply] at Sun Sep 4 09:16:20 CEST 2005