Monday, 26 August 2013

Facebook share for mobile

 function fbShare() {
      var URL = "";
            var title = document.title;
            var url1 =  location.href;//"https://www.facebook.com/dialog/feed?app_id=100000";
            var summary = "Not your money. Not your clothes. Not your time or attention. We want something that you do not even use.Your caller tune can help spread awareness about some of the health issues we face today.";
            var image = "http://www.donateyourcallertune.in/images/200_200_logo.jpg";
          //  var openwin = decodeURI('https://www.facebook.com/dialog/feed?app_id=1000000&p[title]=' + title + '&p[summary]=' + summary + '&p[url]=' + url + '&p[images][0]=' + image + '');
            // window.open('http://www.facebook.com/sharer.php?s=100&p[title]=' + title + '&p[summary]=' + summary + '&p[url]=' + url + '&&p[images][0]=' + image + '', 'facebook-share-dialog', 'width=626,height=436')
           // window.open(openwin, '', 'width=626,height=436');
            //window.open('http://www.facebook.com/sharer.php?s=100&p[title]=' + title + '&p[summary]=' + summary + '&p[url]=' + url + '&&p[images][0]=' + image + '', 'facebook-share-dialog', 'width=626,height=436')

            //window.open('http://www.facebook.com/sharer.php?s=100&p[title]=' + title + '&p[summary]=' + summary + '&p[url]=' + url, 'sharer', 'toolbar=0,status=0,width=626,height=436');
            //            window.open('http://www.facebook.com/sharer.php?u=' + encodeURIComponent(url) + '&t=' + encodeURIComponent(title), 'sharer', 'toolbar=0,status=0,width=626,height=436');



            URL = "https://www.facebook.com/dialog/feed?app_id=100000";
            URL += "&title=" + title;
            URL += "&picture=" + image;
            URL += "&description=" + summary;
            URL += "&link=" + "http://*******.in";
            URL += "&redirect_uri=" + "http://*******.in";

            window.open(URL, 'sharer', 'toolbar=0,status=0,width=626,height=436');
    
    
        }

No comments:

Post a Comment