This is what your URL will look like
Your FB App ID is the FB Application IDremember to add https:// to the beginning
graph.facebook.com/oauth/authorize?type=user_agent&client_id=Your FB App ID&redirect_uri=http://Your Site Path&scope=publish_stream,offline_access,manage_pages
Your site path is what you defined in your FB application under the Web Site Profile. http://www.yoursite.com or http://www.yoursite.com/cart/
If you have done it correctly when you activate that in your browser it will take you to your zen cart.
Look back into your browser address bar and copy and paste the entire string that you see (to be saved locally on your computer)
what you will see is something like this.
copy and paste everything between the access_token= and the &expiresthere will be an http://www. at the beginning
yoursite.com/#access_token=some very long number and letter&expires_in=0
this is called your URL parameter access_token - this is the big bad boy that will gleam the rest of the information that you need to tell FB what page for zen cart to access and post the new products to.
Next step take that very long string that you just copy and pasted locally and insert it into the following URL
activate the string in your browseradd https:// to the beginning of the string
graph.facebook.com/me/accounts?access_token=Your URL parameter access token
if you have done it correctly what is then gleamed is all the fan pages that you manage, along with the page ID and Page Access token for each fan page managed
copy and paste this locally for future reference{
"name": "Bugs Bunny Frontier",
"category": "Websites",
"id": "29469045921",
"access_token": "some secret string."
"name": "Daffy Duck Play Pen",
"category": "Websites",
"id": "15326801473",
"access_token": "some secret string."
"name": "Mother Goose Brothel",
"category": "Websites",
"id": "19785012358",
"access_token": "some secret string."
},
Now you have the Page ID and the Associated Access Token for that page
Go back to your editor in the update_product.php
replace the Page ID with the one that matches the page you want zen cart to post to.
then replace the Page Access Token on the line directly below with the one that matches the Page ID you put in the line above.
Save and upload to your server then test - if all went well it will now be posting the page of your choosing.
Jamielife will be adding a drop down option on his next release that will make it simpler in the future to pick which page for zen cart to post to - this is only a temporary procedure for the release that is currently out for us.



Reply With Quote
