我无法使用 PHP 上传 SWF 文件

I cant Upload SWF Files With PHP

我在 1 个表单中有 2 个输入文件。当我尝试 post 使用图像 print_rvar_dump 显示其属性时。

但是当我尝试 post 使用 swf print_rvar_dump 说空并且不能 post.

那么如何上传 swf 文件?谢谢。

echo var_dump($_FILES);

if($_FILES["oyun_yolu_file"]["type"] == "application/x-shockwave-flash")
{
    echo "aha";
    echo var_dump($_FILES["oyun_yolu_file"]);
}

我已经上传了代码,但我的问题是我无法上传 swf 文件,我可以上传常规文件,如 txt、图片等。

<form action="" method="post" enctype="multipart/form-data">
<table>
<tr>
<td>Resim Yolu</td>
<td>
<input type="text" name="resim_yolu" class="resim_yolu" style="width:260px !important" />
<span id="kirmizi" style="padding:0px 10px">yada</span>
<input type="file" name="resim_yolu_file" class="resim_yolu_file" />
</td>
</tr>

<tr>
<td>Oyun Yolu</td>
<td>
<input type="text" name="oyun_yolu" class="oyun_yolu" style="width:260px !important" />
<span id="kirmizi" style="padding:0px 10px">yada</span>
<input type="file" name="oyun_yolu_file" class="oyun_yolu_file" />
</td>
</tr>
</table>
</form>

我自己测试了这段代码,它可以正常工作

<?php
//echo var_dump($_FILES);
if(isset($_POST['add']))
{
if($_FILES["oyun_yolu_file"]["type"] == "application/x-shockwave-flash")
{
    echo "aha";
    echo var_dump($_FILES["oyun_yolu_file"]);
}}
 ?>
<form action="" method="post" enctype="multipart/form-data">
<table>
<tr>
<td>Oyun Yolu</td>
<td>
<input type="text" name="oyun_yolu" class="oyun_yolu" style="width:260px !important" />
<span id="kirmizi" style="padding:0px 10px">yada</span>
<input type="file" name="oyun_yolu_file" class="oyun_yolu_file" />
</td>
</tr>

<tr>
<td>Oyun Açıklaması</td>
<td>
<textarea cols="45" rows="5" name="oyun_aciklama" style="width:264px !important; padding:4px;"></textarea>
</td>
</tr>
<tr><td>
<input type="submit" name="add">
</td></tr></table>
</form>

输出是检查你的文件

ahaarray(5) { ["name"]=> 字符串(23) "Car-speakers-590x90.swf" ["type"]=> 字符串(29) "application/x-shockwave-flash" ["tmp_name"]=> 字符串(23) "E:\xamp\tmp\php7D0E.tmp" ["error"]=> 整数(0) ["size"]=> 整数(116887) }