使用android在Flickr上传图片

时间:2012-07-30 05:39:01

标签: android flickr

我需要将Flickr与android集成。我完成了authentication.i需要上传图像到flickr但我不知道如何做同样的事情。 我推荐文件:http://www.flickr.com/services/api/upload.api.html。 任何人都可以帮助我

1 个答案:

答案 0 :(得分:3)

enter image description here

//change your key and secreat key
private static final String API_KEY = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"; //$NON-NLS-1$
public static final String API_SEC = "xxxxxxxxxxxxx"; //$NON-NLS-1$

View.OnClickListener mFlickrClickListener = new View.OnClickListener() {

    @Override
    public void onClick(View v) {
        if (fileUri == null) {
            Toast.makeText(getApplicationContext(), "Please pick photo",
                    Toast.LENGTH_SHORT).show();

            return;
        }

        Intent intent = new Intent(getApplicationContext(),
                FlickrjActivity.class);
        intent.putExtra("flickImagePath", fileUri.getAbsolutePath());
        startActivity(intent);
    }
};