<?php
echo "PHP上传配置检查:\n";
echo "-------------------\n";
echo "upload_max_filesize: " . ini_get('upload_max_filesize') . "\n";
echo "post_max_size: " . ini_get('post_max_size') . "\n";
echo "max_file_uploads: " . ini_get('max_file_uploads') . "\n";
echo "max_execution_time: " . ini_get('max_execution_time') . "\n";
echo "memory_limit: " . ini_get('memory_limit') . "\n";
echo "\n";
echo "文件上传临时目录:\n";
echo "upload_tmp_dir: " . ini_get('upload_tmp_dir') . "\n";
echo "\n";
echo "视频目录权限:\n";
$dirs = ['videos/', 'videos/opening/', 'videos/host/'];
foreach ($dirs as $dir) {
    $path = __DIR__ . '/' . $dir;
    $exists = is_dir($path) ? '存在' : '不存在';
    $writable = is_writable($path) ? '可写' : '不可写';
    echo "$dir: $exists | $writable\n";
}
?>