Sha256: e53719e2869889b08561e879467764e9adf4d8a9adbcef22d89ab09a87fc8f6d
Contents?: true
Size: 500 Bytes
Versions: 5
Compression:
Stored size: 500 Bytes
Contents
var upload_service = angular.module("UploadService",[]); upload_service.service('upload_service', ['$http', function ($http) { this.uploadFileToUrl = function(file, uploadUrl){ var fd = new FormData(); fd.append('file', file); $http.post(uploadUrl, fd, { transformRequest: angular.identity, headers: {'Content-Type': undefined} }) .success(function(){ }) .error(function(){ }); }; return this; }]);
Version data entries
5 entries across 5 versions & 1 rubygems