Loading...
 

Making a PHP summary from Tiki RSS

  • Download http://boastology.com/pages/download.php The BMashine plugin
  • insert the code from this .php file into your web page at the place where you need the summary
  • modify the link to the RSS page in the beginning
$url="http://www.laka.lv/tiki/tiki-articles_rss.php?ver=2";
  • modify the text outputed in the for cycle in the beginning of the script to output everything you need. I used this:
for($i=1;$i<=count($myar[TITLE]);$i++) {
$title=iconv("UTF-8", "ISO-8859-13", $myar[TITLE][$i+1]); //convert the codepage (I need this)
$description=iconv("UTF-8", "ISO-8859-13", $myar[DESCRIPTION][$i]);
$link=$myar[LINK][$i];
$pubDate=$myar[PUBDATE][$i];
if($pubDate) { // Only show enteries with a publication date
$pubDate=strftime( "%d.%m.%Y"  ,strtotime($pubDate)); //Convert the date to something sensible
echo <<<EOF
<p><b>$pubDate</b> - <a href="$link">$title</a><br>
$description</p>
EOF;
    }
}
  • I also had to change this line
//$tags=array();
$tags=array("title", "link", "description", "pubDate");

  • In Tiki 1.8 there is a bug: RSS streams conflict with gzip compressed pages, so disable this feature in General features pane. You may still use php or apache level gzipping.

Page last modified on Sunday 28 March 2004 10:10:35 GMT-0000

Upcoming Events

1)  21 Mar 2024 18:00 GMT-0000
Tiki Roundtable Meeting
2)  25 Mar 2024 17:00 GMT-0000
29th
3)  18 Apr 2024 18:00 GMT-0000
Tiki Roundtable Meeting
4)  16 May 2024 18:00 GMT-0000
Tiki Roundtable Meeting
5)  20 Jun 2024 14:00 GMT-0000
Tiki Roundtable Meeting
6)  18 Jul 2024 14:00 GMT-0000
Tiki Roundtable Meeting
7)  15 Aug 2024 14:00 GMT-0000
Tiki Roundtable Meeting
8)  19 Sep 2024 14:00 GMT-0000
Tiki Roundtable Meeting
9) 
Tiki birthday
10)  17 Oct 2024 14:00 GMT-0000
Tiki Roundtable Meeting