how to publish on wall

Jun 8, 2009 at 11:56 AM

please help to publish on the wall



Rajesh Thakur


Jun 8, 2009 at 5:19 PM

well since you left the question so open ended, and since there are probably a dozen ways to answer it, I will pick one way to publish to the wall and share that:

You will need to create a template using the FB Developer tools or using code.  The template ID needs to be in your web.config file under the setting "SomeTemplateName" (or just hard-code it in the java script).  In the tempalte referenced in this example there is one custom tag, {*thing*} - modify this script to match the tags in your template.  In this example I ahve set the single image attachment to link to the home page of my application but you could make that any URL you want for each of multiple images you can attach.

Use the wiki to see full specs for showFeedDialog to see what I am not using - null parameters int eh call, they might be useful for you.

<script type="text/javascript">

        function publishToWall(thingname, friendFBID, thingImageURL) {
            var template_data = {
            "thing": thingname,
            "images": [{
            "src": thingImageURL, "href": '<%= String.Format("{0}", System.Web.Configuration.WebConfigurationManager.AppSettings["APPROOT"]) %>'}]
            var continuation = function() { return true; };
            var templateID = '<%= String.Format("{0}", System.Web.Configuration.WebConfigurationManager.AppSettings["SomeTemplateName"])%>';
            Facebook.showFeedDialog(templateID, template_data, null, friendFBID, continuation, null, null);
            return false;

If you are not doing a FBML Canvas application this answer probably won't help, but you didn't specify so I had to guess :)


ASCIT Consulting



Oct 20, 2009 at 6:30 PM

Hi David

Very helpful reply

what if I don't use PHP?

I am using Python as the web framework...

how can I do what you described with python?