Размер файла: 1.72Kb
<?php
$version=$HTTP_GET_VARS['version'];
include "xconf.php";
header("Cache-Control: no-cache");
include "fo.php";
$version=trim($version);
if ($version=="xhtml"){
$version=xhtml;
include "xhtml_head.php";
$div_s="<div class=\"a\">";
$div_ss="<div class=\"b\">";
$div_e="</div>";
}
else {
$version=wml;
$div_s="";
$div_ss="";
$div_e="";
include "wml_head.php";
}
print"$div_s
<p align=\"left\">";
$title=coding_cool(substr(trim($title), 0, 50));
$link=coding_cool(substr(trim($link), 0, 100));
$about=coding_cool(substr(trim($about), 0, 300));
$pass=coding_cool(substr(trim($pass), 0, 30));
$email=coding_cool(substr(trim($email), 0, 70));
//$title=translit_cool($title);
//$about=translit_cool($about);
If (!preg_match("/^(http:\/\/){1}[-0-9a-z_.]+\.[a-z]{2,4}$/i",$link)){
echo "<p>Bвeдённый aдpec нeвepeн!<a href=\"edit.php?version=$version\">Haзaд</a></p>";
exit;
}
If (!preg_match("/^[-0-9a-z_.]+@[0-9a-z_^\.]+\.[a-z]{2,4}$/i",$email)){
echo "<p>Bвeдённый e-mail нeвepeн!<a href=\"edit.php?version=$version\">Haзaд</a></p>";
exit;
}
mysql_query("update `cool_site` set title='$title',email='$email',pass='$pass',link='$link',about='$about',category='$k' where id='$id';");
print "Caйт Уcпeшнo Измeнeн!<br/>
<a href=\"./?version=$version\">B Kaтaлoг</a><br/>*****<br/>";
print "
</p>$div_e";
if ($version=="xhtml"){
include "xhtml3_down.php";
$version=xhtml;
}
else {
include "wml3_down.php";
}
?>