Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How to upload at facebook news feed section

Posted on 2010-11-23
2
Medium Priority
?
467 Views
Last Modified: 2013-11-13
Hello Sir

I want to upload any file at facebook news feed option.Means when i upload any file at server from my website that time it shall also upload at facebook news feed section.Then please guide to me how to do this.
Regards,
Aasim afridi
0
Comment
Question by:rAfridi
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 2

Accepted Solution

by:
karthi4all earned 2000 total points
ID: 34203034
1.Use the facebook php sdk, from
https://github.com/facebook/php-sdk/

2.settup an application profile

http://www.facebook.com/developers/


3, here is the code to post to wall

 public function postToWall($id, $message, $picture, $link, $name, $description) {
        try {
           $fb=new Facebook();
            $result = $fb->api("/$id/feed", "POST", Array(
                        'message' => $message,
                        'picture' => $picture,
                        'link' => $link,
                        'name' => "your app name",
                        'description' => $description
                    ));
            return "ok";
        } catch (FacebookApiException $e) {
            return false;
        }
    }

note : go through the sample code in sdk to find how to setup app, you can google and find lot of tutorials for that..
0
 

Author Closing Comment

by:rAfridi
ID: 34523494
good answer
0

Featured Post

[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

3 proven steps to speed up Magento powered sites. The article focus is on optimizing time to first byte (TTFB), full page caching and configuring server for optimal performance.
This article will show how Aten was able to supply easy management and control for Artear's video walls and wide range display configurations of their newsroom.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
Suggested Courses

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question