Ir para conteúdo
  • Cadastre-se

(Resolvido)Erro no Gesior


Ir para solução Resolvido por luanluciano93,

Posts Recomendados

Olá pessoal do TK, como estão?

 

Então, venho perguntar pra vocês, como eu lido com esse erro chato ?

Resumindo, eu criei um servidor, importei a database pro phpmyadmin, e baixei o Gesior do Matheus, quando fui importar a database,

com esse comando: 

 
INSERT INTO `accounts` (`id`, `name`, `password`, `salt`, `premdays`, `lastday`, `email`, `key`, `blocked`, `warnings`, `group_id`, `page_lastday`, `email_new`, `email_new_time`, `created`, `rlname`, `location`, `page_access`, `email_code`, `next_email`, `premium_points`, `vote`, `last_post`, `flag`, `vip_time`, `guild_points`, `guild_points_stats`) VALUES
(1, '1', 'kiiugttgmm8', '', 65535, 0, '', '0', 0, 0, 1, 0, '', 0, 1374647117, '', '', 999999, '0', 0, 0, 0, 0, '', 0, 0, 0),
(1426839, '10', 'Android', '', 2, 1401333989, '[email protected]', '0', 0, 0, 1, 0, '', 0, 1401333940, '', '', 0, '0', 0, 0, 0, 0, '', 0, 0, 0);
 

Deu esse erro:

#1054 - Unknown column 'page_lastday' in 'field list' 

 

Então revirei o google, achei alguns posts aqui mesmo do TK, mas nenhum resolveu meu erro,

sem alguem puder me ajudar, fico grato, e ja sabe né, aquele rep+++

 

Valeu!!

Editado por shntutor (veja o histórico de edições)
Link para o post
Compartilhar em outros sites

 

Execute esse comando no phpmyadmin em sua database:

ALTER TABLE `accounts` ADD `page_lastday` int(11);

 

Valeu, adicionei todas as tables certinho, estava faltando quase todas, agora está com outro erro, no mesmo comando

 

#1062 - Duplicate entry '1' for key 'PRIMARY' 

 

Já vou aproveitar e perguntar outra coisa, hahaha

Eu ainda não puxei a database do site pro localhost/phpmyadmin, pois está dando esse erro acima

porém quando eu entro no localhost/phpmyadmin, da esse erro:

 

Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[42S02]: Base table or view not found: 1146 Table 'greek.z_news_tickers' doesn't exist' in C:\xampp\htdocs\latestnews.php:80 Stack trace: #0 C:\xampp\htdocs\latestnews.php(80): PDO->query('SELECT * FROM `...') #1 C:\xampp\htdocs\index.php(72): include('C:\xampp\htdocs...') #2 {main} thrown in C:\xampp\htdocs\latestnews.php on line 80

 

Não sei se tem algo a ver com a database não está pronta ainda, mas anyways, estou postando este erro ^^

Aqui está o lastnews.php:   (a linha em negrito itálico com fonte maior é a linha 80)

