file-upload

Displaying progressbar for file upload

I need to create an application where I can add files for upload. As I add items for upload, a progressbar should be displayed along with each item added. And when I click for file upload, the progress of file upload for each file should be reflected in the progress bar. The progress should use the function like ..... addEventListener(P...

$_FILES['file']['size'] echoing 0(zero) for files over upload_max_filesize

The problem is that I want to check if the file is too large to upload so that I can display a relevant error message, but when the file is larger than upload_max_filesize in php.ini it seems to be only displaying a 0. Why is this happening? How can I test that the file is too large to give a relevant error? ...

AJAX Toolkit - AsyncFileUpload Control Return Data

I am using the AsyncFileUpload control provided by the Ajax Toolkit. I am needing to store the file uploaded in a temporary directory and then return the temporary file name back to the client (or set viewstate) so that on the next post back it can be committed to a database. Does anyone have any ideas as the best approach to do this, i...

WYSIWYG image uploads in Rails App

Can anyone recommend a way of creating a view where users can upload images to my app through a WYSIWYG editor? I've tried solving this using CK Editor and Paperclip but am having lots of trouble... Maybe I'm going about this the wrong way. If someone's done this before I'd really like to know how! I don't have a editor or file storage...

How to create the file browser in view for spring roo?

I'm new in spring roo. I want to create a page with file upload. I used spring roo to create all pages and i try to use it to create a file browser button in file upload page. The problem is spring roo using spring form tag which doesn't have file browser. I solve this problem by using html input type="file" tag instead, but the sprin...

How to set django upload_handler in admin?

I'm trying to make a django upload progress bar within the django admin. The application is only a small part of the project, therefor I do not want to set the custom upload handler in the settings.py. The upload_handler can be set with request.upload_handlers.insert(0, UploadProgressHandler(request)) but not within the add_view of the ...

Setting the filetype in ASP.net fileupload

Is it possible to limit the asp.net fileupload dialog to view only XML files? (Filer, .xml only) Note: Not to check whether the extension is .xml, but to actually only let the user view xml files in the dialog. ...

C#, customise fileupload control

Hi All, I'm creating a website that is able to do multiple file uploads. However, is it possible such that when I click on the browse button and select the file to upload, it automatically adds it to a list of files to be uploaded, instead of selecting the file, and having another button to add that selected file to the list? It is some...

How to upload a file to iphone app from a computer?

In some of the apps, I have seen its possible to upload files to the library of a certain application. They ask to type "http://192.xxx.xxx.xxx" and then to upload files to that location which inturn becomes available for download in iphone when we use the same URL. Do anyone have an idea how to do it OR where to look for to gain info ...

Please help to understand this RegEx statement.

Please help to understand this RegEx statement in details. It's supposed to validate filename from ASP.Net FileUpload control to allow only jpeg and gif files. It was designed by somebody else and I do not completely understand it. It works fine in Internet Explorer 7.0 but not in Firefox 3.6. <asp:RegularExpressionValidator id="FileUpL...

Handling file uploads with JavaScript and Google Gears, is there a better solution?

So - I've been using this method of file uploading for a bit, but it seems that Google Gears has poor support for the newer browsers that implement the HTML5 specs. I've heard the word deprecated floating around a few channels, so I'm looking for a replacement that can accomplish the following tasks, and support the new browsers. I can...

MySQL / PHP Drag and Drop File Upload

I am looking to upload files into a MySQL database using a drag and drop application. Any ideas? I want to be able to drag a file into the browser and then type in a file name. THANKS! ...

Can ServletFileUpload.parseRequest() only be called once per request?

I'm working a custom SpringSecurityFilter for my Grails application and I'm trying to use the commons upload library to process the request. I'm able to process the request in the filter but once it gets to my controller, none of the values are available. Can the HttpRequest only be processed once by the upload library? I'm guessing it...

Problem catching form submit with jQuery when using "display:none"

Hi Guys, I am trying to use jQupload to upload an image asynchronously. The script uses an iframe off of the page to upload and then catches the .load() event of the iframe to return the JSON message that is returned. If I display the form at the bottom of a standard HTML page and include the javascript then it works fine. However, I w...

Jquery form plugin file upload

Hi all, i have a problem with jquery form plugin. I try to upload a file asynchronously but it does not submit the form. html markup and javascript code are like below <form id="fileUploadForm" method="post" action="Default.aspx" enctype="multipart/form-data"> <input type="text" name="filename" /> <input type="file" id="postedFile" nam...

How do I create a single-click upload control for a web-app using JS/HTML/CSS/PHP?

I know how to do the traditional "Select File..." and then "Upload" mechanism for uploading files. I would like to know if there is a way to do this using single input control. Part of the motivation for this is that nobody selects a file without wanting to upload it, so why should people have to two-step the process? I know that there ...

Upload file and parameters with ajax request, pure javascript or prototypejs

Hi, I want to upload a file using an ajax request var xhr = new XMLHttpRequest(); xhr.open("POST", "/photos"); xhr.overrideMimeType('text/plain; charset=x-user-defined-binary'); xhr.sendAsBinary(bin); Works fine, but I want to post a parameter with this request ie: token=abc123 How can give a parameter to this request? this is pu...

How to limit file upload speed in php or apache?

I'm doing some form in Zend Framework for file upload on "Apache friends - xampp" server 1.7.1 on Ubuntu 9.10. My problem is that I what to add progress bar for this upload and since xampp server is on my localhost, file uploads are very fast. As a result, I have no time to check or observer if progress bar works as it should. Is th...

How to develop a cross-browser, simplified photo uploader

similar to what is shown here. I don't need total image editing... only rotation, maybe cropping. But the user being able to drag'n drop a photo and then minor editing is what I'm after. I'm sure there's a jQuery plugin for something like it. (preferably not an HTML5 solution) However, I've refrained from using uploaders that use an aj...

Rhino Mocks: Mocking HttpRequestBase.Files

I have a view & controller that allow the user to upload a file to the server. This is done in the view using an input type='file' and in the controller by getting the value of Request.Files (HttpRequestBase, returning a HttpFileCollectionWrapper). I am having difficulty mocking this using Rhino Mocks. HttpContextBase mockHttpContext =...