<?
ob_start();
require_once("../lib/func_ar.php");

$idd=$_GET['id'];
$sel = "select active from src_jornal where id='$idd'";
$query = mysql_query($sel);
    while($result = mysql_fetch_array($query)){
    extract($result);
        if($active != 1){
            //change active
            $result = "update src_jornal set active='1' where id='$idd'";
            $query = mysql_query($result);
            header('Location: edit_customer.php');
        }else{
            //change active
            $result = "update src_jornal set active='0' where id='$idd'";
            $query = mysql_query($result);
            header('Location: edit_customer.php');
        }
    }





ob_flush();
?>