Agile Uploader(在上传到服务器之前调整图像大小)- POST 数据中根本没有图像?

发布于 2024-12-28 14:18:11 字数 1491 浏览 2 评论 0原文

我想使用 Agile Uploader 在上传到我的服务器之前调整图像大小。

但是当我尝试在服务器上上传图像时,它什么也没做...我的意思是 POST 数据中没有图像。我检查了 POST,根本没有任何项目。我做错了什么?

这是我的代码:

<html>
<head>
    <script type="text/javascript" src="/static/js/jquery1.6.4.min.js"></script>
    <script src="/static/js/jquery.flash.min.js" type="text/javascript"></script>
    <link type="text/css" rel="stylesheet" href="/static/css/unrelated.css" />
    <script src="/static/js/agile-uploader-3.0.js" type="text/javascript"></script>
    <link type="text/css" rel="stylesheet" href="/static/css/agile-uploader.css" />
</head>
<body>

<form action="/test" method="post" id="singularDemo" enctype="multipart/form-data">
    <div id="single"></div>
</form>

<a href="#" onClick="document.getElementById('agileUploaderSWF').submit();">Submit</a>
    <script type="text/javascript">
        $('#single').agileUploaderSingle({
            formId:'singularDemo',
            progressBarColor:'#3b5998',
            flashVars:{
                firebug:true,
                form_action:'/test',                
            }
        });
    </script>

</body>
</html>

大部分代码部分取自他们的演示

提前致谢!

I want to use Agile Uploader to resize images before upload on my server.

But when I try to upload image on server it does nothing... I mean that there is no image in POST data. I've checked POST and there is no items at all. What am I doing wrong?

Here is my code:

<html>
<head>
    <script type="text/javascript" src="/static/js/jquery1.6.4.min.js"></script>
    <script src="/static/js/jquery.flash.min.js" type="text/javascript"></script>
    <link type="text/css" rel="stylesheet" href="/static/css/unrelated.css" />
    <script src="/static/js/agile-uploader-3.0.js" type="text/javascript"></script>
    <link type="text/css" rel="stylesheet" href="/static/css/agile-uploader.css" />
</head>
<body>

<form action="/test" method="post" id="singularDemo" enctype="multipart/form-data">
    <div id="single"></div>
</form>

<a href="#" onClick="document.getElementById('agileUploaderSWF').submit();">Submit</a>
    <script type="text/javascript">
        $('#single').agileUploaderSingle({
            formId:'singularDemo',
            progressBarColor:'#3b5998',
            flashVars:{
                firebug:true,
                form_action:'/test',                
            }
        });
    </script>

</body>
</html>

Most code part taken from their demo.

Thanks in advance!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

你的往事 2025-01-04 14:18:11

您必须编辑 process.php 文件,您将在其中定义远程上传文件夹!
然后修改form_action中:"form_action: process.php"

you have to edit the process.php file, where you'll define the remote upload folder!
and then modify the form_action in: "form_action: process.php"

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文