LucasFerreira LucasFerreira - 1 year ago 88
PHP Question

How to auto share a post on facebook timeline?

I have a website that uses the Group Buying Site plugin ( It uses facebook app to login and register.

When I add a new item to the cart the user is redirected to

and the function
add_item($product_id, ...)
is called. I want to know if there is a way that when I enter this page I automatically share a post on facebook timeline.


Answer Source

Assuming you have the access token, I suggest you try this:

$result = $facebook->api(
    array('access_token' => $access_token, 'message' => 'Your Post here')
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download