我正在做一个项目,用户可以上传图像,如图像图像或图像为他们的图像gallary.现在它将所有图像上传到我的服务器.
现在,我想使用php脚本直接将所有这些图像上传到我的rackspace云文件.例如:
所以你有任何想法,我到底怎么做?
我在用:
提前感谢任何答案.
我正在尝试使用以下代码将文件上传到rackspace云文件:
Upload.html
<form action="upload.php" enctype="multipart/form-data" method="POST">
File:
<input name="upload" type="file" />
<input name="submit" type="submit" value="Upload To Rackspace!" />
</form>
Run Code Online (Sandbox Code Playgroud)
upload.php的
<?php
// include the API
require('cloudfiles.php');
// cloud info
$username = ""; // username
$key = ""; // api key
// Connect to Rackspace
$auth = new CF_Authentication($username, $key);
$auth->authenticate();
$conn = new CF_Connection($auth);
// Get the container we want to use
$container = $conn->get_container('resumetune');
// store file information
$localfile = $_FILES['upload']['tmp_name'];
$filename = $_FILES['upload']['name'];
// upload file to Rackspace …Run Code Online (Sandbox Code Playgroud) 我想使用PHP和jQuery做以下事情
https://www.careerbuilder.com/share/register.aspx?sc_cmp1=JS_LoginASPX_RegNow
脚步
然后我需要验证选定的城市,州和国家.
你有什么想法?
提前致谢