• Hello,

    Around a month ago, i got a custom bookmarklet coded for my wordpress blog and on top of the bookmarklet .js code there is this line
    var token = 'QzEJ5PJ3/RRO4cubQQiKKNg5au6SESUSkQOK5w9HKFgH6GxVu1NNilA5TYqoMBbz6sKdZP6eQ4GeLyZ1Ht5S/VrHIISvHXKFPxXNUZmRp1M=';

    I think this is some sort of API key or something that’s specific to a wordpress installation right? cause when i move the code from one blog to another, it does not work.
    Unfortunately the coder that i hired is unreachable now and i am not sure how and where to fetch this key from.
    Can someone please point me to where i can get this value off my wordpress instalation?

    Thanks and Kind Regards.
    Wpb.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Is the plugin you have coded accessing data from an external source?

    You don’t need to have a token declared for your WordPress installation to function properly.

    Thread Starter wpbaxter

    (@wpbaxter)

    @themesumo : its a bookmarklet that fetches data i.e. images from other blogs, its similar to pinterest image bookmarklet.

    • This reply was modified 9 years, 6 months ago by wpbaxter.

    I don’t really know what you’re asking then as this is related directly to your own custom plugin, and the API service the plugin is making use of.

    WordPress doesn’t require, or offer, any keys or tokens that you need to make your site function correctly.

    If you’re simply trying to use the same token/key on a different WordPress installation then perhaps the token/key is specific to a URL perhaps?

    Sorry to not be of much help.

    Thread Starter wpbaxter

    (@wpbaxter)

    @themesumo : Its alright, i am really glad you are willing to help tough 🙂 i really appreciate that 🙂

    Btw can you please take a look at this code, this is the full code for the plugin
    http://snippi.com/s/sufk1vc

    Maybe this will give an idea what that top line is used for and what i need to do in order to make this plugin work on other domains? I am sorry for such noob questions but i am really not familiar with this programming stuffs.

    Anyways, i would really appreciate if you take a look and if possible maybe help me a bit further?

    P.S. I did change all the domain entries from labs4.imvges.com [old installation] to labs5.imvges.com [new installation] [just thought you might wanna know that i am aware that this needs to be changed too]

    I’m not particularly strong with JavaScript to be honest, I get the gist of what the plugin is doing but I don’t see any references to an external API or anything so it’s difficult to see where the token may have come from.

    If the token doesn’t work on different domains then I would guess that the API service you’re using is domain specific, I very well may be wrong here.

    Hopefully someone with more JS experience can shed some light on it for you.

    Thread Starter wpbaxter

    (@wpbaxter)

    @themesumo, i found the token code in one more file bookmarklet.php, can you please take a look at it and let me know if there is something in this file that restricting the plugin to work only on 1 specific domain?

    http://snippi.com/s/l4xof8g (Bookmarklet.php)
    http://snippi.com/s/8ewe4z6 (Bookmarklet.js)

    • This reply was modified 9 years, 6 months ago by wpbaxter.

    Hi, the token won’t include information about the domain restriction (if there is one), I would think that will be declared on the API service itself, when the token is generated perhaps.

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

The topic ‘How to Get WordPress API Token?’ is closed to new replies.