aboutsummaryrefslogtreecommitdiff
path: root/blocks/rss_agw
diff options
context:
space:
mode:
Diffstat (limited to 'blocks/rss_agw')
-rw-r--r--blocks/rss_agw/index.php14
1 files changed, 11 insertions, 3 deletions
diff --git a/blocks/rss_agw/index.php b/blocks/rss_agw/index.php
index 83c3ff1..c811ecc 100644
--- a/blocks/rss_agw/index.php
+++ b/blocks/rss_agw/index.php
@@ -1,11 +1,17 @@
<link rel="stylesheet" type="text/css" href="blocks/rss_agw/style.css" media="screen"/>
<?php
+function stripBBCode($text_to_search) {
+ $pattern = '|[[\/\!]*?[^\[\]]*?]|si';
+ $replace = '';
+ return preg_replace($pattern, $replace, $text_to_search);
+}
+
include 'rssreader.php';
$rss = new rss_php;
- $rss->load('http://www.armedglobalwarfare.com/index.php?type=rss;action=.xml;limit=30');
+ $rss->load('http://www.armedglobalwarfare.com/index.php?type=rss;action=.xml;limit=150');
$items = $rss->getItems(); #returns all rss items
@@ -14,9 +20,11 @@
foreach($items as $story){
if($story['category']=="Tournament Announcements"){
$numFeeds++;
+ // $text = $story['description'];
+ // $text = preg_replace("(\[font(.+?)...)","",$text);
echo "<a href=\"{$story['link']}\" target=\"_blank\"><span class=\"title\">{$story['title']}</span></a><br />
- <span class=\"date\">{$story['pubDate']}</span><br />
- {$story['description']}<br /><br />";
+ <span class=\"date\">{$story['pubDate']}</span><br />";
+ echo "{$text}<br /><br />";
}
}
if(!$numFeeds){