I've installed everything, created and mapped a content type, and everything looks great until I go to the content generator and try to bring in some topics. Although I entered and saved my api key, whenever I try to import topics I get

You need to set your npr API key, click here or if you don't have one, click here to get one

I'm hoping it's something simple (or stupid) on my part, really enjoyed the screencast and am looking forward to using the module.

Comments

pwaterz’s picture

Try going to api.npr.org and use the query generator make sure your api key is valid.

mwoodwar’s picture

It seems to run fine at NPR ?

pwaterz’s picture

This was a bug which I have fixed. I have taken down the stable release and changed to development release. This is a brand new module, thought I caught all the bugs, but I guess not. The download like for the development version may not show up for a little while so you will need to use git if you want it now. Run this on the command line git clone --branch 6.x-1.x-dev http://git.drupal.org/project/npr_package.git

pwaterz’s picture

I just updated to 6.x-1.1, download that release for the fix. Sorry still getting use to git.

pwaterz’s picture

Component: User interface » Code
Status: Active » Closed (fixed)
mwoodwar’s picture

Thanks. I downloaded the update via drush ( git clone --branch 6.x-1.x-dev http://git.drupal.org/project/npr_package.git) and I see that it created a git dir on my system...but do I need to do anything else or does the 'clone' command update the modules?

Sorry for being dense, but if you think you're new to git...I am really struggling :>)

pwaterz’s picture

please just disregard that git clone. Just download the most current version 6.x-1.1 from the http://drupal.org/project/npr_package

mwoodwar’s picture

I did just that...I no longer get the api key not recognized, ut whatever query I run (one keyword) I get:

NPR Content Generator
Alert: your search did not return any results please try a less complex query.

Thanks in advance

pwaterz’s picture

Try and run a query with nothing selected.

mwoodwar’s picture

I checked to make sure that NOTHING was selected, and got the same result:

NPR Content Generator
Alert: your search did not return any results please try a less complex query.

pwaterz’s picture

I just installed a fresh install and it worked perfect.

1. Are you connected to the internet?
2. Did you update to the 6.x-1.1 release?
3. Did you uninstall the module before you updated it? (This shouldn't make a difference but just to be through)

If you can still not get it to work, if you want, we can arrange a screen share using http://www.join.me

mwoodwar’s picture

I've done everything except completely uninstall and reinstall. Let me try that, and if I'm still stumped I'd love to do a screen share

pwaterz’s picture

Status: Closed (fixed) » Active
mwoodwar’s picture

Doing a complete un/reinstall seemed to do the trick...thanks for your help!

I went to save some stories, and got a page of errors that looked like this: I 'think' my mapping is ok, but I'll double check.

463.
warning: fopen() [function.fopen]: URL file-access is disabled in the server configuration in /home/clients/websites/w_make/public_html/make/sites/all/modules/contrib/npr_package/npr_api/npr_api.module on line 519.
warning: fopen(http://api.npr.org/m3u/1106193971-dfbf01.m3u?orgId=1&topicId=1017&aggIds...) [function.fopen]: failed to open stream: no suitable wrapper could be found in /home/clients/websites/w_make/public_html/make/sites/all/modules/contrib/npr_package/npr_api/npr_api.module on line 519.
warning: file_get_contents() [function.file-get-contents]: URL file-access is disabled in the server configuration in /home/clients/websites/w_make/public_html/make/sites/all/modules/contrib/npr_package/npr_api/npr_api.module on line 463.

pwaterz’s picture

It looks like your php configuration is not allowing to import the photo's. If you do a quick google search with the first part of that error you get lots of responses. I found this one for example http://www.learnphponline.com/errors/url-file-access-is-disabled-in-the-.... Who are you hosting with?

mwoodwar’s picture

This site is on WebEnabled, a fairly robust drupal host. If it helps at all, I'm able to import (with the feeds module) rss feeds with pictures and audio?

Mark

pwaterz’s picture

I just commit a work around. The reason it isn't work for you is because you don't have allow_url_fopen set to on, but there is another approach so this will never be an issue. I just committed a update. Download 6.x-1.2 and let me know how it goes. Thanks for being patient.

mwoodwar’s picture

Well, I uninstalled, cleared cached, reinstalled. We're making progress...I'm now getting images...am not sure where the audio should be but I don't see it? The nodes are created (when saved) but I still get:

warning: fopen() [function.fopen]: URL file-access is disabled in the server configuration in /home/clients/websites/w_make/public_html/make/sites/all/modules/contrib/npr_package/npr_api/npr_api.module on line 519.
warning: fopen(http://api.npr.org/m3u/1135811802-a56e08.m3u?orgId=1&topicId=1104&aggIds...) [function.fopen]: failed to open stream: no suitable wrapper could be found in /home/clients/websites/w_make/public_html/make/sites/all/modules/contrib/npr_package/npr_api/npr_api.module on line 519.
warning: fopen() [function.fopen]: URL file-access is disabled in the server configuration in /home/clients/websites/w_make/public_html/make/sites/all/modules/contrib/npr_package/npr_api/npr_api.module on line 519.
warning: fopen(http://api.npr.org/m3u/1135760866-50fab0.m3u?orgId=1&topicId=1091&aggIds...) [function.fopen]: failed to open stream: no suitable wrapper could be found in /home/clients/websites/w_make/public_html/make/sites/all/modules/contrib/npr_package/npr_api/npr_api.module on line 519.

pwaterz’s picture

There is no fix for the audio. You need to set allow_url_fopen=On in your php.ini or in your .htaccess

mwoodwar’s picture

Title: Doesn't recognize my api key? » YEA!!

Thanks for being so patient, I finally got it working just right...and learned a lot in the process. I appreciate the work you've done, and the help you've given

pwaterz’s picture

anytime, glad I could help. Thanks for the bug testing!

pwaterz’s picture

Status: Active » Closed (fixed)