move uploaded files into a folder
<p>I'm trying to move uploaded files into a folder, but i can't do it. Somebody see the error?</p>

<p>My html code has this line:</p>

<pre><code>&lt;form id="form" method="post" action="save_new_article.php" enctype="multipart/form-data"&gt;
</code></pre>

<p>And this is php code:</p>

<pre><code>include("bd.php");
header('Content-type: text/html; charset=windows-1251');
$category = $_POST['category'];
$name = $_POST['name'];
$description = $_POST['full_description'];
$price = $_POST['price'];

$way = "../galery";
$file = $_FILES['photo']['tmp_name'];
$file_name = $_FILES['photo']['name'];
$file_name = ext($file_name);

$way .= "/".$file_name;
move_uploaded_file($file,$way);
</code></pre>

<p>If somebody can detect the error, inform me please</p>
