facebook_api.createFacebookWallFeed = function(video)
{
    var comment = video.comment;
    if (comment != '')
    {
        comment = '"'+comment+'"' + "\n\n";
    }

    feedAttachments.caption     = feedAttachments.caption.replace(/\[rating\]/, parseInt(video.rating));
    feedAttachments.description = feedAttachments.description.replace(/\[comment\]/, comment);
    
    FB.Connect.streamPublish(null, feedAttachments, null, null, 'Skriv på din facebook wall.', function(post_id, exception, user_message)
    {
        if (post_id != null && post_id != 'null')
        {
            var data = {
                videoId: video.videoId,
                postId: post_id
            };

            $.post(websiteUrl + 'service/video/add-recommendation/', data);
        }

        popup.hideBackground();
    });
}