photo-upload

Phonegap Image Upload works only once

怎甘沉沦 提交于 2020-01-07 03:41:15
问题 my app needs to upload photos to a server. This works great when uploading the first captured photo. When I capture another photo, the upload fails. Here is my code: // Upload files to server function uploadFile(mediaFile) { $.mobile.loading( 'show' ); var path = mediaFile; alert(path); var options = new FileUploadOptions(); options.mimeType="image/jpeg"; var params = new Object(); params.fullpath = path; params.eventID = eventID; options.params = params; options.chunkedMode = true; var ft =

OAuthException when trying to upload/post photos to group

三世轮回 提交于 2020-01-03 22:58:46
问题 I am currently trying to upload photos to pages and groups through an app. I have these codes: try { $facebook->setFileUploadSupport(true); $args = array('message' => 'This is my image caption',); $args['image'] = '@'.realpath('./uploads/terragarden1.png'); $response = $facebook->api('/GROUP_ID/photos/','POST',$args); } catch(FacebookApiException $e) { echo "Error: ".$e; } The value of $args['image'] would be something like this: @/home/publica/public_html/AutoPost/uploads/terragarden1.png

OAuthException when trying to upload/post photos to group

烈酒焚心 提交于 2020-01-03 22:58:23
问题 I am currently trying to upload photos to pages and groups through an app. I have these codes: try { $facebook->setFileUploadSupport(true); $args = array('message' => 'This is my image caption',); $args['image'] = '@'.realpath('./uploads/terragarden1.png'); $response = $facebook->api('/GROUP_ID/photos/','POST',$args); } catch(FacebookApiException $e) { echo "Error: ".$e; } The value of $args['image'] would be something like this: @/home/publica/public_html/AutoPost/uploads/terragarden1.png

Exception when uploading photo with Facebook Graph API

拈花ヽ惹草 提交于 2019-12-18 13:34:21
问题 I would like to upload a photo to facebook for a user in the default album for an application. This is described under publishing here: http://developers.facebook.com/docs/reference/api/photo The method has been answered here: How can I upload photos to album using Facebook Graph API. I am using the following: $args = array( 'message' => 'Photo Caption', 'image' => '@'.realpath("image.png") ); $data = $facebook->api('/me/photos', 'post', $args); However I get the exception "(#324) Requires

User must have accepted TOS - Facebook Graph API error when posting photos to group page

蓝咒 提交于 2019-12-12 13:15:27
问题 I've been struggling to upload an image from the user's computer and posted to our group page using the Facebook Graph API. I was able to send a post request to facebook with the image however, I'm getting this error back: ERROR: (#200) User must have accepted TOS. To some extent, I don't believe that I need the user to authorize himself as the photo is being uploaded to our group page. This below, is the code i'm using: if($albumId != null) { $args = array( 'message' => $description ); $args

Uploading photo to server to use as profile picture.

旧街凉风 提交于 2019-12-12 01:05:44
问题 I have a problem that I'm working with right now. Currently I have a registration form that accepts a few fields from the user and a picture upload field for the profile picture. Currently the profile picture name is being inserted into the database but when viewing the folder of the target location there is no sign of the picture. Right now the page goes white and loads a little tiny broken picture in the top left hand corner. Any advice? Profile Page <?PHP ob_start(); error_reporting(E_ALL)

How do I use File Handlers in Sweetalert?

…衆ロ難τιáo~ 提交于 2019-12-11 14:04:52
问题 I am very new to JavaScript so I am guessing, that this problem will be fairly simple for most of you guys (or at least I hope so...) I have this SweetAlert Code. It asks the User to upload two images and one text. I am able to add the text to my database but I am struggling with the images... I know that I need to pass the Images using the File Handlers, but I don't know how... This is my Server that I run my Code on: https://mars.iuk.hdm-stuttgart.de/~mk304/Web_Projekt/webpage/ui/sweetalert

Photo Upload to own wall via iOS Graph API with user's location

笑着哭i 提交于 2019-12-11 04:24:21
问题 I need to post a photo (taken form the camera) in the users facebook wall with the location of the user. Now, the facebook photo object has a field named place: object containing id and name of Page associated with this location, and a location field containing geographic information such as latitude, longitude, country, and other fields (fields will vary based on geography and availability of information) Now how do I get the place, attach it with the photo and upload it in the users wall.

ObjectiveFlickr Photo Upload Error

别来无恙 提交于 2019-12-05 03:03:09
问题 I'm working on using the ObjectiveFlickr library to upload photos to Flickr from my iPhone app. I am able to authorize the app and perform general requests, but I am getting an error while trying to upload a photo. The photo is meant to be uploaded is an image captured using AVFoundation. Here is the relevant code: UIImage *image = [[UIImage alloc] initWithData:imageData]; if ([[AppDelegate sharedDelegate].apiContext.OAuthToken length]) { NSData *uploadData = UIImageJPEGRepresentation(image,

Facebook PHP SDK app to upload photo to page

安稳与你 提交于 2019-12-04 04:21:21
问题 I am trying to create a Facebook application that uploads images to a page. I can manage to upload photos to the user's photo album but not to the page's. Here's my code: require_once('php-sdk/facebook.php'); $config = array( 'appId' => 'XXXXXXXX', 'secret' => 'YYYYYYYYYYYYYYYY', 'fileUpload' => true, ); $facebook = new Facebook($config); $user_id = $facebook->getUser(); $photo = $_POST['image']; $message = "Lorem ipsum"; echo $user_id; if ($user_id) { $ret_obj = $facebook->api('/XXXXXXXXXX