<div class="box-body">

<div class="padd-lr10">
<div class="box boxStyle2 infoBox margin-b15">
<div class="padd10t">

<table id="tableN" class="col-md-12">
<tr class='tabTop'>
<td colspan="2">

<?PHP 
define("DATA_FILE", $targetedX);
extract($_POST);
$cat0=($_POST['cat0']);
$cat1=($_POST['cat1']);
$cat2=($_POST['cat2']);
$cat3=($_POST['cat3']);
$cat4=($_POST['cat4']);
$cat5=($_POST['cat5']);
$cat6=($_POST['cat6']);

if (isset($_POST['save'])) {
if (strlen(@$_POST[cat0])<=0){@$_POST[cat0]="";}
if (strlen(@$_POST[cat1])<=0){@$_POST[cat1]="";}
if (strlen(@$_POST[cat2])<=0){@$_POST[cat2]="";}
if (strlen(@$_POST[cat3])<=0){@$_POST[cat3]="";}
if (strlen(@$_POST[cat4])<=0){@$_POST[cat4]="";}
if (strlen(@$_POST[cat5])<=0){@$_POST[cat5]="";}
if (strlen(@$_POST[cat6])<=0){@$_POST[cat6]="";}
$Message=SaveData();}
else{
@die ("
<span class='resF'>".$resultFalse."</span>
<br>
<br>
<a href='$elink'>
<div class='vlinkS'>
<i class='hvL fa fa-arrow-circle-right padd-right5'></i>
<span class='hvS'>".$back1."</span>
</div>
</a>
");
return ($tag);
}

function SaveData(){
$tag='';
$patterns=array();
$replacements=array();
$content=file(DATA_FILE);
$t=chr(34);

$patterns[0]='/cat0=(.+?);/';
$patterns[1]='/cat1=(.+?);/';
$patterns[2]='/cat2=(.+?);/';
$patterns[3]='/cat3=(.+?);/';
$patterns[4]='/cat4=(.+?);/';
$patterns[5]='/cat5=(.+?);/';
$patterns[6]='/cat6=(.+?);/';

@$replacements[0]=sprintf("cat0=%s%s%s;",$t,$_POST[cat0],$t);
@$replacements[1]=sprintf("cat1=%s%s%s;",$t,$_POST[cat1],$t);
@$replacements[2]=sprintf("cat2=%s%s%s;",$t,$_POST[cat2],$t);
@$replacements[3]=sprintf("cat3=%s%s%s;",$t,$_POST[cat3],$t);
@$replacements[4]=sprintf("cat4=%s%s%s;",$t,$_POST[cat4],$t);
@$replacements[5]=sprintf("cat5=%s%s%s;",$t,$_POST[cat5],$t);
@$replacements[6]=sprintf("cat6=%s%s%s;",$t,$_POST[cat6],$t);

if ($fp=fopen(DATA_FILE,"w")){
$tag="<?PHP \n";
include("./../languages/$_COOKIE[xlanguage]/general.inc.php");
@print_r("<span class='resT'>".$resultTrue."</span>");
fputs($fp,$tag,strlen($tag));
for ($i=1;$i < count($content);$i++){
$check=$content[$i];
$check=(preg_replace($patterns,$replacements,$check));
$check=preg_replace("/\r|\r/s", "\r", $check);
include("./../function/savecheck.inc.php");
if (strlen($check)> 0) $content[$i]=$check;
$line=sprintf('%s',$content[$i]);
fputs($fp,$line,strlen($line));
}
fclose($fp);
}
}

include("./../function/forward-s-e.inc.php");
include("./../function/autoX.inc.php");
echo "
<br>
<br>
<a href='$elink'>
<div class='vlinkS'>
<i class='hvL fa fa-arrow-circle-right padd-right5'></i>
<span class='hvS'>".$back1."</span>
</div>
</a>
";
?>
</td>
</tr>

</table>
<div class="clearX box-footer"></div>
</div>
</div>
</div>
</div>