<?PHP
date_default_timezone_set('America/Sao_Paulo');
//######################## SHOW TICKERS AND NEWS #######################
if ($logged){
$players_from_account = $SQL->query("SELECT `players`.`name`, `players`.`id` FROM `players` WHERE `players`.`account_id` = ".(int) $account_logged->getId())->fetchAll();
foreach($players_from_account as $player)
    {
        $str .= '<option value="'.$player['id'].'"';
            if($player['id'] == $char_id)
            $strt .= ' selected="selected"';
            $str .= '>'.$player['name'].'</option>';
    }
}
$time = time();
$news_content .= '<div id="newsticker" class="Box">
<div class="Corner-tl" style="background-image: url('.$layout_name.'/images/content/corner-tl.gif);"></div>
<div class="Corner-tr" style="background-image: url('.$layout_name.'/images/content/corner-tr.gif);"></div>
<div class="Border_1" style="background-image: url('.$layout_name.'/images/content/border-1.gif);"></div>
<div class="BorderTitleText" style="background-image: url('.$layout_name.'/images/content/title-background-green.gif);"></div>
<img class="Title" src="headline.php?text=News ticker" alt="Contentbox headline">
<div class="Border_2">
<div class="Border_3">
<div class="BoxContent" style="background-image: url('.$layout_name.'/images/content/scroll.gif);">';
//##################### ADD NEW TICKER #####################
if($action == "newticker") {
if($group_id_of_acc_logged >= $config['site']['access_tickers']) {
$ticker_text = stripslashes(trim($_POST['new_ticker']));
$ticker_icon = (int) $_POST['icon_id'];
if(empty($ticker_text)) {
$news_content .= 'You can\'t add empty ticker.';
}
else
{
if(empty($ticker_icon)) {
$news_icon = 0;
}
$SQL->query('INSERT INTO '.$SQL->tableName('z_news_tickers').' (date, author, image_id, text, hide_ticker) VALUES ('.$SQL->quote($time).', '.$account_logged->getId().', '.$ticker_icon.', '.$SQL->quote($ticker_text).', 0)');
$news_content .= '<center><h2><font color="red">Added new ticker:</font></h2></center><hr/>
<div id="newsticker" class="Box">
<div id="TickerEntry-1" class="Row" onclick=\'TickerAction("TickerEntry-1")\'>
<div class="Odd">
<div class="NewsTickerIcon" style="background-image: url('.$layout_name.'/images/news/icon_'.$ticker['image_id'].'.gif);"></div>
<div id="TickerEntry-1-Button" class="NewsTickerExtend" style="background-image: url('.$layout_name.'/images/general/plus.gif);"></div>
<div class="NewsTickerText">
<span class="NewsTickerDate">'.date("j M Y", $time).' -</span>
<div id="TickerEntry-1-ShortText" class="NewsTickerShortText">';
$news_content .= '<a href="?subtopic=latestnews&action=deleteticker&id='.$time.'"><img src="'.$layout_name.'/images/news/delete.png" border="0"></a>';
$news_content .= short_text($ticker_text, 60).'
</div>
<div id="TickerEntry-1-FullText" class="NewsTickerFullText">';
$news_content .= '<a href="?subtopic=latestnews&action=deleteticker&id='.$time.'"><img src="'.$layout_name.'/images/news/delete.png" border="0"></a>';
$news_content .= $ticker_text.'
</div>
</div>
</div>
</div>
</div><hr/>';
}
}
else
{
$news_content .= 'You don\'t have admin rights. You can\'t add new ticker.';
}
$news_content .= '<form action="?subtopic=latestnews" METHOD="post"><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$layout_name.'/images/buttons/_sbutton_back.gif" ></div></div></form>';
}
//#################### DELETE (HIDE only!) TICKER ############################
if($action == "deleteticker") {
if($group_id_of_acc_logged >= $config['site']['access_tickers']) {
header("Location: ");
$date = (int) $_REQUEST['id'];
$SQL->query('UPDATE '.$SQL->tableName('z_news_tickers').' SET hide_ticker = 1 WHERE '.$SQL->fieldName('date').' = '.$date.';');
$news_content .= '<center>News tickets with <b>date '.date("j M Y", $date).'</b> has been deleted.<form action="?subtopic=latestnews" METHOD=post><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$layout_name.'/images/buttons/_sbutton_back.gif" ></div></div></form></center>';
}
else
{
$news_content .= '<center>You don\'t have admin rights. You can\'t delete tickers.<form action="?subtopic=latestnews" METHOD=post><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$layout_name.'/images/buttons/_sbutton_back.gif" ></div></div></form></center>';
}
}
//show tickers if any in database or not blocked (tickers limit = 0)
$tickers = $SQL->query('SELECT * FROM `z_news_tickers` WHERE hide_ticker != 1 ORDER BY date DESC LIMIT 5;');
$number_of_tickers = 0;
if(is_object($tickers)) {
foreach($tickers as $ticker) {
if(is_int($number_of_tickers / 2))
$color = "Odd";
else
$color = "Even";
$tickers_to_add .= '
<div id="TickerEntry-'.$number_of_tickers.'" class="Row" onclick=\'TickerAction("TickerEntry-'.$number_of_tickers.'")\'>
<div class="'.$color.'">
<div class="NewsTickerIcon" style="background-image: url('.$layout_name.'/images/news/icon_'.$ticker['image_id'].'.gif);"></div>
<div id="TickerEntry-'.$number_of_tickers.'-Button" class="NewsTickerExtend" style="background-image: url('.$layout_name.'/images/general/plus.gif);"></div>
<div class="NewsTickerText">
<span class="NewsTickerDate">'.date("j M Y", $ticker['date']).' -</span>
<div id="TickerEntry-'.$number_of_tickers.'-ShortText" class="NewsTickerShortText">';
//if admin show button to delete (hide) ticker
if($group_id_of_acc_logged >= $config['site']['access_admin_panel']) {
$tickers_to_add .= '<a href="?subtopic=latestnews&action=deleteticker&id='.$ticker['date'].'"><img src="'.$layout_name.'/images/news/delete.png" border="0"></a>';
}
$tickers_to_add .= short_text($ticker['text'], 60).'</div>
<div id="TickerEntry-'.$number_of_tickers.'-FullText" class="NewsTickerFullText">';
//if admin show button to delete (hide) ticker
if($group_id_of_acc_logged >= $config['site']['access_admin_panel']) {
$tickers_to_add .= '<a href="?subtopic=latestnews&action=deleteticker&id='.$ticker['date'].'"><img src="'.$layout_name.'/images/news/delete.png" border="0"></a>';
}
$tickers_to_add .= $ticker['text'].'</div>
</div>
</div>
</div>';
$number_of_tickers++;
}
}
if(!empty($tickers_to_add)) {
//show table with tickers
if($group_id_of_acc_logged >= $config['site']['access_admin_panel'] && $action!=newticker)
$news_content .= '<script type="text/javascript">
var showednewticker_state = "0";
function showNewTickerForm()
{
if(showednewticker_state == "0") {
document.getElementById("newtickerform").innerHTML = \'<form action="?subtopic=latestnews&action=newticker" method="post" ><table border="0"><tr><td bgcolor="D4C0A1" align="center"><b>Select icon:</b></td><td><table border="0" bgcolor="F1E0C6"><tr><td><img src="'.$layout_name.'/images/news/icon_0.gif" width="20"></td><td><img src="'.$layout_name.'/images/news/icon_1.gif" width="20"></td><td><img src="'.$layout_name.'/images/news/icon_2.gif" width="20"></td><td><img src="'.$layout_name.'/images/news/icon_3.gif" width="20"></td><td><img src="'.$layout_name.'/images/news/icon_4.gif" width="20"></td></tr><tr><td><input type="radio" name="icon_id" value="0" checked="checked"></td><td><input type="radio" name="icon_id" value="1"></td><td><input type="radio" name="icon_id" value="2"></td><td><input type="radio" name="icon_id" value="3"></td><td><input type="radio" name="icon_id" value="4"></td></tr></table></td></tr><tr><td align="center" bgcolor="D4C0A1"><b>New<br>ticker<br>text:</b></td><td bgcolor="F1E0C6"><textarea name="new_ticker" rows="3" cols="45"></textarea></td></tr><tr><td><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Submit" alt="Submit" src="'.$layout_name.'/images/buttons/_sbutton_submit.gif" ></div></div></form><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><img class="ButtonText" id="AddTicker" src="'.$layout_name.'/images/buttons/_sbutton_cancel.gif" onClick="showNewTickerForm()" alt="AddTicker" /></div></div></td></tr></table>\';
document.getElementById("jajo").innerHTML = \'\';
showednewticker_state = "1";
}
else {
document.getElementById("newtickerform").innerHTML = \'\';
document.getElementById("jajo").innerHTML = \'<div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><img class="ButtonText" id="AddTicker" src="'.$layout_name.'/images/buttons/addticker.gif" onClick="showNewTickerForm()" alt="AddTicker" /></div></div>\';
showednewticker_state = "0";
}
}
</script><div id="newtickerform"></div><div id="jajo"><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><img class="ButtonText" id="AddTicker" src="'.$layout_name.'/images/buttons/addticker.gif" onClick="showNewTickerForm()" alt="AddTicker" /></div></div></div><hr/>';
//add tickers list
$news_content .= $tickers_to_add;
//koniec
}
$news_content .= '</div>
</div>
</div>
<div class="Border_1" style="background-image: url('.$layout_name.'/images/content/border-1.gif);"></div>
<div class="CornerWrapper-b"><div class="Corner-bl" style="background-image: url('.$layout_name.'/images/content/corner-bl.gif);"></div></div>
<div class="CornerWrapper-b"><div class="Corner-br" style="background-image: url('.$layout_name.'/images/content/corner-br.gif);"></div></div>
</div>';
//end of tickers, news part
//adding news
if($action == "newnews") {
if($group_id_of_acc_logged >= $config['site']['access_news']) {
$text = ($_REQUEST['text']);
$char_id = (int) $_REQUEST['char_id'];
$post_topic = stripslashes(trim($_REQUEST['topic']));
$smile = (int) $_REQUEST['smile'];
$news_icon = (int) $_REQUEST['icon_id'];
if(empty($news_icon)) {
$news_icon = 0;
}
if(empty($post_topic)) {
$an_errors[] .= 'You can\'t add news without topic.';
}
if(empty($text)) {
$an_errors[] .= 'You can\'t add empty news.';
}
if(empty($char_id)) {
$an_errors[] .= 'Select character.';
}
//execute query
if(empty($an_errors)) {
$SQL->query("INSERT INTO `z_forum` (`id` ,`first_post` ,`last_post` ,`section` ,`replies` ,`views` ,`author_aid` ,`author_guid` ,`post_text` ,`post_topic` ,`post_smile` ,`post_date` ,`last_edit_aid` ,`edit_date`, `post_ip`, `icon_id`) VALUES ('NULL', '0', '".time()."', '1', '0', '0', '".$account_logged->getId()."', '".(int) $char_id."', ".$SQL->quote($text).", ".$SQL->quote($post_topic).", '".(int) $smile."', '".time()."', '0', '0', '".$_SERVER['REMOTE_ADDR']."', '".$news_icon."')");
$thread_id = $SQL->lastInsertId();
$SQL->query("UPDATE `z_forum` SET `first_post`=".(int) $thread_id." WHERE `id` = ".(int) $thread_id);//show added data
$main_content .= '<form action="?subtopic=latestnews" METHOD=post><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Back" alt="Back" src="'.$layout_name.'/images/buttons/_sbutton_back.gif" ></div></div></form>';
}
else
{
//show errors
$main_content .= '<div class="SmallBox" >  <div class="MessageContainer" >    <div class="BoxFrameHorizontal" style="background-image:url('.$layout_name.'/images/content/box-frame-horizontal.gif);" /></div>    <div class="BoxFrameEdgeLeftTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);" /></div>    <div class="BoxFrameEdgeRightTop" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);" /></div>    <div class="ErrorMessage" >      <div class="BoxFrameVerticalLeft" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);" /></div>      <div class="BoxFrameVerticalRight" style="background-image:url('.$layout_name.'/images/content/box-frame-vertical.gif);" /></div>      <div class="AttentionSign" style="background-image:url('.$layout_name.'/images/content/attentionsign.gif);" /></div><b>The Following Errors Have Occurred:</b><br/>';
foreach($an_errors as $an_error) {
$main_content .= '<li>'.$an_error;
}
$main_content .= '</div>    <div class="BoxFrameHorizontal" style="background-image:url('.$layout_name.'/images/content/box-frame-horizontal.gif);" /></div>    <div class="BoxFrameEdgeRightBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);" /></div>    <div class="BoxFrameEdgeLeftBottom" style="background-image:url('.$layout_name.'/images/content/box-frame-edge.gif);" /></div>  </div></div><br/>';
//okno edycji newsa z wpisanymi danymi przeslanymi wczesniej
$main_content .= '<form action="?subtopic=latestnews&action=newnews" method="post" ><table border="0"><tr><td bgcolor="D4C0A1" align="center"><b>Select icon:</b></td><td><table border="0" bgcolor="F1E0C6"><tr><td><img src="'.$layout_name.'/images/news/icon_0.gif" width="20"></td><td><img src="'.$layout_name.'/images/news/icon_1.gif" width="20"></td><td><img src="'.$layout_name.'/images/news/icon_2.gif" width="20"></td><td><img src="'.$layout_name.'/images/news/icon_3.gif" width="20"></td><td><img src="'.$layout_name.'/images/news/icon_4.gif" width="20"></td></tr><tr><td><input type="radio" name="icon_id" value="0" checked="checked"></td><td><input type="radio" name="icon_id" value="1"></td><td><input type="radio" name="icon_id" value="2"></td><td><input type="radio" name="icon_id" value="3"></td><td><input type="radio" name="icon_id" value="4"></td></tr></table></td></tr><tr><td align="center" bgcolor="F1E0C6"><b>Topic:</b></td><td><input type="text" name="topic" maxlenght="50" style="width: 300px" value="'.$post_topic.'"></td></tr><tr><td align="center" bgcolor="D4C0A1"><b>News<br>text:</b></td><td bgcolor="F1E0C6"><textarea name="text" rows="6" cols="60">'.$text.'</textarea></td></tr><tr><td width="180"><b>Character:</b></td><td><select name="char_id"><option value="0">(Choose character)</option>'.$str.'</select></td></tr><tr><td><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Submit" alt="Submit" src="'.$layout_name.'/images/buttons/_sbutton_submit.gif" ></div></div></form><div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><img class="ButtonText" id="CancelAddNews" src="'.$layout_name.'/images/buttons/_sbutton_cancel.gif" onClick="location.href=\'?subtopic=latestnews\';" alt="CancelAddNews" /></div></div></td></tr></table>';
}
}
else
{
$main_content .= 'You don\'t have site-admin rights. You can\'t add news.';}
}
//####################Show script with new news panel############################
if($group_id_of_acc_logged >= $config['site']['access_news'] && $action != 'newnews')
{
 
$main_content .= '
<font style="font-size: 16px; font-weight: bold; margin-left: 20px;">New News</font>
<form action="?subtopic=latestnews&action=newnews" method="post" >
<table border="0">
<tr>
<td bgcolor="D4C0A1" align="center"><b>Select icon:</b></td>
<td>
<table border="0">
<tr bgcolor="F1E0C6">
<td><img src="'.$layout_name.'/images/news/icon_0.gif" width="20"></td>
<td><img src="'.$layout_name.'/images/news/icon_1.gif" width="20"></td>
<td><img src="'.$layout_name.'/images/news/icon_2.gif" width="20"></td>
<td><img src="'.$layout_name.'/images/news/icon_3.gif" width="20"></td>
<td><img src="'.$layout_name.'/images/news/icon_4.gif" width="20"></td>
</tr>
<tr bgcolor="D4C0A1">
<td><input type="radio" name="icon_id" value="0" checked="checked"></td>
<td><input type="radio" name="icon_id" value="1" /></td>
<td><input type="radio" name="icon_id" value="2" /></td>
<td><input type="radio" name="icon_id" value="3" /></td>
<td><input type="radio" name="icon_id" value="4" /></td>
</tr>
</table>
</td>
</tr>
<tr>
<td align="center" bgcolor="F1E0C6"><b>Topic:</b></td>
<td><input type="text" name="topic" maxlenght="50" style="width: 300px" ></td>
</tr>
<tr>
<td align="center" bgcolor="D4C0A1"><b>News<br>text:</b></td>
<td bgcolor="F1E0C6"><textarea name="text" rows="6" cols="60"></textarea></td>
</tr>
<tr>
<td width="180"><b>Character:</b></td>
<td><select name="char_id"><option value="0">(Choose character)</option>'.$str.'</select></td>
</tr>
<tr>
<td>
<div class="BigButton" style="background-image:url('.$layout_name.'/images/buttons/sbutton.gif)" ><div onMouseOver="MouseOverBigButton(this);" onMouseOut="MouseOutBigButton(this);" ><div class="BigButtonOver" style="background-image:url('.$layout_name.'/images/buttons/sbutton_over.gif);" ></div><input class="ButtonText" type="image" name="Submit" alt="Submit" src="'.$layout_name.'/images/buttons/_sbutton_submit.gif" ></div></div></form></td></tr>
</table>
<hr/>';
$zapytanie = $SQL->query("SELECT `z_forum`.`icon_id`,`z_forum`.`post_topic`, `z_forum`.`author_guid`, `z_forum`.`post_date`, `z_forum`.`post_text`, `z_forum`.`id`, `z_forum`.`replies`, `players`.`name` FROM `z_forum`, `players` WHERE `section` = '1' AND `z_forum`.`id` = `first_post` AND `players`.`id` = `z_forum`.`author_guid` ORDER BY `post_date` DESC LIMIT 3;")->fetchAll();
}
///show news
$announcements = $SQL->query("SELECT * FROM `announcements` WHERE id ORDER BY `date` DESC LIMIT 1");
foreach ($announcements as $announcementsRow){
$news_content .= '<div id="featuredarticle" class="Box">
<div class="Corner-tl" style="background-image:url('.$layout_name.'/images/content/corner-tl.gif);"></div>
<div class="Corner-tr" style="background-image:url('.$layout_name.'/images/content/corner-tr.gif);"></div>
<div class="Border_1" style="background-image:url('.$layout_name.'/images/content/border-1.gif);"></div>
<div class="BorderTitleText" style="background-image:url('.$layout_name.'/images/content/title-background-green.gif);"></div>
<img class="Title" src="headline.php?text=Announcement" alt="Contentbox headline" />
<div class="Border_2">
<div class="Border_3">
<div class="BoxContent" style="background-image:url('.$layout_name.'/images/content/scroll.gif);">
<div id="TeaserThumbnail"><img src="images/news/announcement.jpg" width="150" height="100" border="0" alt="" /></div>
<div id="TeaserText">
<div style="position: relative; margin-bottom: 2px;" >
<div style="font-size:18px; font-weight:bold;">'.$announcementsRow['title'].'</div>
</div>
'.$announcementsRow['text'].'
<br />
<br />
<small style="float: right;">Posted by <font color="red">'.$announcementsRow['author'].'</font> - '.date("d M Y", $announcementsRow['date']).'</small>';
if ($logged)if ($account_logged->getCustomField("page_access") > 6 ){ $news_content .='<input type="button" value="Deletar" OnClick="location.href=\'?subtopic=cpanel&action=deletar_ann&id='.$announcementsRow['id'].'\'" />';} 
$news_content .='
</div>
</div>
</div>
</div>
 
<div class="Border_1" style="background-image:url('.$layout_name.'/images/content/border-1.gif);"></div>
<div class="CornerWrapper-b"><div class="Corner-bl" style="background-image:url('.$layout_name.'/images/content/corner-bl.gif);"></div></div>
<div class="CornerWrapper-b"><div class="Corner-br" style="background-image:url('.$layout_name.'/images/content/corner-br.gif);"></div></div>
</div>
';
}
 
