<?php 
session_start(); //SESSION 开始
require_once('../../include/class.inc.php'); 
?>
<?php
$ID=$_GET["ID"];
$Home_t=$_GET["Home"];
$Latest_t=$_GET["Latest"];
	
if($Home_t=="Homeok")
{

	$sql="update news set Home_t='首页推荐' where ID=$ID";
	mysql_query($sql);

	echo "<script>alert('激活成功！');location.href='news.php'</script>";
}
if($Home_t=="Homeno")
{
	$sql="update news set Home_t='HomeNo' where ID=$ID";
	mysql_query($sql);	

	echo "<script>alert('取消激活！');location.href='news.php'</script>";
}

if($Latest_t=="Latestok")
{

	$sql="update news set Latest_t='最新推荐' where ID=$ID";
	mysql_query($sql);

	echo "<script>alert('激活成功！');location.href='news.php'</script>";
}
if($Latest_t=="Latestno")
{
	$sql="update news set Latest_t='LatestNo' where ID=$ID";
	mysql_query($sql);	

	echo "<script>alert('取消激活！');location.href='news.php'</script>";
}
?>