onload="okno('Название предмета, в который встраивается свиток', 'main.php?edit=1&use=<?= $_GET['use'] ?>','target')"><?
}else{
$svitok=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `name` = '".$_SESSION['scroll']."' AND `owner` = '{$user['id']}' AND `dressed`=0 LIMIT 1;"));
$dress=mysql_fetch_array(mysql_query("SELECT * FROM `inventory` WHERE `owner` = '{$user['id']}' AND `name` LIKE '{$_POST['target']}' AND `includemagic` = 0 AND `dressed`=0 LIMIT 1;"));
//echo "SELECT * FROM `inventory` WHERE `owner` = '{$user['id']}' AND `name` LIKE '{$_REQUEST['target']}' AND `includemagic` = 0 LIMIT 1;";
$_SESSION['scroll']=null;
if(!$svitok){
echo"<font color=red><b>У вас нет такого свитка!<b></font>";
}elseif(!$dressor$dress['type']>=12){
echo"<font color=red><b>У вас нет такого предмета!<b></font>";
}else{
$incmagic=mysql_fetch_array(mysql_query("SELECT * FROM `magic` WHERE `id` = '{$svitok['magic']}' LIMIT 1;"));