Ask your JavaScript questions! Pay money and get answers fast! Comodo Trusted Site Seal
Official PayPal Seal

FB.Event to respond after the fb:like post wall dialogue closes JavaScript

Really need some help with this please.

I have this fb:like button...

<fb:like id="fbLikeButton" href="'.$furl.'" show_faces="false" width="450"></fb:like>

And I am redirecting/responding when the like button has been liked. Using FB.Event.subscribe...

jQuery(document).ready(function() {
FB.Event.subscribe("edge.create", function(href) {
var data = { action: "virallocker", myID: "'.$my_id.'"};"viral-lock.class.php", data, function(response) {
if (virallocker_use) location.reload();

See what happens as standard when you click a 'Like Button' - the post wall dialogue appears...

[[LINK href=""]][[/LINK]]

Now the problem I am having is that the location.reload(); in the javascript, is firing before the 'Post to wall' dialogue has been completed or closed.

location.reload(); runs when the Like button is clicked.

My question is, can someone help me adjust the script so the response runs after the Post to wall dialogue has been closed or posted, instead of the 'Like' button being clicked.

See my problem here on the 'Like' button... [[LINK href=""]][[/LINK]]


Answers (0)

No answers yet.