Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter benedictcollins

    (@benedictcollins)

    If a blog is running JetPack you can comment on a post by entering an name and email address, or you can ‘sign on’ to your WordPress account ( and Facebook etc.) and post a comment using these credentials.

    This plugin requires you to login to a local account associated with the blog, but not with a wordpress account.

    I can use Oauth and call https://public-api.wordpress.com/rest/v1.1/me which gives me a response with
    Display_Name, email, profie_URL and avatar_URL, but these details can’t then be used to post back a comment.

    I have amended the plugin so instead of calling user_info to get this for the locally logged in person, I then use the details (above) I get back from WordPress, and this will work OK, but it’s not very neat.

    It would be better to have a solution that has the wordpress.com account login option as well as the Facebook login option, then allow posting back of comments using these credentials, so you don’t need to have a local account on the blog at all.

    Just extending the API to offer more login options and not requiring a local account.

    Thread Starter benedictcollins

    (@benedictcollins)

    Hi Ali,

    Appreciate you looking into this.

    Thanks

    Ben

    Thread Starter benedictcollins

    (@benedictcollins)

    After looking at this for a hours and posting a question, I found the issue.

    I added realised that ‘success’ means it just got a valid response, but the response could be an error message so I amended success to be.

    success: function(response){
    if (response) {
    console.log(‘got a response’);
    console.log(response.status);
    console.log(response.error);

    And found the obvious mistake of using ‘comment’ as a parameter instead of ‘content’

    It’s not working.

Viewing 3 replies - 1 through 3 (of 3 total)