mirror of
https://github.com/slawkens/myaac.git
synced 2025-04-26 17:29:21 +02:00

* updated forum links to use friendly_urls * some more info will be shown when cannot connect to database * show more error infos when creating character * fixed forum link on newses * fixed spells loading when there's vocation name instead of id * fixed bug when you have changed template but it doesn't exist anymore * fixed vocations with promotion loading * fixed support for gesior pages and templates * added function OTS_Acount:getGroupId()
34 lines
1.3 KiB
PHP
34 lines
1.3 KiB
PHP
<?php
|
|
defined('MYAAC') or die('Direct access not allowed!');
|
|
function news_parse($title, $content, $date, $icon = 0, $author = '', $comments = '')
|
|
{
|
|
global $template_path, $config;
|
|
//$tmp = $template_path.'/images/letters/'.$content[0].'.gif';
|
|
//if(file_exists($tmp)) {
|
|
// $firstLetter = '<img src="' . $tmp . '" alt="'.$content[0].'" BORDER=0 ALIGN=bottom>';
|
|
//$content[0] = '';
|
|
//}
|
|
|
|
return '
|
|
<div class="NewsHeadline">
|
|
<div class="NewsHeadlineBackground" style="background-image:url(' . $template_path . '/images/news/newsheadline_background.gif)">
|
|
<img src="' . $template_path . '/images/news/icon_' . $icon . '.gif" class=\'NewsHeadlineIcon\' />
|
|
<div class="NewsHeadlineDate">' . date($config['news_date_format'], $date) . ' - </div>
|
|
<div class="NewsHeadlineText">' . stripslashes($title) . '</div>
|
|
' . (isset($author[0]) ? '
|
|
<div class="NewsHeadlineAuthor"><b>Author: </b><i>' . $author . '</i></div>' : '') . '
|
|
</div>
|
|
</div>
|
|
<table style="clear:both" border=0 cellpadding=0 cellspacing=0 width="100%" >
|
|
<tr>
|
|
<td style="padding-left:10px;padding-right:10px;" >' . $content . '</td>
|
|
</tr>'
|
|
. (isset($comments[0]) ? '
|
|
<tr>
|
|
<td>
|
|
<div style="text-align: right; margin-right: 10px;"><a href="' . $comments . '">» Comment on this news</a></div>
|
|
</td>
|
|
</tr>' : '') .
|
|
'</table><br/>';
|
|
}
|
|
?>
|