FAQ Database Discussion Community


How can I upload files to dropbox using JavaScript?

javascript,angularjs,file-upload,upload,dropbox
I didn't see any useful upload in dropbox example. Can you help me? I'm using AngularJS....

Warning: getimagesize(image.jpg) [ ]: failed to open stream: no such file or directory

php,upload,resize-image
I have problem to crop the image, but this source work fine when i use for resize image before some code i change to crop. This the source for Crop: $filenames1 = stripslashes($_FILES['txtfile1']['name']); $exts1 = substr($images1, strrpos($images1, '.')+1); $idimgs = md5(uniqid() . time() . $filenames1) . "-1." . $exts1; $target_files1...

Why I can't receive files on nodeJS server?

javascript,ajax,node.js,post,upload
I can't understand why I don't receive files, I have this code on browser (drag&drop): function dropZone(){ //drop zone var dropZone = $('#dropZone'), maxFileSize = 1000000000000000000000; // max size - if (typeof(window.FileReader) == 'undefined') { dropZone.text('Use recent browser to upload files'); dropZone.addClass('error'); } //events dropZone[0].ondragover = function() { dropZone.addClass('hover'); return...

Progress percentage from browser on POST multipart request. GWT

post,gwt,upload,progress-bar,progress
I looking for approaches to implement Progress Bar for POST multipart file upload from GWT app. I already known about open-source GWTUpload lib and GWT AJAX-requests. But I can't make any changes for server side, just client side. I found out that Chrome somehow handles such progress (http://oi58.tinypic.com/2w22ekm.jpg). How I...

Uploading a file to S3 (frankfurt) gets an error authorization AWS4-HMAC-SHA256

javascript,node.js,amazon-web-services,amazon-s3,upload
Hi :) When I try to directly upload a file to AWS S3, I get this error: The authorization mechanism you have provided is not supported. Please use AWS4-HMAC-SHA256. Seems like I'm missing something with the signing of the v4 hmac authorization signature :\ The html file: <form action="https://mybucket.s3.eu-central-1.amazonaws.com/" enctype="multipart/form-data"...

File upload using input type=file not working in IE for first file, works on subsequent uploads

javascript,jquery,html5,internet-explorer,upload
Upload functionality works perfectly fine in Chrome, however it doesn't work on IE 11. I'm trying to implement upload functionality by using the following dom element: <input type="file" id="file-upload" class="hidden-inputs"/> I'm triggering the click when the user clicks something else, the input itself is hidden. This is the code for...

Perl FTP uploading empty file to server

perl,upload,ftp
I have to upload a file to a Debian server using Perl and FTP. I tried $ftp->put which gave me no errors but uploaded only an empty file (or created one), and $ftp->copy which gave me some weird message, I guess is an error and again, an empty file. My...

Upload Image using ajax (json)

php,ajax,image,upload
I need to upload image using ajax. Elaborating my point: I need t pass my image data to a php page and check the type, size, name and all oher attributes of the file. If all attributes matches, then only I need to transfer the file. Problem here is passing...

How to create file upload like gmail?

javascript,jquery,file-upload,upload
I am having a code with "upload" and done "button". It will select the file on clicking of "upload" and upload the file on clicking "Done" in the given location. But I need to auto-upload file, like Gmail attachment. Can anyone help me out pls

How to implement upload component with one upload button in Vaadin?

