Файл: RootPanel 1.7.0 FreeCode/RootPanel 1.7.0 FreeCode/_rootbill/_profile.inc.php
Строк: 1035
<?
if ($profileId == "new" and GetSetting("profileMultiEnable")) {
@mysql_query("INSERT INTO users_profile (uid) VALUES('".$_SESSION["userId"]."')") or die("File: ".__FILE__."<BR>Line: ".__LINE__."<BR>MySQL Error: ".mysql_error());
$profileId = mysql_insert_id();
}
if ($sub == 'edit') {
$object=GetUserProfileByUserId($_SESSION["userId"],$profileId);
$upload_error = "";
$res = array();
if (!$upload_error and $_FILES[userfile1][name]) {
$res[1] = uploadPassportFiles(userfile1,$object->id,"1");
if (!$res[1]) { $upload_error = $_lang[ProfileErrorCantUpload]." 1 ($UploadError)"; }
}
if (!$upload_error and $_FILES[userfile2][name]) {
$res[2] = uploadPassportFiles(userfile2,$object->id,"2");
if (!$res[2]) { $upload_error = $_lang[ProfileErrorCantUpload]." 2 ($UploadError)"; }
}
if (!$upload_error and $_FILES[userfile3][name]) {
$res[3] = uploadPassportFiles(userfile3,$object->id,"3");
if (!$res[3]) { $upload_error = $_lang[ProfileErrorCantUpload]." 3 ($UploadError)"; }
}
if (!$upload_error and $_FILES[userfile4][name]) {
$res[4] = uploadPassportFiles(userfile4,$object->id,"4");
if (!$res[4]) { $upload_error = $_lang[ProfileErrorCantUpload]." 4 ($UploadError)"; }
}
if (!$upload_error and $_FILES[userfile5][name]) {
$res[5] = uploadPassportFiles(userfile5,$object->id,"5");
if (!$res[5]) { $upload_error = $_lang[ProfileErrorCantUpload]." 5 ($UploadError)"; }
}
if (!$upload_error) { if (count($res) > 0) { $passportFiles = @join(":x:",$res); }}
else {
@unlink($full_home_path."/_rootfiles/passport_".$object->id."_1.jpg");
@unlink($full_home_path."/_rootfiles/passport_".$object->id."_2.jpg");
@unlink($full_home_path."/_rootfiles/passport_".$object->id."_3.jpg");
@unlink($full_home_path."/_rootfiles/passport_".$object->id."_4.jpg");
@unlink($full_home_path."/_rootfiles/passport_".$object->id."_5.jpg");
}
$chkProfile = GetSetting("checkprofiletype");
if ($isR) { $chkProfile = "max"; }
else if ($isD and $chkProfile != "max") { $chkProfile = "min"; }
if (!valid_email($email)) {$error="<font color=red>".$_lang[ProfileErrorBadEmail]."</font>";}
else if ($upload_error) {$error="<font color=red>".$upload_error."</font>";}
else if (checkProfile($chkProfile)) {
if ($ripn and !preg_match("/-RIPN$/ui",$ripn)) { $ripn = $ripn."-RIPN"; }
if ($uanic and !preg_match("/-UANIC$/ui",$uanic)) { $uanic = $uanic."-UANIC"; }
if ($ripe and !preg_match("/-RIPE$/ui",$ripe)) { $ripe = $ripe."-RIPE"; }
@mysql_query("UPDATE users_profile SET icq = '$icq', name = '$name', otchestvo = '$otchestvo', firma = '$firma', firmaeng = '$firmaeng', phone = '$phone', fax = '$fax', country = '$country', oblast = '$oblast', city = '$city', post = '$post', street = '$street', address_org = '$address_org', komu = '$komu', pasport_seriya = '$seriya', pasport_by = '$by', ripn = '$ripn', ripe = '$ripe', uanic = '$uanic', surname = '$surname',pasport_date = '".fromMyDate($date)."',birthday = '".fromMyDate($birthday)."',inn = '$inn',kpp = '$kpp',okonh = '$okonh',bank = '$bank',bank_schet = '$bank_schet',bank_bik = '$bank_bik',edrpou='$edrpou',email='$email',org='$org',passportFiles='$passportFiles',socstrahnumber='$socstrahnumber',ogrn='$ogrn' WHERE uid = '".$_SESSION["userId"]."' and id='$profileId'") or die("File: ".__FILE__."<BR>Line: ".__LINE__."<BR>MySQL Error: ".mysql_error());
if (GetSetting("profileSetNotChecked")) {
@mysql_query("UPDATE users_profile SET profileChecked='0' WHERE uid = '".$_SESSION["userId"]."' and id='$profileId'") or die("File: ".__FILE__."<BR>Line: ".__LINE__."<BR>MySQL Error: ".mysql_error());
$profileChecked = 0;
}
if ($fromreg or $bill_id or ($testPeriod and $testPeriodHostId)) {
if (GetSetting("testPeriodEnable") and $testPeriod and $testPeriodHostId) {
if (GetSetting("testPeriodAutoCreate")) {
if (createUser($testPeriodHostId)) {
$testPeriodCreated = 1;
}
}
$testAddon = "&testPeriod=1&testPeriodCreated=$testPeriodCreated";
}
Header("Location: billing.php?do=pay&id=$bill_id$testAddon");
} else {
$error=$_lang[ProfileChangeSuccess];
}
} else {
$error = "<font color=red>".$GLOBALerror."</font>";
}
} else {
$profile=GetUserProfileByUserId($_SESSION["userId"],$profileId);
$chkProfile = GetSetting("checkprofiletype");
if ($isR) { $chkProfile = "max"; }
else if ($isD and $chkProfile != "max") { $chkProfile = "min"; }
checkProfile($chkProfile, $_SESSION["userId"], $profileId);
if ($GLOBALerror and $country and $org) {$error = "<font color=red>".$GLOBALerror."</font>";}
}
_head('utf-8',$_lang[ProfileTitle]);
if (!$fromreg and !$GLOBALerror) {
print "<form method=post style='padding: 0;'><input type=hidden name=do value=$do>";
print $_lang[ProfileYourProfiles].": "; printProfileSelect($_SESSION["userId"],$profileId,1); print " <input class=button type=Submit value='".$_lang[Select]."'>";
print "</form>";
}
if ($error) {print "$error<BR><BR>";}
if ($fromreg) {
print "<table class='rpTableBlank' border=0><tr><td><b>".$_lang[ProfileNeedFromReg];
if ($isD and $country) { print "<br>".$_lang[ProfileFieldsForAllDomains]; }
if ($isR and $country) { print "<br>".$_lang[ProfileFieldsForRuDomain]; }
if ($testPeriod) { print "<br>".$_lang[ProfileNeedForTestPeriod]; }
print "</tr></td></table><BR>";
}
$object=GetUserProfileByUserId($_SESSION["userId"],$profileId);
$t=GetUserById($_SESSION["userId"]);
if ($sub != "edit") {
if ($object->org and $object->country) { $org = $object->org; }
$surname = $object->surname;
$name = $object->name;
$otchestvo = $object->otchestvo;
$firma = $object->firma;
$firmaeng = $object->firmaeng;
$seriya = $object->pasport_seriya;
$by = $object->pasport_by;
$date = mydate($object->pasport_date);
$birthday = mydate($object->birthday);
$inn = $object->inn;
$kpp = $object->kpp;
if ($object->org and $object->country) { $country = $object->country; }
$oblast = $object->oblast;
$post = $object->post;
$city = $object->city;
$street = $object->street;
$address_org = $object->address_org;
$komu = $object->komu;
$phone = $object->phone;
$fax = $object->fax;
$email = $object->email;
$icq = $object->icq;
$ripn = $object->ripn;
$ripe = $object->ripe;
$uanic = $object->uanic;
$okonh = $object->okonh;
$bank = $object->bank;
$bank_schet = $object->bank_schet;
$bank_bik = $object->bank_bik;
$edrpou = $object->edrpou;
$passportFiles = $object->passportFiles;
$profileChecked = $object->profileChecked;
$socstrahnumber = $object->socstrahnumber;
$ogrn = $object->ogrn;
}
if ($org == "3") { $userType = $_lang[ProfileOfOrg]; }
else if ($org == "2") { $userType = $_lang[ProfileOfPrivatePredprinimatel]; }
else { $userType = $_lang[ProfileOfPrivatePerson]; }
print "
<table class='rpTable' border=1 width=95% align=center><form method=post enctype="multipart/form-data">
<tr><th colspan=2 align=center>$userType [$t->login]</th></tr>
<input type=hidden name=do value=$do>";
if ($country and $org) { print "<input type=hidden name=sub value=edit>"; }
print "
<input type=hidden name=fromreg value='$fromreg'>
<input type=hidden name=bill_id value='$bill_id'>
<input type=hidden name=isR value='$isR'>
<input type=hidden name=isD value='$isD'>
<input type=hidden name=profileId value='$object->id'>
<input type=hidden name=profileChecked value='$profileChecked'>
<input type=hidden name=testPeriod value='$testPeriod'>
<input type=hidden name=testPeriodHostId value='$testPeriodHostId'>
";
if ($org) { print "<input type=hidden name=org value='$org'>"; }
$profileDisableChange=GetSetting("profileDisableChange"); $pdc=split("::",$profileDisableChange);
$profileDisableChangeWithPassport=GetSetting("profileDisableChangeWithPassport"); $pdcwp=split("::",$profileDisableChangeWithPassport);
$profileDisableChangeWithProfileCheck=GetSetting("profileDisableChangeWithProfileCheck"); $pdcwpc=split("::",$profileDisableChangeWithProfileCheck);
if ($country and $org) {
if ($org == "3" or ($org == "2" and $country == "FI")) { $contactTitle = $_lang[ProfileDirector]; } else if ($org == "2") { $contactTitle = $_lang[OrderUserPrivatePredprinimatel]; } else { $contactTitle = $_lang[ProfileContact]; }
print "<tr><th colspan=2 align=center><B>".$contactTitle."</b></th></tr>";
print "<tr><th>".$_lang[ProfileSurname].":</th><td><input class=input type=text name=surname value="$surname" size=40 "; if ($surname and (@in_array("surname",$pdc) or ($profileChecked and @in_array("surname",$pdcwpc)) or ($passportFiles and @in_array("surname",$pdcwp)))) { print "readonly"; } print"></td></tr>";
print "<tr><th>".$_lang[ProfileName].":</th><td><input class=input type=text name=name value="$name" size=40 "; if ($name and (@in_array("name",$pdc) or ($profileChecked and @in_array("name",$pdcwpc)) or ($passportFiles and @in_array("name",$pdcwp)))) { print "readonly"; } print"></td></tr>";
print "<tr><th>".$_lang[ProfileOtchestvo].":</th><td><input class=input type=text name=otchestvo value="$otchestvo" size=40 "; if ($otchestvo and (@in_array("otchestvo",$pdc) or ($profileChecked and @in_array("otchestvo",$pdcwpc)) or ($passportFiles and @in_array("otchestvo",$pdcwp)))) { print "readonly"; } print"></td></tr>";
if ($org == "1" and $country == "FI") {print "<tr><th>".$_lang[ProfileSocStrahNumber].":</th><td><input class=input type=text name=socstrahnumber value="$socstrahnumber" size=40 "; if ($socstrahnumber and (@in_array("socstrahnumber",$pdc) or ($profileChecked and @in_array("socstrahnumber",$pdcwpc)) or ($passportFiles and @in_array("socstrahnumber",$pdcwp)))) { print "readonly"; } print"></td></tr>";}
if ($org == "2" and $country == "UA") { print "<tr><th valign=top>".$_lang[ProfileEdrpou].":</th><td><input class=input type=text name=edrpou value="$edrpou" size=40 "; if ($edrpou and (@in_array("edrpou",$pdc) or ($profileChecked and @in_array("edrpou",$pdcwpc)) or ($passportFiles and @in_array("edrpou",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileEdrpouComment]."</td></tr>"; }
else if ($org == "2") { print "<tr><th valign=top>".$_lang[ProfileInn].":</th><td><input class=input type=text name=inn value="$inn" size=40 "; if ($inn and (@in_array("inn",$pdc) or ($profileChecked and @in_array("inn",$pdcwpc)) or ($passportFiles and @in_array("inn",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileInnComment]."</td></tr>"; }
if ($org == "2" and $country == "HU") { print "<tr><td valign=top>".$_lang[ProfileRegNumberPP].":</td><td><input class=input type=text name=ogrn value="$ogrn" size=40 "; if ($ogrn and (@in_array("ogrn",$pdc) or ($profileChecked and @in_array("ogrn",$pdcwpc)) or ($passportFiles and @in_array("ogrn",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileRegNumberPPComment]."</td></tr>"; }
if (($org == "1" or $org == "2") and $country != "FI") {
if (!GetSetting("profilePassportDisabled")) {
print "<tr><th colspan=2 align=center><B>".$_lang[ProfilePassportData]."</b></th></tr>";
print "<tr><th valign=top>".$_lang[ProfilePassportSeriya].":</th><td><input class=input type=text name=seriya value="$seriya" size=40 "; if ($seriya and (@in_array("pasport_seriya",$pdc) or ($profileChecked and @in_array("pasport_seriya",$pdcwpc)) or ($passportFiles and @in_array("pasport_seriya",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfilePassportSeriyaComment]."</td></tr>";
print "<tr><th valign=top>".$_lang[ProfilePassportVidan].":</th><td><input class=input type=text name=by value="$by" size=40 "; if ($by and (@in_array("pasport_by",$pdc) or ($profileChecked and @in_array("pasport_by",$pdcwpc)) or ($passportFiles and @in_array("pasport_by",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfilePassportVidanComment]."</td></tr>";
print "<tr><th>".$_lang[ProfilePassportVidanData].":</th><td><input class=input type=text name=date value="$date" size=40 "; if ($date and $date != "00.00.0000" and (@in_array("pasport_date",$pdc) or ($profileChecked and @in_array("pasport_date",$pdcwpc)) or ($passportFiles and @in_array("pasport_date",$pdcwp)))) { print "readonly"; } print"></td></tr>";
print "<tr><th>".$_lang[ProfileBirthDate].":</th><td><input class=input type=text name=birthday value="$birthday" size=40 "; if ($birthday and $birthday != "00.00.0000" and (@in_array("birthday",$pdc) or ($profileChecked and @in_array("birthday",$pdcwpc)) or ($passportFiles and @in_array("birthday",$pdcwp)))) { print "readonly"; } print"></td></tr>";
}
}
if ($org == "3" or ($org == "2" and $country == "FI")) {
print "<tr><th colspan=2 align=center><B>".$_lang[ProfileOrgData]."</b></th></tr>";
print "<tr><th valign=top>".$_lang[ProfileOrg].":</th><td><input class=input type=text name=firma value="$firma" size=40 "; if ($firma and (@in_array("firma",$pdc) or ($profileChecked and @in_array("firma",$pdcwpc)) or ($passportFiles and @in_array("firma",$pdcwp)))) { print "readonly"; } print"><BR><p style="$styleHelp">".$_lang[ProfileOrgComment]."</td></tr>";
if ($country != "FI") { print "<tr><th valign=top>".$_lang[ProfileOrgEng].":</th><td><input class=input type=text name=firmaeng value="$firmaeng" size=40 "; if ($firmaeng and (@in_array("firmaeng",$pdc) or ($profileChecked and @in_array("firmaeng",$pdcwpc)) or ($passportFiles and @in_array("firmaeng",$pdcwp)))) { print "readonly"; } print"><BR><p style="$styleHelp">".$_lang[ProfileOrgEngComment]."</td></tr>"; }
print "<tr><th valign=top>".$_lang[ProfileYuridAddress].":</th><td><input class=input type=text name=address_org value="$address_org" size=40 "; if ($address_org and (@in_array("address_org",$pdc) or ($profileChecked and @in_array("address_org",$pdcwpc)) or ($passportFiles and @in_array("address_org",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileYuridAddressComment]."</td></tr>";
if ($country != "FI") { print "<tr><th valign=top>".$_lang[ProfileInn].":</th><td><input class=input type=text name=inn value="$inn" size=40 "; if ($inn and (@in_array("inn",$pdc) or ($profileChecked and @in_array("inn",$pdcwpc)) or ($passportFiles and @in_array("inn",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileInnComment2]."</td></tr>"; }
if ($country == "RU") { print "<tr><th valign=top>".$_lang[ProfileKpp].":</th><td><input class=input type=text name=kpp value="$kpp" size=40 "; if ($kpp and (@in_array("kpp",$pdc) or ($profileChecked and @in_array("kpp",$pdcwpc)) or ($passportFiles and @in_array("kpp",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileKppComment]."</td></tr>"; }
if ($country == "RU") { print "<tr><th valign=top>".$_lang[ProfileOkonh].":</th><td><input class=input type=text name=okonh value="$okonh" size=40 "; if ($okonh and (@in_array("okonh",$pdc) or ($profileChecked and @in_array("okonh",$pdcwpc)) or ($passportFiles and @in_array("okonh",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileOkonhComment]."</td></tr>"; }
if ($country == "FI" or $country == "HU") { print "<tr><th valign=top>".$_lang[ProfileOgrn].":</th><td><input class=input type=text name=ogrn value="$ogrn" size=40 "; if ($ogrn and (@in_array("ogrn",$pdc) or ($profileChecked and @in_array("ogrn",$pdcwpc)) or ($passportFiles and @in_array("ogrn",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileOgrnComment]."</td></tr>"; }
}
$passportFilesEnable = GetSetting("passportFilesEnable");
if ($passportFilesEnable and !GetSetting("profilePassportDisabled")) {
if (!$passportFiles) {
if ($org == "1") { $commPassport = $_lang[ProfilePassportFilesUser]; } else if ($org == "2") { $commPassport = $_lang[ProfilePassportFilesIP]; } else if ($org == "3") { $commPassport = $_lang[ProfilePassportFilesOrg]; }
print "<tr><th valign=top>".$_lang[ProfilePassportFiles].":</th><td><p style="$styleHelp"><B>".$commPassport."</B><BR>".$_lang[ProfilePassportFilesComment]."<BR>".$_lang[ProfileImage]."1: <input type='file' class='input' name='userfile1'><BR>".$_lang[ProfileImage]."2: <input type='file' class='input' name='userfile2'><BR>".$_lang[ProfileImage]."3: <input type='file' class='input' name='userfile3'><BR>".$_lang[ProfileImage]."4: <input type='file' class='input' name='userfile4'><BR>".$_lang[ProfileImage]."5: <input type='file' class='input' name='userfile5'></td></tr>";
} else {
print "<input type=hidden name=passportFiles value='$passportFiles'>";
}
}
if ($org == "2" or $org == "3") {
print "<tr><th colspan=2 align=center><B>".$_lang[ProfileBankRekviz]."</b></th></tr>";
print "<tr><th valign=top>".$_lang[ProfileBank].":</th><td><input class=input type=text name=bank value="$bank" size=40 "; if ($bank and (@in_array("bank",$pdc) or ($profileChecked and @in_array("bank",$pdcwpc)) or ($passportFiles and @in_array("bank",$pdcwp)))) { print "readonly"; } print"></td></tr>";
print "<tr><th valign=top>".$_lang[ProfileBik].":</th><td><input class=input type=text name=bank_bik value="$bank_bik" size=40 "; if ($bank_bik and (@in_array("bank_bik",$pdc) or ($profileChecked and @in_array("bank_bik",$pdcwpc)) or ($passportFiles and @in_array("bank_bik",$pdcwp)))) { print "readonly"; } print"></td></tr>";
print "<tr><th valign=top>".$_lang[ProfileSchet].":</th><td><input class=input type=text name=bank_schet value="$bank_schet" size=40 "; if ($bank_schet and (@in_array("bank_schet",$pdc) or ($profileChecked and @in_array("bank_schet",$pdcwpc)) or ($passportFiles and @in_array("bank_schet",$pdcwp)))) { print "readonly"; } print"></td></tr>";
}
if ($country and (@in_array("country",$pdc) or ($profileChecked and @in_array("country",$pdcwpc)) or ($passportFiles and @in_array("country",$pdcwp)))) { $countryReadonly=1; } else {$countryReadonly=0;}
if ($oblast and (@in_array("oblast",$pdc) or ($profileChecked and @in_array("oblast",$pdcwpc)) or ($passportFiles and @in_array("oblast",$pdcwp)))) { $oblastReadonly=1; } else {$oblastReadonly=0;}
print "<tr><th colspan=2 align=center><B>".$_lang[ProfilePochtAddress]."</b></th></tr>
<tr><th>".$_lang[ProfileCountry].":</th><td>"; printCountrySelect($country,$countryReadonly); echo "</td></tr>
<tr><th valign=top>".$_lang[ProfileOblast].":</th><td>"; printOblastSelect($country, $oblast, $oblastReadonly); print "</td></tr>
<tr><th valign=top>".$_lang[ProfileIndex].":</th><td><input class=input type=text name=post value="$post" size=40 "; if ($post and (@in_array("post",$pdc) or ($profileChecked and @in_array("post",$pdcwpc)) or ($passportFiles and @in_array("post",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileIndexComment]."</td></tr>
<tr><th valign=top>".$_lang[ProfileCity].":</th><td><input class=input type=text name=city value="$city" size=40 "; if ($city and (@in_array("city",$pdc) or ($profileChecked and @in_array("city",$pdcwpc)) or ($passportFiles and @in_array("city",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileCityComment]."</td></tr>
<tr><th valign=top>".$_lang[ProfileAddress].":</th><td><input class=input type=text name=street value="$street" size=40 "; if ($street and (@in_array("street",$pdc) or ($profileChecked and @in_array("street",$pdcwpc)) or ($passportFiles and @in_array("street",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileAddressComment]."</td></tr>";
if ($country != "FI") { print "<tr><th valign=top>".$_lang[ProfileKomu].":</th><td><input class=input type=text name=komu value="$komu" size=40 "; if ($komu and (@in_array("komu",$pdc) or ($profileChecked and @in_array("komu",$pdcwpc)) or ($passportFiles and @in_array("komu",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileKomuComment]."</td></tr>"; }
print "<tr><th colspan=2 align=center><B>".$_lang[ProfileContactInfo]."</b></th></tr>
<tr><th valign=top>".$_lang[ProfilePhone].":</th><td><input class=input type=text name=phone value="$phone" size=40 "; if ($phone and (@in_array("phone",$pdc) or ($profileChecked and @in_array("phone",$pdcwpc)) or ($passportFiles and @in_array("phone",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfilePhoneComment]."</td></tr>
<tr><th valign=top>".$_lang[ProfileFax].":</th><td><input class=input type=text name=fax value="$fax" size=40 "; if ($fax and (@in_array("fax",$pdc) or ($profileChecked and @in_array("fax",$pdcwpc)) or ($passportFiles and @in_array("fax",$pdcwp)))) { print "readonly"; } print"><p style="$styleHelp">".$_lang[ProfileFaxComment]."</td></tr>
<tr><th>".$_lang[ProfileEmail].":</th><td><input class=input type=text name=email value="$email" size=40 "; if ($email and (@in_array("email",$pdc) or ($profileChecked and @in_array("email",$pdcwpc)) or ($passportFiles and @in_array("email",$pdcwp)))) { print "readonly"; } print"></td></tr>
<tr><th>".$_lang[ProfileIcq].":</th><td><input class=input type=text name=icq value="$icq" size=40 "; if ($icq and (@in_array("icq",$pdc) or ($profileChecked and @in_array("icq",$pdcwpc)) or ($passportFiles and @in_array("icq",$pdcwp)))) { print "readonly"; } print"></td></tr>
<tr><th colspan=2 align=center><B>".$_lang[ProfileDopInfo]."</b></th></tr>
<tr><th>".$_lang[ProfileRipn].":</th><td><input class=input type=text name=ripn value="$ripn" size=40 "; if ($ripn and (@in_array("ripn",$pdc) or ($profileChecked and @in_array("ripn",$pdcwpc)) or ($passportFiles and @in_array("ripn",$pdcwp)))) { print "readonly"; } print"></td></tr>
<tr><th>".$_lang[ProfileRipe].":</th><td><input class=input type=text name=ripe value="$ripe" size=40 "; if ($ripe and (@in_array("ripe",$pdc) or ($profileChecked and @in_array("ripe",$pdcwpc)) or ($passportFiles and @in_array("ripe",$pdcwp)))) { print "readonly"; } print"></td></tr>
<tr><th>".$_lang[ProfileUanic].":</th><td><input class=input type=text name=uanic value="$uanic" size=40 "; if ($uanic and (@in_array("uanic",$pdc) or ($profileChecked and @in_array("uanic",$pdcwpc)) or ($passportFiles and @in_array("uanic",$pdcwp)))) { print "readonly"; } print"></td></tr>
";
} else {
if ($org == "1") {$orgCheck1='checked';} else if ($org == "2") {$orgCheck2='checked';} else if ($org == "3") {$orgCheck3='checked';}
print "<tr><th>".$_lang[ProfileUserType].":</th><td><input type=radio name=org value=1 $orgCheck1> ".$_lang[OrderUserPrivatePerson]." <input type=radio name=org value=2 $orgCheck2> ".$_lang[OrderUserPrivatePredprinimatel]." <input type=radio name=org value=3 $orgCheck3> ".$_lang[OrderUserOrg]."</td></tr>";
print "<tr><th>".$_lang[ProfileCountry].":</th><td>"; printCountrySelect($country); echo "</td></tr>";
}
print "<tr><th colspan=2 align=center><input class=button type=Submit value='".$_lang[Save]."'></th></tr></table></form>";
_foot('utf-8');
?>