Hi
Given I have a webservice which accepts file uploads.
And I want to test it in Cucumber
When I put the following code in Step Definition
post '/webservice', 'picture[file]' => File.new(Rails.root.join(@path_to_file), 'rb')
Then I should see the saved file
Unfortunately, this is not the case.
Any help would be greatly appreciate...
Hello
Is it possibly to write a HTML5 web application designed for the iOS devices (iPad, iPhone, iPod Touch) which can allow the user to upload an image from the filesystem?
Imagine uploading a new photo to your twitter avatar via a web app.
Thanks.
...
Hey, trying to post a file using curl and all is working great. I have one problem. I can't declare my file outside of my post_file() function. I call this function in my application many times so want it to be reusable.
So this works:
function call_me(){
$file_path = "/home/myfile.mov";
$url = "http://myurl.com";
$this->...
Hello once again i ask question on stackOverflow :D
how can i upload file with JSF using primefaces?
i have method handle Upload Image
public void handleFileUpload(FileUploadEvent event) {
ExternalContext extContext = FacesContext.getCurrentInstance().
getExternalCo...
My ascx does support postback(dont ask why), I do an ajax call to save all the data on page, but I have to do a file upload as well so I am using an iframe for it. Everything works well expect for in the firefox.
In the firefox it all works well for the first time not the 2nd time. i.e. if the form filled and files uploaded and submitte...
I am using file upload fucntionality in my asp.net MVC project.
It worked great until I started using some AJAX functionality on my page.
The HttpPostedFile is always NULL on Ajax page.
How can solve this issue along with calling ajax on my page?
...
I have a PHP script that you can upload very large files with (up to 500MB), and the file's content is stored in a MySQL database. Currently I do something like this:
mysql_query("INSERT INTO table VALUES('')");
$uploadedfile = fopen($_FILES['file']['tmp_name'], 'rb');
while (!feof($uploadedfile)) {
$line = mysql_escape_string(fget...
Hi,
Interesting issue I seem to have come across. I have a form that uploads an image and stores the value in a database table. The form uploads the image file OK and makes it available for processing. The issue is as follows; using move_uploaded_file to the specified directory does not work, however using copy() to this directory d...
Hi all, I've been getting this warning when some people upload images to our site :
Warning: imagecreatefromjpeg()
[function.imagecreatefromjpeg]:
gd-jpeg: JPEG library reports
unrecoverable error: in
/home/sherifo/private/includes/snapsutils.php
on line 220
Warning: imagecreatefromjpeg()
[function.imagecreatefromjpe...
I'm still fairly new to rails but I've done file uploading before. I'm trying to implement very basic file uploading - nothing fancy, just upload the file, save it, and make a record of it. So here's my method for saving the file:
def self.save(upload,name)
directory='public/uploads'
ext=File.extname(upload.original_filename)
...
For Example, http://imgur.com
In the stock browser on an android phone you can press the "Browse" button on imgur.com and navigate to a photo you wish to upload. This works great in the browser. Is there something I should set to true to allow this in a webview?
...
Hi All,
I want to configure product like this,when a customer puts his order he can upload the image that he wanna see over his product
Thanks in Advance
...
I am looking for a ajax method that can be used to file upload.
It will be super if I find a funtion that uses Prototype + Script.acul.us
...
I am trying to create a upload servlet that handles enctype="multipart/form-data" from a form. The file I am trying to upload is a zip. However, I can upload and read the file on localhost, but when I upload to the server, I get a "File not found" error when I want to upload a file. Is this due to the Struts framework that I am using? Th...
I want to store filename, filesize, etc. from images already on my server. My idea is to upload images via ftp and then store the data in mysql using php. Is that possible?
...
I'm building Java client that will automatically upload file from Java server to Panda Instance that I installed on my EC2 cloud using their AMI. I'm trying to use Apache HTTP Components to upload to Panda Server (Panda Stream). It works fine with my browser client but for some reason I can't upload from that library. Here is my code:
S...
I have noticed a difference in behaviour between chrome and IE of handling file input clicks.
jsFiddle example here.
In Chrome, clicking anywhere on the input (text or button bit) triggers the file dialogue.
In IE (testing on 7), you have to click on the actual button, not the text bit.
The problem is that I'm using a transparent fil...
Hi all -
I read in a file via HTML5 FileReader and jQuery like so:
holder.ondrop = function(e) {
this.className = '';
e.preventDefault();
var file = e.dataTransfer.files[0],
reader = new FileReader();
reader.onloadend = function(event) {
$.ajax({
url:"/path/to/upload",
type: "POST",
...
I have a somewhat complex problem or at least it appears like this. In my project I'm dealing with really big image files uploaded by users. Storage is provided by separate media server which also generates thumbnails. Thumbnails are not created immediately, so there will be a cron function to check if they're ready. There are also files...
hello there.
i have been stressing for an hour at this stupid script i am trying to make it uploa an MP3
file to a folder it creates.
It is putting the information into mysql and making the folder bu when i ftp the folder is empty with no music file in there
here is the script thanks so so so much!
BTW $name is the POSTED name and ful...