Файл: region_clean/userfoto.php
Строк: 64
<?
#######################################
## Mod By KoT (borispol) [76-75-072] ##
#######################################
require_once "start.php";
require_once "sid.php";
header("Cache-Control: no-cache");
if ($ver == "wml")header ("Content-type:text/vnd.wap.wml; charset=utf-8");
else header("Content-Type:text/html; charset=UTF-8");
require_once "inc.php";
$link = connect_db();
list($row, $id, $ps, $fsize1, $fsize2) = check_login($link);
require_once "version.php";
if (!is_numeric($usid))
{ header ("Location: index.php?isset=403"); exit; }
if (isset($rm) and !is_numeric($rm))
{ header ("Location: index.php?isset=403"); exit; }
settype($usid, 'integer');
$select = mysql_query("Select img,user from users where id='".$usid."'");
$inf = mysql_fetch_array($select);
$img = $inf['img'];
$user = $inf['user'];
$ras = explode(".", $img);
$type = $ras[1];
if ($ver == "wml") {
echo $xml;
echo $dtd;
echo "<wml>n
<card id="cabinet" title="Фото ".$user."">n
<p align="center">n";
} else {
echo "<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><link rel="stylesheet" type="text/css" href="css/$css.css"/>
<title>Фото ".$user."</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/></head><body>
<div align="center">";
}
if (empty($row['img'])) {
echo 'Ты не можешь просматривать фотки т.к. у тебя не установлено фото!<br/>';
include_once 'foot.php';
break;
}
echo "<img align="center" src="photos/".$usid.".".$type."" alt="".$user.""/><br/>n";
if ($id != $usid) {
echo $fsize1;
echo "<a href="galery.php?$ses&mod=votes&nk=$usid&rm=$rm&ref=$ref">+1</a>|
<a href="galery.php?$ses&mod=votes2&nk=$usid&ref=$ref">+3</a>|
<a href="galery.php?$ses&mod=votes3&nk=$usid&ref=$ref">+5</a>|<br/>
<a href="galery.php?$ses&mod=votes4&nk=$usid&ref=$ref">-1</a>|
<a href="galery.php?$ses&mod=votes5&nk=$usid&ref=$ref">-3</a>|
<a href="galery.php?$ses&mod=votes6&nk=$usid&ref=$ref">-5</a>|<br/>";
echo $fsize2;
echo '<br/>';
}
echo $fsize1;
echo "<a href="photos/".$usid.".".$type."">Скачать фото</a><br/>-----<br/>n";
echo "<div class = 'd1'><a href="enter.php?$ses&ref=$ref">Прихожая</a></div>n";
echo $fsize2;
include_once "foot.php";
?>