Agenda |
$sql = "SELECT * FROM agenda ORDER by data LIMIT 3";
$query = mysql_query($sql);
$info = mysql_fetch_array($query);
$totalRows_info = mysql_num_rows($query);
?>
$sql1 = "SELECT * FROM agenda";
$query1 = mysql_query($sql1);
$totalRows_info1 = mysql_num_rows($query1);
?>
if ($totalRows_info1 > 3 ){
echo " :: mais eventos";
}
?>
|
|
|
$sql = "SELECT * FROM destaque WHERE id=1";
$query = mysql_query($sql);
$info = mysql_fetch_array($query);
$totalRows_info = mysql_num_rows($query);
?>
Destaque |
|
|
$sql = "SELECT * FROM noticias ORDER BY id DESC LIMIT 1";
$query = mysql_query($sql);
$info = mysql_fetch_array($query);
$totalRows_info = mysql_num_rows($query);
?>
Noticias |
|
echo substr($info['texto'],0,100); ?> ... |
|
|
|
$sql1 = "SELECT * FROM noticias";
$query1 = mysql_query($sql1);
$totalRows_info1 = mysql_num_rows($query1);
?>
if ($totalRows_info1 > 1 ){
echo " :: mais noticias";
}
?>
|
|
|
|