Flickr: Add photos to my personal photostream - iphone

I found a similar problem in ' Let Users Submit To Our Flickr Feed (iPhone) '.
So, I want other people (using my iOS app) be able to upload photos to MY photostream.
I got it working with phpFlickr, using the setToken method and not using the auth method. (See bottom section how).
But I don't want to use this script and directly upload it to flickr, to cut out 'the middleman' (= my webserver), to limit data usage and server load etc.
I'm using the ObjectiveFlickr library for communication with flickr. Anyone who can give me a direction to work in or maybe a small piece of working code.

Related

Embed API demo not working

I tried using this Google Analytics Embed API Demo, of course with my own ClientID (49803909):
Embed API Demo
However, instead of the graphic I should be getting, I only get a blank page. I did follow the instructions quite carefully. Does this work for others? Any ideas of what may be wrong?
PS: Here's the screenshot of where I am getting the id from. #DaImTo was right that just 49803909 wasn't it, but I also tried to full long string and even the service id below (the one with #), all to the same effect (a blank screen). So, is this the wrong screen then?
I think #DalmTo is correct. You're most likely using one of the many other Google Analytics IDs instead of using a valid Client ID (which is not Google Analytics-specific, it's a general ID used for accessing Google APIs), and you're probably getting errors logged to the JavaScript console that say something to that affect.
If you follow the steps in this Embed API Developer Guide, you'll see instructions on how to create a Client ID to use with the Embed API.

Facebook Graph: Possible to upload photo to /user/account/album? If so, how?

I'm attempting to set up an app for a small set of known users, all of whom have a sub "page", "account" or whatever the terminology du jour is. The main goal of the app is to publish photos to these sub-accounts in an automated fashion on their behalf.
The crux of the issue seems to be that while I can ask for "manage_pages" to manage the user's sub-accounts and for "publish_stream" which allows me to upload photos to the user's root stream I can't upload photos to a subaccount stream.
I've been able to do a status update on the sub-account stream (text only), but every time I try to upload a photo (via curl, commandline-style), I get various errors depending on how I try to do it:
http://graph.facebook.com/albumid/photos -> Error #324 requires upload file
http://graph.facebook.com/albumid -> Error #200 application does not have the capability to make this API call.
http://graph.facebook.com/subaccount_id/feed - > Error #100 Source URL is not properly formatted
http://graph.facebook.com/subaccount_id/photos -> Error #324 requires upload file
I've stabbed around in the dark like this for about 4 hours with no luck and am beginning to wonder: Is posting a photo to a user's sub-account stream even possible? If so, how?
(BTW, I have tried doing a text status update with a photo URL -- attempting to circumvent the whole uploading part -- and that doesn't help. The url of the photo appears in the post, but does not show the photo. I'm open to any suggestion that shows photos in a subaccount stream.)
Only about 5 minutes after posting this, I kind of, sort of found a solution:
First, upload the image to your own web server, s3 bucket, or other location.
Second, use http://graph.facebook.com/subaccount_id/feed with source=http://www.thenewlocationofyourimage.com/image.jpg.
The image shows up in the page stream, albeit as a small thumbnail. Better than nothing, though. If you have better information, PLEASE let me know. Thanks!

iPhone web services NSURL

hi I am working on an application which takes data from a website and it displays it in table. I have been sucessful in making like an RSS feed (made like a twitter feed so I think it is an xmlparser) but now I want to get data from a website which doesn't have RSS feed in it..I just want to get the titles from the webpage.... any suggestion how do I do it without the XMLParser...
thanks
I think that the best way is to create on your server a php/asp/... page that will scrape data from the remote website.
Then, in that page, you can use some CURL to scrape data.
See here.
Next, you return the data in the format you want (XML/jSon/etc...).
Finally, you can easily call that script from your code.
On the other hand, pay attention to not scrape anything as skimming is generally illegal and Apple ca reject your app because of that.
There is a nice post talking about it.

Need to let user upload video using GWT

I need to let users upload videos in GWT site, and after uploading I should allow them to preview it. I don't need any controls, just a play and stop button would be enough so that I can show them a preview?
Uploading the video to your server is the easy part - that's what the FileUpload Widget is for. You just need to write some sort of end point on the server side - a servlet, PHP script, etc. that will receive the file and store it somewhere.
The tricky part is the preview - AFAIK, you need a media streaming server for that. The only free and good one I know is Red5 (site1, site2, site3 - don't know which one is the current one =_=).
An alternative would be to use an exisiting media streaming site that exposes an API for users to upload videos - like YouTube API. The docs show how to upload a file (directly from the user, or from your server) to the YouTube service - in return you'll get a link or HTML code to embed on your site.

How does facebook's Share a link feature work?

I'm trying to implement a feature like that where a user inputs a url and when displaying that url I want to have a custom display (an embed object if it's a video from youtube, a thumbnail if it's an image link, title and excerpt of body if it's a normal link).
How can such a feature be realized?
There is a new idea called oEmbed that a few sites support (Flickr, Vimeo and a few others) that addresses this problem. oEmbed site
Otherwise, just check the site against a list of ones you pick and then pull out the relevant bits to construct an embed link.
I liked the idea of oEmbed a lot but unfortunately it doesn't has that much adoption yet.
oohEmbed tries to solve this issue by building oEmbed for many websites.
For the feature to work, it needs the server's interaction where I believe the following scenario is how it works
Assume that we have the site humanzz.com and that it provides such feature
A user enters a url on the humanzz.com's webpage and presses a button like facebooks' preview button
An AJAX call is made to a dedicated page on humanzz.com
humanzz.com does calls the remote website and gets its data
The AJAX call now returns the page's data (oEmbed JSON object)
This involves so much server's overhead.
I really wanted to do it using JavaScript as the server's role was only to bypass "Same Origin Policy"'s restrictions.
oohEmbed allows bypassing the server's step by specifying a callback parameter to oohEmbed so that the JSON object returned is passed to a callback function on your page.
An example illustrating this is as follows
Add a script tag dynamically to your page
< script type="text/javascript" src="http://oohembed.com/oohembed/?url=http%3A//www.amazon.com/Myths-Innovation-Scott-Berkun/dp/0596527055/&callback=myCallBack">< /script>
This would result in executing myCallback(oEmbedJSONObject) which is great.
The problem with that solution is you still have to have a fallback for websites that don't have oEmbed representations.
For the embedded things, I have been using auto_html ( https://github.com/dejan/auto_html) with great success (vimeo, youtube, images) and even added soundcloud myself. But I am still looking for a "thumbnail" generation with an image and text facebook-like.
I guess you have to construct it by yourself by manually parsing the kind of URL you get.
If it is an image url, well then you just have to rescale it and in case the user clicks on it, then handle that by opening the original one somehow.
If it is a link to some youtube video, then you have to take a look at how the embedding of Youtube videos works. You can just copy the code that is provided by Youtube itself, and then exchange the parts with the URL to the video with the URL you got from your user.
I did never implement something like that, but I assume it should work somehow like this.