Jump to content
Robert1995

Quick Post to facebook wall/friend page/ etc ...

Recommended Posts

Posted (edited)

Includeti fisieru, eu il foloseam ca partiala sa pun pe facebook ceva de genul User did X pe site-ul X apoi sa il trimit de acolo undeva, have fun.

De mentionat trebuie sa aveti inclusa libraria javascript de la gigya


<script type="text/javascript" src="http://cdn.gigya.com/js/socialize.js?apiKey=<?php echo $this->config['apiKey'];?>"></script>
<script type="text/javascript">
var conf=
{
APIKey: '<?php echo $this->config['apiKey'];?>',
}
</script>

Key de dev : 2_Y82PzwJ_chSFImHXaIDJClnLyJzmk-VFOavSsaNTzl6m901s_NNxRAS0xJ3bd3_N


<?php

if(!isset($this->title,$this->link_back,$this->description,$this->redirect_link)){
throw new Exception("Invalid parameters set to facebook post to wall");
}

?>
<script type="text/javascript">
// Constructing a UserAction Object
var act = new gigya.services.socialize.UserAction();

act.setActionName("Test");
act.setTitle("<?php echo $this->title;?>"); // Setting the Title
act.setDescription("<?php echo $this->description;?>"); // Setting Description
act.setLinkBack("Read More", "<?php echo $this->link_back;?>"); // Adding Action Link
var params =
{
userAction:act,
callback:redirect_user_to_post
};

function redirect_user_to_post(){
window.location = "<?php echo $this->redirect_link;?>";
}

// Publishing the User Action
gigya.services.socialize.publishUserAction(params);

</script>

Edited by Robert1995
Mispell

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...