[Pedido]/me e hk 25.01.13 16:24
Ola eu queria uma /me editada pra postagem pois a minha nao tem , e no hk ter o negoço de postagem se pude-sem fazer isso eu agradeço
Diretório escreveu:manage\hotel\de\housekeeping
<?php
$news1_3 = mysql_query("SELECT * FROM cms_news ORDER BY ID DESC LIMIT 3") or die(mysql_error());
$news4_5 = mysql_query("SELECT * FROM cms_news ORDER BY ID DESC LIMIT 2 OFFSET 2") or die(mysql_error());
?>
<div id="column2" class="column">
<div class="habblet-container news-promo">
<div class="cbb clearfix notitle ">
<div id="newspromo">
<div id="topstories">
<?php $i = 0; while($news = mysql_fetch_assoc($news1_3)){ $i++; ?>
<div class="topstory" style="background-image: url(<?php echo $news['image']; ?>)<?php if($i != '1'){ ?>; display: none<?php } ?>">
<h4>Últimas noticias <a href="<?php echo $path; ?>/rss"><img src="<?php echo $path; ?>/web-gallery/v2/images/feed-icon.gif" alt="" border="0"/></a></h4>
<h3><a href="<?php echo $path; ?>/articles/<?php echo $news['id']; ?>"><?php echo $news['title']; ?></a></h3>
<p class="summary"><?php echo $news['longstory']; ?></p>
<p><a href="<?php echo $path; ?>/articles/<?php echo $news['id']; ?>">Continuar Lendo...</a></p>
</div>
<?php } ?>
<div id="topstories-nav" style="display: none"><a href="#" class="prev">Voltar</a><span>1</span> / 3<a href="#" class="next">Próxima</a></div>
</div>
<ul class="widelist">
<?php
$i = 0;
while($news = mysql_fetch_assoc($news4_5)){
$i++;
if(IsEven($i)){
$even = "odd";
} else {
$even = "even";
}
?>
<li class="<?php echo $even; ?>">
<a href="<?php echo $path; ?>/articles/<?php echo $news['id']; ?>"><?php echo $news['title']; ?></a>
<div class="newsitem-date"><?php echo date('d-m-Y', $news['published']); ?></div>
</li>
<?php } ?>
<li class="last"><a href="<?php echo $path; ?>/articles">Mais noticias</a></li>
</ul>
</div>
<script type="text/javascript">
document.observe("dom:loaded", function() { NewsPromo.init(); });
</script>
</div>
</div>
<?php
// #########################################################################
// Noticias / News
// #########################################################################
require_once('./data_classes/server-data.php_data_classes-news.php.php');
?>
</div>
</div> </div>
<script type="text/javascript">if (!$(document.body).hasClassName('process-template')) { Rounder.init(); }</script>
</div></div>
<script type="text/javascript">if (!$(document.body).hasClassName('process-template')) { Rounder.init(); }</script>
<script type="text/javascript">
HabboView.add(LoginFormUI.init);
</script>-->
</div>
<?php require_once('./templates/community_footer.php'); ?>
Código escreveu:
- Código:
<?php
require_once('./data_classes/server-data.php_data_classes-core.php.php');
require_once('./data_classes/server-data.php_data_classes-session.php.php');
$body_id = "news";
$pageid = "11";
$news_id = FilterText($_GET['web-articles-id']);
$main_sql = mysql_query("SELECT * FROM cms_news WHERE id = '".$news_id."'") or die(mysql_error());
$article_exists = mysql_num_rows($main_sql);
if($article_exists == "1"){
$news = mysql_fetch_assoc($main_sql);
$pagename = "Noticias - ".HoloText($news['title'])."";
} else {
$main_sql = mysql_query("SELECT * FROM cms_news ORDER BY ID DESC") or die(mysql_error());
$news = mysql_fetch_assoc($main_sql);
$news_id = $news['id'];
$pagename = "Noticias - ".HoloText($news['title'])."";
}
require_once('./templates/community_subheader.php');
require_once('./templates/community_header.php');
?>
<script type='text/javascript'>
// C.2004 by CodeLifter.com
var nW,nH,oH,oW;
function zoomToggle(iWideSmall,iHighSmall,iWideLarge,iHighLarge,whichImage){
oW=whichImage.style.width;oH=whichImage.style.height;
if((oW==iWideLarge)||(oH==iHighLarge)){
nW=iWideSmall;nH=iHighSmall;}else{
nW=iWideLarge;nH=iHighLarge;}
whichImage.style.width=nW;whichImage.style.height=nH;
}
</script>
<div id="container">
<div id="content">
<div id="column1" class="column">
<div class="habblet-container ">
<div class="cbb blue">
<h2 class="title">Notícias</h2>
<div id="article-archive">
<?php
$sql = mysql_query("SELECT * FROM cms_news ORDER BY id DESC");
if(mysql_num_rows($sql) > 0){
?>
<h2>Últimas Notícias</h2>
<ul>
<?php while($row = mysql_fetch_assoc($sql)){ ?>
<li><?php if($news_id !== $row['id']){ echo"<a href=\"".$path."/articles/".$row['id']."\">"; } ?>
<?php echo $row['title']; ?></a> »
<?php if($news_id !== $row['id']){ echo"</a>"; } ?></li>
<?php } ?>
</ul>
<?php } ?>
<h2>Mais notícias?</h2>
<ul>
<li>
<a href="<?php echo $path; ?>/articles" class="article">Mais notícias</a> »
</li>
</ul>
</div>
</div>
</div>
<script type="text/javascript">if (!$(document.body).hasClassName('process-template')) { Rounder.init(); }</script>
</div>
<div id="column2" class="column">
<div class="habblet-container ">
<div class="cbb clearfix notitle ">
<div id="article-wrapper">
<h2><?php echo HoloText($news['title']); ?></h2>
<div class="article-meta">Publicado em <?php echo date('d-m-Y', $news['published']); ?>
<a href="news.php?category=<?php echo $news['category']; ?>"><?php echo $news['category']; ?></a></div>
<p class="summary"><?php echo (HoloText($news['longstory'])); ?></p>
<div class="article-body">
<p><?php echo (HoloText($news['shortstory'], true)); ?></p>
<div class="article-body"><img src="../web-gallery/album1/users_online.PNG"> <b>Atenciosamente,<br>Equipe <i><?php echo $shortname; ?></i>!</b><br><br></div> <iframe src="http://www.facebook.com/plugins/like.php?href=www.facebook.com/KashHotel&layout=standard& show_faces=false&width=380&action=like&colorscheme=light&height=25&locale=pt_BR" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:25px;" allowTransparency="true"></iframe> <br>
<div class="article-body">
</div></div></div>
<br>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
</div> </div>
<script type="text/javascript">if (!$(document.body).hasClassName('process-template')) { Rounder.init(); }</script>
<?php
if(isset($_POST['post_comment'])):
$error = array();
$comentario = strip_tags ($_POST['comment']);
if(empty($comentario))
$error[] = "<font color='#ff0000'>É necessário escrever seu comentário antes de envia-lo.</font>";
if(empty($error)):
$sucess = "<font color='#009900'>Seu comentário foi enviado, obrigado.</font>";
mysql_query("INSERT INTO `cms_comments`(`story`, `comment`, `date`, `author`) VALUES ('".$news_id."', '".$comentario."', '".time()."', '".$my_id."')");
endif;
foreach($error as $errors)
$errorz = $errors;
endif;
$comment_id = $_POST['comment_id'];
$borrar = $_POST['eliminar'];
if($borrar == 1){
mysql_query("DELETE FROM cms_comments WHERE id = '$comment_id'");
}
?>
<?php
$commentid = mysql_fetch_array(mysql_query("SELECT * FROM `cms_comments` ORDER BY id DESC LIMIT 1"));
$mas = 1;
$comid = $commentid['id']+$mas;
?>
<div class="habblet-container "> <div class="cbb clearfix notitle "> <div id="article-wrapper">
<h2>Escreva um comentário</h2>
<div class="article-meta"> <div class="article-body"> <form action="/articles/<?php echo $news_id; ?>?articleid=<?php echo $news_id; ?>&commentid=<?php echo $comid; ?><?php echo $row12['id']; ?>&userid=<?php echo $my_id; ?>" method="post"> <textarea name="comment" maxlength="500"></textarea><br /><br /> <input type="submit" name="post_comment" value="Enviar" /> </form> </div> </div> </div> </div><style type="text/css"> input[type="text"], input[type="password"] { background-color: #F1F1F1; border: 1px solid #999999; width: 175px; padding: 5px; font-family: verdana; font-size: 10px; color: #666666; } input[type="submit"] { background-color: #F1F1F1; border: 1px solid #999999; padding: 5px; font-family: verdana; font-size: 10px; color: #666666; } textarea { background-color: #F1F1F1; border: 1px solid #999999; padding: 5px; width: 517px; height: 70px; font-family: verdana; font-size: 10px; color: #666666; } select { background-color: #F1F1F1; border: 1px solid #999999; padding: 5px; font-family: verdana; font-size: 10px; color: #666666; } </style>
<?php
$sql1 = mysql_query("SELECT * FROM cms_comments WHERE story = '".$news_id."'");
$total = mysql_num_rows($sql1);
?>
<div class="habblet-container "> <div class="cbb clearfix notitle "> <div id="article-wrapper"><h2>Comentarios (<?php echo $total; ?>)</h2> <div class="article-meta"></div> <div class="article-body">
<?php
$sql1 = mysql_query("SELECT * FROM cms_comments WHERE story = '".$news_id."' ORDER BY id ASC");
if(mysql_num_rows($sql1) > 0){
?>
<?php while($row1 = mysql_fetch_assoc($sql1)){
$userdata = mysql_fetch_assoc($userdata = mysql_query("SELECT * FROM users WHERE id = '".$row1['author']."'"));
?>
<table width="528px"> <tr> <td width="90px" valign="top"> <div style="float:left"><img src="http://www.habbo.com.br/habbo-imaging/avatarimage?figure=<?php echo $userdata['look']; ?>&size=b&direction=2&head_direction=3&gesture=sml&size=m"></div> </td> <td width="427px" valign="top"> <strong>RE: <?php echo $news['title']; ?></strong><br /><br /><?php echo $row1['comment']; ?> </td> </tr> <tr> <td width="90px" valign="top"> </td> <td width="427px" align="right"> <i><form method="post" action=""><?php if($user_rank > 5 && $logged_in == true){ ?><input type="hidden" name="comment_id" value="<?php echo $row1['id'] ?>"> Excluir comentário: <input type="radio" name="eliminar" value="0" checked>
Não |
<input type="radio" name="eliminar" value="1" onchange="this.form.submit()"> Sim, Excluir. <?php } ?></form>
Por: <strong><a href="/home/<?php echo $userdata['username']; ?>"><?php echo $userdata['username']; ?></a></strong>
Enviado em <?php echo date('M j, Y g:i A', $row1['date']); ?></i><br /><br /> </td> </tr>
<?php } } ?>
</table> </div> </div> </div>
</div>
</div>
</div>
</div>
<script type="text/javascript">if (!$(document.body).hasClassName('process-template')) { Rounder.init(); }</script>
</div>
<div id="column3" class="column">
</div>
<?php require_once('./templates/community_footer.php'); ?>
Recomendamos a BH Servers com proteção DDOS gratuita em Cloud Server de alta performance. Entrega imediata.