$main_content .= '<div class="NewsHeadline"> 
    <div class="NewsHeadlineBackground" style="background-image:url(' . $layout_name . '/images/news/newsheadline_background.gif)">
        <table border="0"> 
        <tr> 
        <td style="text-align: center; font-weight: bold;"> 
            <div class="MostHeadlineText"><font color="white">Most powerfull guilds</font></div> 
        </td> 
        </tr> 
        </table> 
        </div> 
</div> 
<table border="0" cellspacing="3" cellpadding="4" width="100%"> 
        <tr>'; 
 
foreach($SQL->query('SELECT `g`.`id` AS `id`, `g`.`name` AS `name`, 
        `g`.`logo_gfx_name` AS `logo`, COUNT(`g`.`name`) as `frags` 
FROM `killers` k 
        LEFT JOIN `player_killers` pk ON `k`.`id` = `pk`.`kill_id` 
        LEFT JOIN `players` p ON `pk`.`player_id` = `p`.`id` 
        LEFT JOIN `guild_ranks` gr ON `p`.`rank_id` = `gr`.`id` 
        LEFT JOIN `guilds` g ON `gr`.`guild_id` = `g`.`id` 
WHERE `k`.`unjustified` = 1 AND `k`.`final_hit` = 1 
        GROUP BY `name` 
        ORDER BY `frags` DESC, `name` ASC 
        LIMIT 0, 4;') as $guild) 
        $main_content .= '        <td style="width: 25%; text-align: center;"> 
                        <a href="?subtopic=guilds&action=show&guild=' . $guild['id'] . '"><img src=guilds/' . ((!empty($guild['logo]) && file_exists('guilds/' . $guild['logo'])) ? $guild['logo'] : 'default_logo.gif') . '" width=64" height="64" border="0"/><br />' . $guild['name] . '</a><br />' . $guild['frags'] . ' kills 
                </td>'; 
 
$main_content .= '    </tr> 
</table>';  
 
//
$zapytanie = $SQL->query("SELECT `z_forum`.`icon_id`, `z_forum`.`post_topic`, `z_forum`.`author_guid`, `z_forum`.`post_date`, `z_forum`.`post_text`, `z_forum`.`id`, `z_forum`.`replies`, `players`.`name` FROM `z_forum`, `players` WHERE `section` = '1' AND `z_forum`.`id` = `first_post` AND `players`.`id` = `z_forum`.`author_guid` ORDER BY `post_date` DESC LIMIT 3;")->fetchAll();
foreach ($zapytanie as $row)
{
        $BB = array(
'/\[youtube\](.*?)\[\/youtube\]/is' => '<center><object width="500" height="405"><param name="movie" value="http://www.youtube.com/watch?v=$1&hl=pt-br&fs=1&rel=0&color1=0x3a3a3a&color2=0x999999&border=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/watch?v=$1&hl=pt-br&fs=1&rel=0&color1=0x3a3a3a&color2=0x999999&border=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="500" height="405"></embed></object></center>',
'/\[b\](.*?)\[\/b\]/is' => '<strong>$1</strong>',
'/\[center\](.*?)\[\/center\]/is' => '<center>$1</center>',
'/\
(.*?)\[\/quote\]/is' => '<table cellpadding="0" style="background-color: #c4c4c4; width: 480px; border-style: dotted; border-color: #007900; border-width: 2px"><tr><td>$1</td></tr></table>',

'/\[u\](.*?)\[\/u\]/is' => '<u>$1</u>',

'/\[i\](.*?)\[\/i\]/is' => '<i>$1</i>',

'/\[letter\](.*?)\[\/letter\]/is' => '<img src=images/letters/$1.gif alt=$1 />',

?>

Editado por shntutor (veja o histórico de edições)
Link para o post
Compartilhar em outros sites
CREATE TABLE IF NOT EXISTS `z_news_tickers` (
  `date` int(11) NOT NULL default '1',
  `author` int(11) NOT NULL,
  `image_id` int(3) NOT NULL default '0',
  `text` text NOT NULL,
  `hide_ticker` tinyint(1) NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
Link para o post
Compartilhar em outros sites

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emojis são permitidos.

×   Seu link foi automaticamente incorporado.   Mostrar como link

×   Seu conteúdo anterior foi restaurado.   Limpar o editor

×   Não é possível colar imagens diretamente. Carregar ou inserir imagens do URL.

  • Quem Está Navegando   0 membros estão online

    Nenhum usuário registrado visualizando esta página.

  • Conteúdo Similar

    • Por BonasxD
      Bom galera primeiramente não sei se estou na area correta ou se nao estou, se nao por favor mover para area certa, grato!
      Estou com esse erro ao tenta instalar o gesior usando a tfs 0.4 não passa dessa parte ja tentei de tudo e nao sei oque fazer ;(
       
      Testei o mesmo procedimento no meu Windows e Funcionou corretamente agora no meu VM(Ubuntu22) não passa desse erro. 
       
      Ja pesquisei por tudo e não sei oque fazer

    • Por Kill of sumoners
      Boa noite, estou com um erro ao atacar um player em meu sv eu nao pego pk, nem sai magia, aparece a mensagem "voce so pode usar isso em criaturas"
      obs: magia em area acerta e pega pk, apenas as targets ou hits de arma nao vao 
    • Por Guilherme HP
      ola boa noite, alguem poderia ta me ajudando nesse erro que apareceu na minha vps quando vou abrir o meu game?

      [./tfs: error while loading shared libraries: libluajit-5.1.so.2: cannot open shared object file: No such file or directory]
    • Por Biel249
      Bom dia. Estou passando por esse problema com meu otserver tibia 8.6 eu coloco online tudo certinho portas abertas dmz e dns configurada mas não fica on só eu consigo entrar. Ja entrei em contato com a fornecedora de Internet eles alegaram que meu ip é privado e só conseguiria pagando um ip público. Alguém me ajuda????
×
×
  • Criar Novo...

Informação Importante

Confirmação de Termo