<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);
$fooB1=($_POST['fooB1']);
$fooB4=($_POST['fooB4']);
$fooName=($_POST['fooName']);
$fooPhone=($_POST['fooPhone']);
$fooFax=($_POST['fooFax']);
$fooMobil=($_POST['fooMobil']);
$fooMail=($_POST['fooMail']);
$fooCompany=($_POST['fooCompany']);
$fooCompany2=($_POST['fooCompany2']);
$fooStreet=($_POST['fooStreet']);
$fooCity=($_POST['fooCity']);
$block1image=($_POST['block1image']);
$block1imgURL=($_POST['block1imgURL']);
$block1imgTitle=($_POST['block1imgTitle']);
$block4image=($_POST['block4image']);
$block4imgURL=($_POST['block4imgURL']);
$block4imgTitle=($_POST['block4imgTitle']);
$gooMaps=($_POST['gooMaps']);
$fooCR=($_POST['fooCR']);
$titleFoo1=($_POST['titleFoo1']);
$titleFoo2=($_POST['titleFoo2']);
$titleFoo3=($_POST['titleFoo3']);
$titleFoo4=($_POST['titleFoo4']);

if (isset($_POST['save'])) {
if (strlen(@$_POST[fooB1])<=0){@$_POST[fooB1]="";}
if (strlen(@$_POST[fooB4])<=0){@$_POST[fooB4]="";}
if (strlen(@$_POST[fooName])<=0){@$_POST[fooName]="";}
if (strlen(@$_POST[fooPhone])<=0){@$_POST[fooPhone]="";}
if (strlen(@$_POST[fooFax])<=0){@$_POST[fooFax]="";}
if (strlen(@$_POST[fooMobil])<=0){@$_POST[fooMobil]="";}
if (strlen(@$_POST[fooMail])<=0){@$_POST[fooMail]="";}
if (strlen(@$_POST[fooCompany])<=0){@$_POST[fooCompany]="";}
if (strlen(@$_POST[fooCompany2])<=0){@$_POST[fooCompany2]="";}
if (strlen(@$_POST[fooStreet])<=0){@$_POST[fooStreet]="";}
if (strlen(@$_POST[fooCity])<=0){@$_POST[fooCity]="";}
if (strlen(@$_POST[block1image])<=0){@$_POST[block1image]="";}
if (strlen(@$_POST[block1imgURL])<=0){@$_POST[block1imgURL]="";}
if (strlen(@$_POST[block1imgTitle])<=0){@$_POST[block1imgTitle]="";}
if (strlen(@$_POST[block4image])<=0){@$_POST[block4image]="";}
if (strlen(@$_POST[block4imgURL])<=0){@$_POST[block4imgURL]="";}
if (strlen(@$_POST[block4imgTitle])<=0){@$_POST[block4imgTitle]="";}
if (strlen(@$_POST[gooMaps])<=0){@$_POST[gooMaps]="";}
if (strlen(@$_POST[fooCR])<=0){@$_POST[fooCR]="";}
if (strlen(@$_POST[titleFoo1])<=0){@$_POST[titleFoo1]="";}
if (strlen(@$_POST[titleFoo2])<=0){@$_POST[titleFoo2]="";}
if (strlen(@$_POST[titleFoo3])<=0){@$_POST[titleFoo3]="";}
if (strlen(@$_POST[titleFoo4])<=0){@$_POST[titleFoo4]="";}
$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]='/fooB1=(.+?);/';
$patterns[1]='/fooB4=(.+?);/';
$patterns[2]='/fooName=(.+?);/';
$patterns[3]='/fooPhone=(.+?);/';
$patterns[4]='/fooFax=(.+?);/';
$patterns[5]='/fooMobil=(.+?);/';
$patterns[6]='/fooMail=(.+?);/';
$patterns[7]='/fooCompany=(.+?);/';
$patterns[8]='/fooCompany2=(.+?);/';
$patterns[9]='/fooStreet=(.+?);/';
$patterns[10]='/fooCity=(.+?);/';
$patterns[11]='/block1image=(.+?);/';
$patterns[12]='/block1imgURL=(.+?);/';
$patterns[13]='/block1imgTitle=(.+?);/';
$patterns[14]='/block4image=(.+?);/';
$patterns[15]='/block4imgURL=(.+?);/';
$patterns[16]='/block4imgTitle=(.+?);/';
$patterns[17]='/gooMaps=(.+?);/';
$patterns[18]='/fooCR=(.+?);/';
$patterns[19]='/titleFoo1=(.+?);/';
$patterns[20]='/titleFoo2=(.+?);/';
$patterns[21]='/titleFoo3=(.+?);/';
$patterns[22]='/titleFoo4=(.+?);/';

@$replacements[0]=sprintf("fooB1=%s%s%s;",$t,$_POST[fooB1],$t);
@$replacements[1]=sprintf("fooB4=%s%s%s;",$t,$_POST[fooB4],$t);
@$replacements[2]=sprintf("fooName=%s%s%s;",$t,$_POST[fooName],$t);
@$replacements[3]=sprintf("fooPhone=%s%s%s;",$t,$_POST[fooPhone],$t);
@$replacements[4]=sprintf("fooFax=%s%s%s;",$t,$_POST[fooFax],$t);
@$replacements[5]=sprintf("fooMobil=%s%s%s;",$t,$_POST[fooMobil],$t);
@$replacements[6]=sprintf("fooMail=%s%s%s;",$t,$_POST[fooMail],$t);
@$replacements[7]=sprintf("fooCompany=%s%s%s;",$t,$_POST[fooCompany],$t);
@$replacements[8]=sprintf("fooCompany2=%s%s%s;",$t,$_POST[fooCompany2],$t);
@$replacements[9]=sprintf("fooStreet=%s%s%s;",$t,$_POST[fooStreet],$t);
@$replacements[10]=sprintf("fooCity=%s%s%s;",$t,$_POST[fooCity],$t);
@$replacements[11]=sprintf("block1image=%s%s%s;",$t,$_POST[block1image],$t);
@$replacements[12]=sprintf("block1imgURL=%s%s%s;",$t,$_POST[block1imgURL],$t);
@$replacements[13]=sprintf("block1imgTitle=%s%s%s;",$t,$_POST[block1imgTitle],$t);
@$replacements[14]=sprintf("block4image=%s%s%s;",$t,$_POST[block4image],$t);
@$replacements[15]=sprintf("block4imgURL=%s%s%s;",$t,$_POST[block4imgURL],$t);
@$replacements[16]=sprintf("block4imgTitle=%s%s%s;",$t,$_POST[block4imgTitle],$t);
@$replacements[17]=sprintf("gooMaps=%s%s%s;",$t,$_POST[gooMaps],$t);
@$replacements[18]=sprintf("fooCR=%s%s%s;",$t,$_POST[fooCR],$t);
@$replacements[19]=sprintf("titleFoo1=%s%s%s;",$t,$_POST[titleFoo1],$t);
@$replacements[20]=sprintf("titleFoo2=%s%s%s;",$t,$_POST[titleFoo2],$t);
@$replacements[21]=sprintf("titleFoo3=%s%s%s;",$t,$_POST[titleFoo3],$t);
@$replacements[22]=sprintf("titleFoo4=%s%s%s;",$t,$_POST[titleFoo4],$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>
