session_name("AdecigaSite2013"); session_start(); include ("configuracao.php"); include ("script/biblioteca.php"); $id = $_GET['id']; $npag = ($id > 0) ? 4 : 12; $limite_pagina = 20; if (!$ipag) { $ipag = 0; } $QueryNoticia = mysql_query("SELECT * FROM noticia WHERE status = 1 ORDER BY data DESC, id_noticia DESC LIMIT $ipag,$npag") or die(mysql_error()); $QueryCount = mysql_query("SELECT COUNT(*) FROM noticia WHERE status = 1") or die (mysql_error()); $cpag = mysql_fetch_array($QueryCount); $cpag = $cpag[0]; $cont = 0; ?>