Random Quote Machine - with Facebook API - partially Solved

Can you please advice me what I am doing wrong with my code for Facebook Api. I manage to get random quote and tweet it successfully. Please some advice on facebook Api. I read the developer facebook page and created App Id as well. I tried hard to figure out why it is not working!!! please help me and much appreciated. here is my codepen link

Thank you

Here’s an error I see when I press Facebook button:

Try setting “http://s.codepen.io/” as the website URL for your app settings.

1 Like

Hi @mpontus thank you for your reply. Do you mean in my Facebook developer account? for app setting url field I enter the “http://s.codepen.io/” with or without full path of my project. it bypass the error message but it display a blank page after log into my facebook. thank you for your time and help to get rid this error. but no luck with post it. hope you can help with this. it is getting there nearly. Thanks

Do you see any errors if you open developer’s console on the blank page?

I’m afraid facebook API may be incompatible with codepen due to iframe sandbox settings. Try publishing your app on github pages or surge.sh.

Hi @mpontus thank you again for all your advice. I am still couldn’t feed the post due to developer facebook setting. I believe that need to approve my app and publish_action setting by Facebook team to make it work and it is a long process, but at least the Facebook code is correct in my codepen i have improved my code and more organised. meantime i move to my next project. . any feedback regarding code much appreciated. Thank you again for all your advice and help