Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

chrome example extension not working

I have downloaded the code as it is from this link from chrome site

And tried to load the extension however the images do not get loaded and a small rectangle box is displayed.I tried to follow this link but no such error is present in the file i downloaded.Can anyone help please?

like image 397
nnm Avatar asked Jun 30 '26 08:06

nnm


2 Answers

Quick Google search of that error and based on its description, it's a problem with the app's API key for Flickr. You can find the key in the example code at line 25.

searchOnFlickr_: 'https://secure.flickr.com/services/rest/?' +
  'method=flickr.photos.search&' +
  'api_key=90485e931f687a9b9c2a66bf58a3861a&' +

I encountered this before with this kittens example and you have to wait until the key is reactivated. I'd suggest just getting started with another simple sample, such as "A browser action with a popup that changes the page color".

like image 139
Murdeth Avatar answered Jul 02 '26 23:07

Murdeth


What I did:

  1. Go to "popup.js", find the query url, concatenate it, paste it to browser, found out the API key expired
  2. Search for "Flickr API key register", go to the registration page
  3. Register for a Yahoo account
  4. Register a Flickr API key using that Yahoo account
  5. Replace the old API key in the query url with the one you just created, and enter that in the browser, confirm that it works
  6. Replace the old API key in the popup.js with the new one
  7. Now when you click the extension button again, it should show kitten pictures.

Finding out where the problem lies is not as hard as you may think.

like image 36
AsyncMoksha Avatar answered Jul 02 '26 21:07

AsyncMoksha