The Dark Alliance
Open Area => General Discussion => Topic started by: Fenderon on 12 August, 2008, 12:39:20 PM
-
SimplePortal up and running ! Any news suggestions you have, just create a thread and PM me about it. :)
Edit: If you can't find the forum again.. click on "Forum" at top, or follow this link: http://tda.nu/forum/index.php?action=forum
-
a few bugs to work out with the themes..
For those that dont yet have it, this will add a "Forum" button to the top bar.. on the front page you'll see news and other info (including poll(s)).
In time and if we get XML like we had in daoc .. info pulled from the WAR servers can be used as well :)
More info to come..
-
Cool :) Hopefully WAR will have something equal (or better) to what DAoC has regarding XML and stuff. I just fixed the XML stats on fom.urme.com, Mythic had done some changes to the xml structure, doesn't seem they are updating it that frequently atm though.
Will write something similiar when WAR is released and if GOA are updating the XML for WAR which they didn't do that often for DAoC :/
-
Forum button added for Black Rain theme
-
wicked \o/
-
feedback is welcome :P
-
I like it. Tho not sure how to post stuff on it (if i actually can)
Can the latest polls be hiden from the main site? might come a time when we have a poll we dont want non members to see.
-
Polls were added manually. :) And if a person is not logged in, he can't see those in "member only" section.
edit: I'll sort rights for global mods now .. it should come up as an option when you create a new topic/thread
-
Lembit: See now if you get the option.
-
It works.
Yes yes yes, replying here to get me postcount up :)
-
I removed it :P
Hopefully this will give us xml data for WAR when/if that becomes available.
-
Is there any module so you can have an RSS feed from warhammeronline.com news? Basically just a box like "forum activity" on the first page. Or is _everything_ driven through forum posts?
-
There are php and html boxes.. so in theory if you have php code that reads the news, that should do it.
-
quick test using php code from here: http://www.rss-info.com/en_rssinclude-simple.html worked ..
however black text on userdefined background didn't really do it.. also it showed the entire entry, I'd like just the topics :)
-
fyi: I use the classic YABB SE theme - no fancy graphics and "readability" (hehe - what a word) is best I think. Some stuff might not work here, but as long as I can follow a link and come back to the forum I am happy for the moment.
-
I know.. you could try classic for now, if thats ok.. but I didn't find a "forum" button :p in the other themes I could just add it manually, there was no picture file
-
next on the todo list is to "move" the entire thing to http://tda.nu/ .. as in remove the "forum/" bit.
Will have to look into that a bit, might break a few links
-
I have written a simple rss parser for WAR news, try to add this code to a php block:
Example 1:
$feedurl = "http://feeds.warhammeronline.com/warherald/RSSFeed.war?type=current";
if(!$xml=simplexml_load_file($feedurl)){
echo 'Error reading RSS file';
}
foreach($xml->channel->item as $news) {
echo '<a href="'.$news->link.'" target="_blank">'.$news->title.'</a> - ';
echo '<small>'.strftime("%d %b",strtotime($news->pubDate)).'</small><br />';
}
Not sure if we have to cut number of letters so it's easier to read.
Edit: Changed the code a tiny bit 15:45cet
Edit2: Maybe it's easier to read if it's a list with a dot before the header.
Example 2:
$feedurl = "http://feeds.warhammeronline.com/warherald/RSSFeed.war?type=current";
if(!$xml=simplexml_load_file($feedurl)){
echo 'Error reading RSS file';
}
echo '<ul style="list-style-position:inside;margin:0;padding:0;">';
foreach($xml->channel->item as $news) {
echo '<li style="padding-bottom:5px;"><a href="'.$news->link.'" target="_blank">'.$news->title.'</a> - ';
echo '<small>'.strftime("%d %b",strtotime($news->pubDate)).'</small></li>';
}
echo '</ul>';
-
Btw that was the US RSS news feed, we could have two blocks one for US and one for EU :)
Create another block and change the $feedurl like this:
$feedurl = "http://www.war-europe.com/syndic_proc/rss/guest/en/rss.xml";
And it will display the EU WAR News.
-
Or maybe it's enough to display the four latest news from each feed in the same box:
$feedurl1 = "http://feeds.warhammeronline.com/warherald/RSSFeed.war?type=current";
$feedurl2 = "http://www.war-europe.com/syndic_proc/rss/guest/en/rss.xml";
$limit = 4;
function displaynews($title, $xml, $counter = 0) {
$newsdata = '<b>'.$title.'</b>';
$newsdata .= '<ul style="list-style-position:inside;margin:0;padding:0;">';
foreach($xml->channel->item as $news) {
if($counter < 4) {
$newsdata .= '<li style="padding-bottom:5px;"><a href="'.$news->link.'" target="_blank">'.$news->title.'</a> - ';
$newsdata .= '<small>'.strftime("%d %b",strtotime($news->pubDate)).'</small></li>';
}
$counter++;
}
$newsdata .= '</ul>';
return $newsdata;
}
if(!$xml1=simplexml_load_file($feedurl1)){
echo 'Error reading US News file<br />';
}
if($xml1) {
echo displaynews("US News", $xml1);
}
if(!$xml2=simplexml_load_file($feedurl2)){
echo 'Error reading EU News file<br />';
}
if($xml2) {
echo displaynews("EU News", $xml2);
}
Edit: Modified the code, so it's a bit cleaner, I'll stop the spam now :)
-
Fatal error: Call to undefined function: simplexml_load_file() in /web/tda.nu/forum/Sources/SPortal.php(1570) : eval()'d code on line 20
-
Hmm what version of PHP are running on the server? I thought simpleXML was default in php5+
-
create a new file called phpinfo.php
and add this code:
<?php
phpinfo();
?>
Then you'll see which version of php and other stuff that's installed on the server.
-
SimplePortal up and running ! Any news suggestions you have, just create a thread and PM me about it. :)
Edit: If you can't find the forum again.. click on "Forum" at top, or follow this link: http://tda.nu/forum/index.php?action=forum
still havent this forum button on top , glad the link is still there! :)
-
what theme are you using?
-
added forum-button to the classic theme that a few people are using (including dub)
edit: it doesn't look 100% as the other buttons, but with four people using the theme .. I didn't bother, sorry :)
-
thanks :)
/hug
-
ah! great Fend, thank you!