java,upload,vaadin
I have the following class that implements the single Upload example @Override public void init() { Window mainWindow = new Window("Singleuploadclick Application"); Label label = new Label("Hello Vaadin user"); mainWindow.addComponent(label); status = new Label("Please select a file to upload"); upload = new Upload(null, receiver); upload.setImmediate(true); upload.setButtonCaption("Select file"); upload.addListener(new Upload.StartedListener() {...

Multiple File Upload Code for Django

python,django,file,upload
Ok. So I've come up with the following code after searching a lot of forums and other posts in Stackoverflow. First of all I've tried using request.FILES.get('onefile') but that only uploaded one file no matter how many I selected during the upload. So I've changed my code a bit to...

How to upload file in PHP and store information in SQLi database?

php,file,mysqli,upload
So I'm trying to do this file upload, and store information such as the size of the file, name, and URL of it in a database, while having the file just upload to a folder on my computer (for testing purposes). It's uploading no problem, the only issue I'm having...

Uploading a video to vimeo via the API in ruby

ruby,upload,vimeo
I've been trying to upload an MP4 video to vimeo via ruby. At first I thought I would try the ruby gem, but looking at it it uses the now deprecated vimeo API. I've been able to upload via a form I made myself, but entirely with code doesn't seem...

Add value to WP Attachment Meta Data

wordpress,upload,orientation,attachment,aspect-ratio
I would like to let Wordpress calculate the aspect ratio & orientation when the media is uploaded instead of doing this in the templates. Then I can call images and ask for image.orientation which will give me 'portrait' or 'landscape' as a value. Example, how it would look like after...

Upload image to server not working

php,curl,file-upload,upload,image-uploading
Before I start, I want to clarify that I did extensive research on this but none of the solutions work. I have been create a app that allow to users upload your images to create an event. I tried to upload this images to my server, and I received successfully...

upload CSV file to database on Google app engine using Python

python,database,google-app-engine,csv,upload
I'm a newbie in python and started learning it from about a week. I was looking into couple of tasks one of which was to upload a file (.txt or .jpg) to a bucket on GAE. I was able to solve it by following couple of tutorials online, but i'm...

Error while uploading image to server with Swift

swift,post,upload,server,multipartform-data
Hi so here's the code I'm using to upload an image to our server via a link. if (currentElementName == "uploadUrl") { let returnUploadURL = string var imageData = UIImagePNGRepresentation(pictureImage.image) if imageData != nil{ var request = NSMutableURLRequest(URL: NSURL(string: returnUploadURL)!) var session = NSURLSession.sharedSession() println(request) request.HTTPMethod = "POST" var boundary...

Upload image failing in php

php,image,upload
I am trying to upload a file using php. However, I get no feedback from echo for some odd reason even though there are only two paths. <?php $allowedExts = array("jpg"); $temp = explode(".", $_FILES["file"]["name"]); $extension = end($temp); if ( ($_FILES["file"]["type"] == "image/jpg") && ($_FILES["file"]["size"] < 100000) && in_array($extension, $allowedExts))...

How to ask the user to upload a file and use it in my code

javascript,json,angularjs,file-upload,upload
Hey guys I'm trying to know how to replace a json with another json a user upload. This is my javascript code var app = angular.module('miApp', []); app.controller('mainController', function ($scope, $http) { $http.get('cuidades.json').success(function(data){ $scope.cities = data; }); }); And this is my html code, with this code I can get...

Can CDNs handle base64 encoded data?

image-processing,upload,xmlhttprequest,base64,cdn
I'm trying to make an app where I take pictures from users add them to a canvas, draw stuff in them, then convert them to a base64 string and upload them. For this purpose I'm considering the possibility to use a cdn but can't find information on what I can...

Uploading image file and string to php backend using android and post method

php,android,image,post,upload
I am having trouble uploading an image file along with a string using a post method. The image file does in fact upload to the server, but my attempt to send a string (username) with it has failed. I know I am getting a value for the username because it...

C++ Array based on external file

c++,arrays,function,file,upload
I have relatively simple problem (at least it seems like that to me). Let's say I have a file 'test.txt' containing 9 lines of numbers like this: 8 4 1.2 2.3 3.4 4.5 2.8 2.1 3.1 9.4 1.2 2.3 3.4 4.5 2.8 2.1 3.1 9.4 The first number (8) tells...

Uploading file from android to server fails

java,android,http,file-upload,upload
I am trying to upload a file to a server. I have tried to do this in two ways. First Method Here is the code for the first method: String lineEnd = "\r\n"; String twoHyphens = "--"; String boundary = "*****"; int bytesRead, bytesAvailable, bufferSize; byte[] buffer; int maxBufferSize =...

CodeIgniter: How can I store a photo name into database

codeigniter,upload,photo
I had looked for many examples about it and I did something as I can do. I will build a registration form. There will be five text fields and also a photo upload section. what I did The text fields are stored in the database. In here only one field...

Laravel 5, attempting multi-file upload, Request::file() only returning last file?

php,http,laravel,upload,laravel-5
I'm attempting to get multiple files uploaded using the same key using Laravel 5's Request facade. From what I've read elsewhere, the correct way to do this is to call Request::file() without passing a parameter to the ::file() method. However, this only seems to return the last file sent in...

php form upload noname attachment

php,forms,upload,email-attachments
I have this code and it works. I have only one side effect and I'd like to know how to solve it.. In my form I have three file selectors. The user can, if he want, upload up to three files.. If the user upload three files I receive the...

Php image upload wont go into set directory

php,sql,upload
I had the exact same code working, although with users directory, replaced the users dir with media, and its like it doesn't think the folder exists. How ever I can manualy put a image inside the media folder and view it via my domain. Here is my current code. <?php...

Codeigniter upload file and resize

codeigniter,upload,resize
I'm trying to resize pre-uploaded images and then send them to another server with FTP, but it doesnt seems to be working. The uploading is working fine, the ftp is working fine too but whenever I download the image and check the size it's just the same as the uploaded...

Upload image codeigniter

php,image,codeigniter,upload
I try to upload an image with CodeIgniter. The image has to be send to a folder and the path send to the database. When I do submit, it doesn't do anything. The var_dump of ($story_img) shows: string(8) "/images/" This is my code: if ($this->input->server('REQUEST_METHOD') == 'POST') { $config['upload_path'] =...

Getting “filetype not allowed” with Codeigniter upload

php,codeigniter,file-upload,upload,mime-types
First of all, there are already a lot of (solved) questions regarding this topic. And I tried all possible solutions. But to no avail. The problem occurs in both CI versions 2.1.4 and 2.2.1. I also tried using different filetypes, such as png,gif and txt. I've done no mime-type alterations,...

How to prevent duplicate filenames in laravel?

php,file,laravel,upload,eloquent
This is the code I have in a store method from one of my controllers. // Get the file object from the user input. $file = Request::file('filefield'); // Get the filename by referring to the input object $fileName = $file->getClientOriginalName(); if (!Storage::exists($fileName)) { Storage::disk('local')->put($fileName, File::get($file)); } else { return 'Hey...

How to get $_GET variables from referrer url in Yii?

ajax,url,yii,upload,get
I trying upload images on server by Ajax, when server catching files the files are writing to database. But here now I need to parse referrer url to get Id. For now I have only this solution: public function actionAjaxTest() { if(Yii::app()->request->isAjaxRequest) { echo json_encode(parse_url(Yii::app()->getRequest()->getUrlReferrer())); } Yii::app()->end(); } Is Yii...

Uploading multiple files using one form

php,pdo,upload,image-uploading
I am trying to create a form, with which a user can upload multiple image files. I am still really at the start and I know that this code is very insecure. I just first would like to be able to upload the pictures and then I will add the...

Image file upload from view to controller parameters returning null in debug

c#,asp.net-mvc,database,image,upload
I am trying to upload an image from users files and save it to the database in byte[] format. I have tried numerous tutorials and have search SO but all I've tried has not solved my problem. Problem: When I debug my project for where I pass the image from...

Coping file from inputstream to outputstream results in bad copy

java,file,servlets,upload
I made an upload file servlet, summed up like this: ServletFileUpload upload = new ServletFileUpload(); FileItemIterator iter = upload.getItemIterator(request); while (iter.hasNext()) { FileItemStream item = iter.next(); InputStream stream = item.openStream() File file = new File(path +"/"+ item.getFieldName)); FileOutputStream fout= new FileOutputStream (file); BufferedOutputStream bout= new BufferedOutputStream (fout); BufferedInputStream bin= new...

How to convert any image to bitmap image and store in MySQL database using PHP?

php,mysql,bitmap,upload
How to convert any image to bitmap image and store in MySQL database using PHP? I want to store an image in a database. How to convert any images to bitmap image. <?php $target_dir = "uploads/"; $target_file = $target_dir . basename($_FILES["fileToUpload"]["name"]); $uploadOk = 1; $imageFileType = pathinfo($target_file,PATHINFO_EXTENSION); // Check if...

FTP not working on any FTP client not even with Mozilla or Chrome

osx,upload,ftp
I am using macbook pro os x 10.10.3. I am a developer and I use ftp on a regular basis. How ever I am new to mac os. It was working fine but suddenly ftp stop working for all ftp clients on my mac for any server, even for ftp://ftp.mozilla.org/....

Upload IPA, strange issue: ERROR ITMS-90032:“Invalid Image Path - No image found at the path referenced under key '$key': '$path'

ios,xcode,upload
Hi everyone, there is a strange issue when I try to upload new build to iTunes Connect via Xcode. I think the problem with Info.plist file. Info.plist: https://docs.google.com/document/d/1Rp51VcZkP-uoUnaBwtr86EAPLLq-aN2w9f2CNrRZsBQ/edit?usp=sharing Thanks you!...

Dropzone.js - drop outlook emails

javascript,file,upload,outlook,dropzone.js
We have Dropzone successfully set up in our browser application and it works great! However, we are trying find a way to drag and drop emails from MS Outlook and we have not had any success. Is there a way to do this?

How to Upload file onclick of button of type=button not type=submit in mvc4 using html begin form

file,asp.net-mvc-4,button,upload,submit
I have to upload a file using a button (of type button, not submit). And I want to show popup when no-file is selected and clicked on upload, it should not go to controller action. Can anyone help please?...

Arduino Sublime Text 2. I can compile but can't upload. Error “The system cannot find the file specified”

c++,upload,arduino,sublimetext2
I have seen several questions answered about similar problems, but none that completely solved my problem. I'm trying to upload a sketch in Arduino using Sublime Text 2. Initially had trouble compiling the file, which could resolve adding the ways: C:\WinAVR-20100110\avr\bin, C:\WinAVR-20100110\bin and C:\ WinAVR-20100110\utils\bin to the path. My problem...

Changing file name to the user's name PHP

php,file,upload
Instead of the file name being what the users want to name it, I would like the file name to be the user's username. As you can see in the code below, I got the user's username from the session. Now, I would just like to apply it to $_FILES,...

PHP - blueimp custom upload directory - empty list on reload

php,upload,blueimp,filelist
i use blueimp on php. In HTML i've put a hidden input field to submit the User_ID (after login, ID of the user from DB) to the Upload Handler as $_POST value. I use the User_ID value as upload directory name to separate each users files from each other. HTML:...

FormData() not working in Firefox and Internet Explorer; only Chrome is OK

ajax,upload,form-data
I am trying to build an AJAX image upload using FormData() and it is not working for Firefox and IE. In Chrome everything behaves well; the php script receives form-data object and returns response as expected. However, in Firefox and Internet Explorer an empty string is always returned as a...

Deployment PhpStorm gone

deployment,upload,phpstorm
My Deployment in PhpStorm is gone. I tried to upload a project and noticed that I couldn't. Then I figured it must be mappings that aren't set the right way, but when I went to Tools and wanted to click Deployment, Deployment wasn't even there....

Is it possible to send base64 image to an amazon s3 bucket via ngFileUpload post?

angularjs,canvas,amazon-s3,upload,ng-file-upload
I have a working script that when the file input changes, pick the files, sign their upload data in my django backend, and upload it from the frontend directly to my s3 bucket. It's working great. I'm using ng-file-upload to do it. var doSignUrl = function(image, success, error){ $http({ url:...

Dropped image preview in dropper plugin jquery

javascript,jquery,upload,drag-and-drop
I've been trying to make a drag and drop image field to upload to server using ajax. I've gone through some Jquery plugins and I found Dropper plugin can help.I tried like this. HTML <div class="target"></div> <img> JS $(".target").dropper({ action: "upload.php", }).on("start.dropper", onStart); function onStart(e, files){ console.log(files); $('.dropper-dropzone').css("background-color", "yellow"); $('img').attr({src:files[0].name});...

How to create folder and upload file inside openshift?

upload,openshift,server,openshift-client-tools
I'm using rhc client tools for openshift. and i want to upload it PhantomJS. So, I've Executable file and now i want to upload into my openshift server, So please let me know. How can i create folder? and how to upload it? I googled but fully confused with ${OPENSHIFT_DATA_DIR}....

How to upload/import a file in the new R shiny version 0.12 using DT package

r,datatable,upload,shiny
I have just updated shiny to version 0.12 and started to use the DT package (finding it a bit difficult to use but have to do it anyway). Basically I am trying to upload or import a file. This is my server code: shinyServer(function(input, output, session) { datasetInput <- reactive({...

$_FILE is empty when upload in PHP

php,jquery,file,file-upload,upload
I was using the dropzone.js to handle the upload part in frontend, using jquery. http://www.dropzonejs.com/ My testing case are : Upload a 34 MB file. Works fine Upload a 27 MB file. Works fine Upload two files, each of them are 5 MB. Works fine Upload two files, 34 MB...

how to upload multiple files, store their paths in different columns in a mysql database row

php,mysql,file,upload,path
Hello i am trying to create a subscription form, that allows a user to fill in a form and upload multiple files. already i have gotten some directions on this site as regards uploading a file and storing their paths in a database using this. <form method="post" action="addMember.php" enctype="multipart/form-data"> <p>...

php upload smaller image version of original

php,image,upload,webserver
I'm new to php and I've managed to get uploading images working to my webserver. Now I'm looking for a way to also upload a smaller duplicate version of the original image to my webserver. For example the original image that is uploaded is image1_timestamp.jpg I also want the same...

jQuery multiple file upload from scratch

javascript,php,jquery,ajax,upload
I am trying to implement a multiple image uploader in jQuery using the new HTML5 multiple attribute. My code is the following: <form action="file-upload.php" method="post" enctype="multipart/form-data"> <input name="userfiles" type="file" multiple="multiple"> </form> The JS code I am using is taken from a discussion here on SO, and is the following: $('input[name=userfiles]').change(function()...

Shiny reactive scan of archive, then write() it to download, fails in cat() -> argument type “closure” not handled

r,download,upload,shiny
I wanted to upload a file, change it in some way and then download it with some lines changed. The write() function can't be replaced for this code. There it is my summarized code: shinyServer(function(input, output) { inFile <- reactive({input$file}) archive <- reactive({scan(inFile$datapath, what = character(), skip = 1, sep=...

C#: Upload Photo To Twitter From Unity

c#,twitter,unity3d,upload,media
currently I am working with unity. In this project, I need to post some status with image to twitter. However, I got a problem to upload the image to the Twitter. Here is the code, which I used to upload the Image: private const string UploadMediaURL = "https://upload.twitter.com/1.1/media/upload.json"; public static...

Selenium - upload file to iframe

python,selenium,iframe,selenium-webdriver,upload
I have a test which has method to upload file in form located in iframe. The problem is that test not stable and sometimes fails with the error (run three times to get error example, third run failed): def fill_offer_image(self): driver = self.app.driver driver.switch_to.frame(driver.find_elements_by_name("upload_iframe")[3]) E IndexError: list index out of...

Uploading files using php very slow in xampp

php,mysql,file-upload,upload
I am new for developing.I have opted for php to learn coding.So I might make mistake as I learn by myself, kindly clarify my doubts. I have problem in uploading files using php to a folder.What I really do is, I upload a file and the file is saved in...

Unity3D, C# and uploading tracks to SoundCloud

android,unity3d,upload,soundcloud
I am working on an app in Unity3D which can upload tracks to SoundCloud. I have been working on this for a while but i can't get it to work. I am using HttpWebRequest for the request to SoundCloud and this works fine on Unity for Windows. But when i...

PHP upload script not functioning and no error on apache logs

php,upload
I created an upload script using the resources from tizag, the script is returning an onscreen error however no error in the apache logs. HTML Form <form action="upload.php" method="post" enctype="multipart/form-data"> <input type="hidden" name="MAX_FILE_SIZE" value="90000000" /> Select video to upload: Please choose a file: <input name="uploadedfile" type="file" /><br /> <input type="submit"...

How do I upload a file via HTML before passing it to a Javascript function?

javascript,html,function,file,upload
So I'm very new to the world of web development and have a project I'm working on in which I'd like a user to upload a .txt file before being returned another file containing an edited version of their file. The difficulty I'm finding is that JS seems to be...

PHP condition with IF working incorrect [duplicate]

php,if-statement,upload,condition
This question already has an answer here: Check if string contains specific words? 25 answers I have the following code, and when I upload a file with named "abc.htaccess" then it works correctly by showing "attacked", but when I upload abc.php or abcphp file name, then it tell me...

Upload picture NO plugin NO activerecord

ruby-on-rails,ruby-on-rails-4,upload,controller
i want to create a function into my controller to save a picture uploaded by an admin. I don't want to use plugin or Activerecord, just a function to write the bytes of the picture into the directory app/assets/images/ . So , when the admin create a new product he...

undefined index error - image upload same code is working with another example

php,html,mysql,upload,undefined
The image upload with php is not working for some reason can somebody here solve the problem? HTML code: <td>Business Image<br><td> <input type="file" name="photo"> <td><input id="button" type="submit" name="submit" value="Setup"></td> MYSQL: Table structure for table markers CREATE TABLE IF NOT EXISTS `markers` ( `id` int(11) NOT NULL, `name` varchar(60) NOT NULL,...

Change upload_dir folder at a certain cpt but cant change back

wordpress,upload,wordpress-plugin,wordpress-plugin-dev,custom-post-type
im try something with the upload_dir filter I check the current CPT with this function function get_current_post_type() { global $post, $typenow, $current_screen; //we have a post so we can just get the post type from that if ( $post && $post->post_type ) { return $post->post_type; } //check the global $typenow...

Multiple file upload with VlabsMediaBundle in Symfony2

php,symfony2,upload,bundle
i'm trying to make a multiple upload file on an entity with the vlabsmediaBundle. So i have an advert who can have many images but each can be linked with only one advert. I followed the tutorial(tuto) of the bundle but get an error. Here: Entity Image.php namespace MDB\PlatformBundle\Entity; use...

Add metadata (Exif) to base64

javascript,canvas,upload,exif
I'm trying to reduce images in client side before uploading them to preserve users' bandwidth and storage space in server side, while keeping informations about the original shot. Current process flow : fileReader -> canvas (drawImage) -> base64 -> XMLHttpRequest (to get progress) -> php server One drawback of this...

How to override error messages in MultiUploader in GWT

gwt,upload
I'm using GWT MultiUploader to upload files to the server. Max size of the uploading files should be 10MB. @UiField(provided = true) MultiUploader muplDef; public MyClass() muplDef = new MultiUploader(); muplDef.setValidExtensions("jpg"); muplDef.setMaximumFiles(1); muplDef.avoidRepeatFiles(false); muplDef.addOnFinishUploadHandler(onFinishUploaderHandler); muplDef.addOnCancelUploadHandler(onCancelUploaderHander); ... } In my web.xml file I set up the max size of the uploading...

Uploading file with Python and Alfresco API

python,curl,upload,alfresco
I'm facing a problem with Alfresco and Python : I want to upload a new file directly with Python. Each time I try I get a HTTP 500 error with no details ... I first try with CURL just to be sure that it works and the file is uploaded...

Best method for clearing temp upload folder

php,mysql,apache,upload,cron
On one of my current projects, I am allowing users to upload images and set them as profile pictures. The image initially will be stored in a temporary folder until the user crops & saves, or cancels the upload. Of course, there will be cases where they won't actually hit...

Storing a file into a database & uploading it in a webpage [closed]

php,mysql,database,file-upload,upload
Background I'm creating a website where the user can store an article as a file in the database and than upload the file's content into a page in the website using a form. The file may only contain text or image or both. Question Can anyone walk me through this?...

Gradle ant ftp error: “425 Connection timed out”

ant,gradle,upload,ftp,gradlew
I have a problem with my gradle build script: apply plugin: 'java' /* * Sources: * http://stackoverflow.com/q/17201815/4490015 * https://github.com/Vazkii/Botania/blob/master/build.gradle */ repositories { mavenCentral() } configurations { ftpAntTask } /* * Load configuration file. */ ext.priv = parseConfig(file('private.properties')) /* * Some project properties */ version = '0.0.1' group = 'randers.notenoughvocab' archivesBaseName...

Post Name to php MYSQL database

javascript,php,mysql,unity3d,upload
If I upload a set of letters, this php script dies with error|5, but if I use numbers for the $phpSign variable, everything works perfectly. <?php $device = $_POST["device"]; $randomChar = $_POST["randomChar"]; $phpSign = $_POST["Sig"]; if($mysql->query("UPDATE premium SET signup = $phpSign WHERE (id, randomChar) = ('$device', '$randomChar')")) die("success"); else die("error|5");...

ftp_put() error failed to open stream: No such file or directory

php,upload,ftp,tmp
So i am trying to create a php on webhost allow client to upload files to the webhost then webhost use ftp_put to upload file to another ftp server. The following function is used for upload the file. //upload ftp function ftp_upload($conn, $vid_name, $video){ //get tmp file $file_tmp_name = $video['tmp_name'];...

Codeigniter 2.0: Upload various files with form inputs with different names

php,codeigniter,file-upload,upload,codeigniter-2
I have a spent a few weeks with this issue, and have to ask you for help, I'm using Codeigniter 2.0, and load the file_upload library from autoload.php, but for some reason the files cannot be uploaded, and does not show any error when I do the do_upload function, here...

Media files end up in in a pycharm subdirectory when uploading

django,upload,directory,settings,media
I am building a Django application on a Windows system where the user should be able to upload images. But somehow my uploades files end up in my Program Files directory at: C:\Program Files (x86)\JetBrains\PyCharm Community Edition 4.5.1\jre\jre\bin\WebApp\media\TestData\static\images I just can't understand why I get this result. I would like...

Thumbnails in media library not showing after upload path change

wordpress,upload,directory,media
After making these changes to change the folder for uploads I can no longer see thumbnails in my media library after uploading. Could anyone suggest a fix? Screenshot: http://take.ms/wtGMZ Steps I took to do it: http://www.hongkiat.com/blog/wordpress-custom-upload-dir/...

scala/play - Make a File object from an uploaded file

file,scala,playframework,upload
I am using scala playframework. I am uploading a file. On the server side I am receiving the file successfully. I want to create a File object from it. How to do it? Here is the code that I have written so far. request.body.file("dataFile").map( currentFile => { // How to...

Upload image in directory

php,image,upload
I would try to write a script where users make their own questions. I was able to safely carry the fields such as title, description and some other details. But I want to make users upload images (also for the moment), unfortunately I can not, I ask therefore help to...

Preview thumbnail of an xls, xlsx, doc, etc file before upload

jquery,excel,upload,preview
I'm having hard time figuring out how to preview the file thumbnail image something like that before uploading it. So when i browse a file using file chooser and selecting the file i want to upload it will display its corresponding preview of what the file is, like .txt, .csv,...

PHP uploading an image

php,image,upload
I am struggling to get PHP to process a posted image. The code which supposedly gets the tempory link is here: $file = file_get_contents($_FILES["pic"]["name"]); But I get the error Warning: file_get_contents(): Filename cannot be empty The image is definatly being posted as running this: echo $_POST['pic']; prints the name of...

766 versus 666 Permissions on an Upload Directory [closed]

php,upload,permissions
Is 766 permissions okay for a directory where my website users can upload images to? I using 766 because when I set the directory to 666, the script returns an error and the file is not uploaded. Please is there any explanation for this? Thanks...

How to render video in browser before uploading it using angularjs?

javascript,html,angularjs,video,upload
I want to render the video in the browser before its uploaded to server.I have done the code in angular js. here is my codes html(jade) input(type='file' ng-file-select="readURL(this)" accept='video/*') video(width='320', height='240', controls='') source(id ='blah' src='#', type='video/mp4') javascript: $scope.readURL = (input) -> console.log "inside" if input.files and input.files[0] console.log 'hello' reader...

Issue with views on button click

django,image,twitter-bootstrap,upload,carousel
I am trying to make a carousel that you can upload pictures to. However, when I click on the upload button, It switches to another page, rather than giving me just the upload selection panel as Intended. Can anyone tell me why this might be? Views.py from django.shortcuts import render...

How do i properly refer to the indexes within $_FILES?

php,arrays,image,upload
I have the following code: foreach($_FILES['add_prod_image'] as &$image){ $target_file = $target_dir . basename($image["name"]); $uploadOk = 1; $imageFileType = pathinfo($target_file,PATHINFO_EXTENSION); I get the following error: Notice: Undefined index: name in /home/matthew/www/cart/admin/process.php on line 30 However when I var_dump( $_FILES['add_prod_image']['name']); I get: array(1) { [0]=> string(16) "plate with 5.jpg" } I'm trying...

Uploading a database to server

database,upload,server,local,host
How do I upload to my local host database to a server uses direct admin. I tried to take a .gz file from my local host database and when uploading it to the server It said that it is not a backup database. So do I have to create the...

PHP upload + dropzoneJS : allow only some files extensions

php,upload,dropzone.js
I'm doing a simple website in PHP, and I'm using DropzoneJS for uploading files. I'm attempting to allow only the following extensions: pdf, png, jpg, jpeg, bmp and txt . Any help please ? Sorry for bad english Here's my upload.php code $ds = DIRECTORY_SEPARATOR; $foldername = "../common/uploads"; if (!empty($_FILES))...

Upload an image or a txt and add it into a web page automatically

php,upload
I have an uploader that make me upload files to the server. I would like that when I upload an image, this image is automatically visible in a page of the site. Eg, if I have a site of a music band, if I upload from an administrator password protected...

PHP image uploads - moving from one type to many

php,image,upload,gd
Currently I'm able to upload jpg files, and I'm saving them as jpg files. Obviously I'm unable to upload/save png files as it's hard-set to jpg. I'm trying to work out how I can move from jpg only to allow png, jpg and jpeg. public static function createAvatar() { //...

why tmp_name is used in this example

php,file,upload
I am quite new to php.I was going through an example on file uploading.Here inside getimagesize() function $_FILES['file']['temp_name'] is used.and when i echoed $_FILES['file']['temp_name'] it shows the following output: C:\xampp\tmp\phpDE4B.tmp my questions are: 1.why use tmp_name instead of original name inside getimagesize() function. 2.For what reason this tmp_name is created...

Import photo to imageview

ios,swift,upload,imageview
I need to do, that user can upload photos from a photo(from device) into imageView. Add an action button? How it works? ...

PHP Image Upload Not Resizing When Sent Via JS

javascript,php,upload,image-uploading,image-resizing
I am running into issues when uploading an image sent to PHP via JS. I can upload the image fine, but I would to resize the image before moving it to it's new destination. I can also rename the image without any issues. It's really just the resizing that is...

Dropzone autoprocess queue false not working if there is an error like maxfilesize,maxfileuploads etc

jquery,file-upload,upload,dropzone.js
When I upload image of more size then permitted in dropzone autoprocessqueue does not works and shows process completed if I upload proper file then it works proper.Following is my code : Dropzone.options.myAwesomeDropzone = { url: 'file-upload.php', previewsContainer: ".dropzone-previews", uploadMultiple: true, parallelUploads: 100, maxFiles: 100, maxFilesize: 5, addRemoveLinks: true, autoProcessQueue:...

JSP upload file

java,apache,jsp,tomcat,upload
My Tomcat is "7.0.59" and I want to upload file to server. path as below: tomcat7.0/[server folder]/upload When I used localhost, file can upload to destination successfully. But when I used other computer as client, it can't work! (Server can get file name and other information correctly.) Do I need...

Upload File: Comsuming WCF Web Service Using Java

java,web-services,wcf,upload
I have a WCF Web Service (.NET C#). And I want to consume that service by java client application. I have a following code using that I am successfully able to connect with the Web Service. But now I am facing problem with uploadFile method. When I am passing string...

how should i import a huge table in phpmyadmin

php,mysql,upload,phpmyadmin
I have a table with 300,000 rows. then when i import it, it will uploaded almost 200,000 rows then phpmyadmin kills the upload with this error: Fatal error: Maximum execution time of 300 seconds exceeded in C:\xampp\phpMyAdmin\libraries\import\sql.php on line 246 Note: 'on line 246' is not unchanged. sometimes is 130...

Why when I try to upload an Image with Windows Phone it uploads a random thing?

c#,php,upload,windows-runtime,windows-phone-8.1
I'm trying to upload an image from my Windows Store App (Windows Phone 8.1) to hosting (using PHP) but always when I "uploaded" the image, and I check its result the "image" it's a corrupted file. I think it's related to the byte array conversion but I haven't found another...

Why UploadProgressChanged in WebClient.UploadFileAsync work not correctly?

c#,wpf,file-upload,upload
I'm upload file and get upload progress like this: using (var wc = new WebClient()) { wc.UploadProgressChanged += FileUploadProgressChanged; wc.Headers.Add(HttpRequestHeader.ContentType, "image/png"); wc.UploadFileAsync(new Uri(url), filePath); } ... private void FileUploadProgressChanged(object sender, UploadProgressChangedEventArgs e) { ProgressBarUpload.Value = e.ProgressPercentage; } But after 50% e.ProgressPercentage return -441850 and then immediately returns 100. Why is...

Why does submitting an upload form not send data?

php,sql,forms,upload
I'm trying to submit a form, that should upload a picture and also put it's name in the database, for some reason it does not submit anything nor upload anything, it goes on like nothing. The site reloads every time I submit. Form: <form name="myForm" action="" enctype="multipart/form-data" method="post"> <div class="id-input">ID:</div>...

Alamofire not sending upload-request (no connection established at all)

ios,swift,upload,alamofire
I want to upload a file, which has recently been downloaded (in my app) from the DocumentPicker (e.g. iCloud, Dropbox, ...) So I have the NSUrl (urlToFile) of this file (verified) I use this code to upload: upload(.POST, Config.uploadURL, urlToFile!) .progress { (bytesWritten, bytesWrittenInTotal, bytesToBeWritten) -> Void in println("Bytes: \(bytesWrittenInTotal)")...

Drupal 7 File Field Library

drupal,upload,drupal-7,drupal-modules
I'm trying to add a field of 'file' type that includes not only an upload button, but also a 'browse' or 'library' button that would show a list of already uploaded files. This would prevent having to upload duplicates if they are reused across the site. I've tried both iterations...