Get an image from photo library and upload it to web service by name and path - iphone

I am creating a web service based iphone application in which a certain place i need to post an image on to the web for which i want to select image from photo gallery of phone and then i need to get the name and the path of the image on textfield and then uploading of the image.
or when pressing the browse button image picker will show all the image of the iphone and by selecting image it will return its path and name by which we can upload it.

Please check the similar question first.
To fully understand the answer you should also need to read UIImagePickerController Class Reference and ASIHTTPRequest documentation
As ASIHTTPRequest library is not supported more by its author, you may use another open source solution - AFNetworking or even the Cocoa classes, described in the URL Loading System Programming Guide

Related

How to get all the Photos from Built In Gallery into our application without using UIPickerController

I have been using UIPickerController to get the pics from my Built-in-Gallery into my own Application, But the issue is that the delegate related to that UIPickerCOntroller get only one pic at a time and returns me only one image. So i need to get the images one by one from PHotoGallery.
Now i want to implement my own Photo-Gallery so that i could get multiple images from Built-In photo Gallery.
Can you guys guide me how to access Builtin Gallery photo Folders and fetch all images from there into my Array so that i can make my own Photo Gallery with Multiple Selection Option
Or PLease tell me if i can manage the Multiple Selection Option from UIPickerController.
I guess Apple should provide us atleast this sort of feature that we can select multiple photos at a time from Photo gallery.
PLease guys Can u guide me with some code from any of these two Options
Thanks
you want to use the Assets Library framework. take a look at this blog post for more details:
http://www.fiveminutes.eu/accessing-photo-library-using-assets-library-framework-on-iphone/

Using a UIImagePicker that only contains photos taken within the app

I'm using source code from apple (SquareCam) and I would like to figure out how I can use the photos taken in that app and see them in a library (like the photos app) without having all the other photos the user has taken elsewhere like in the regular camera.
I'm not too great at making apps yet so I'm pretty noobish.
I've gotten as far as opening the photo library but nothing else. no viewing individual photos or the options such as emailing, messaging and what not.
Don't think you can do that. It either all photos or no photos...
You can of course save the photo in your own documents directory and write your own photo viewer - there's quite some code and frameworks around that do most of the job, see e.g. the answers to this so question:
Open source photo viewer for IPhone

iOS photo gallery - flickr

I'm working on an app for a client and the client wants absolutely everything to be shareable (using sharekit). One of the views that the client wants is a photo gallery that can be easily updated and viewed. I've looked around at folks who have done this and I particularly like the way the Obama 2012 app does it using flickr. This brings me to the question, I'm trying to use the flickr api to display a photo gallery that will allow sharekit to share the url to the image but am hitting a brick wall. I've searched for a few days now and haven't found a tutorial that shows a working example in the way I need it, if anyone has done something similar or knows a good tutorial that would be greatly appreciated.
Download the list of images using the Flickr API, and asynchronously add them to a UIScrollView inside a UINavigationController with its back button as "back". Then add a UIToolBar which has the items 'Next' and 'Previous' (use images). That will give you the look of a photo gallery.
Also, I came across this which is basically what I told you to do, but open source: http://www.cocoacontrols.com/platforms/ios/controls/fgallery
I wrote a tutorial on building a media gallery using a UICollectionView. It populates from the user's photo library, but is definitely more extensible than using a 3rd party.
iPhone Programming Tutorial: Creating An Image Gallery Like Over – Part 1
Hope that helps. Cheers!

Adding photo upload to an iPhone App that's mostly HTML5/JS

I'm working on an iPhone App that's HTML5/JS displayed in a single UI Webview. I'd like to add photo upload capabilities, and I'm wondering what the best approach would be to extend the iPhone app with the necessary classes to pick a photo and upload via an API. I'd also like to trigger the display of the photo picker via JS if that's possible.
I know it's possible to use a framework like PhoneGap to do this, but I don't want to migrate the whole app to a new framework yet. Also, sorry for the "how to" type question - I normally ask about specific problems after I've exhausted my efforts, but I'm pretty new to Objective C, so I'd appreciate some guidance, even if it's just a simple design explanation.
the image picker (UIImagePicker) is fairly straightforward to work with: http://developer.apple.com/library/ios/#documentation/uikit/reference/UIImagePickerController_Class/UIImagePickerController/UIImagePickerController.html
and for an API, are you sending it to an existing system? or creating your own. You just need to craft an NSMutableURLRequest with POSTED data in a multi-part format, and then handle the image portion appropriately in your server.
this might help: upload image from iPhone application

Saving images inside iPhone application without using database or server side saving technique

I am developing an application which requires saving images in the "saved folder" of iPhone Photo album after performing some animations on ImageViews. Is it possible to save the incomplete images temporarily in the iphone application without using database or server side saving technique, so that user can use it for future use and only completely changed ones should get saved in Photo Album? If yes then it would be a great help to get any code or suggestion.
Thanks in advance :) !!!!
Sure, images can be converted to NSData objects, which can then be written to a standard file. Check out UIImagePNGRepresentation() and -[NSData writeToFile:atomically:].
You can then save to the standard native Photo album application using the technique described here (from a UIImage instance):
How to save picture to iPhone photo library?