Hi everyone,
My random quote generator started giving this error now:
“Refused to execute script from ‘http://api.forismatic.com/api/1.0/?method=getQuote&lang=en&format=jsonp&jsonp=jQuery311003923957145428081_1492991504854&_=1492991504855’ because its MIME type (‘text/html’) is not executable, and strict MIME type checking is enabled.”
http://codepen.io/nzldeveloper/pen/rybQjj
Can someone let me know why that’s the case? it was working fine last week when I completed it.
Thank you,
Ning
I’m having the same issue. Worked perfectly until today. I have tried looking around for an answer on Google and everything indicates it’s something to do with our datatype being wrong, but I can’t figure out how to fix it (or why it would only be a problem starting today when it never had a problem before). Anyone have any ideas?
I am having the same issue at http://kaypeter.com/rqg
It seems to be an issue with response headers being sent by the forismatic api website. It goes and sends a content-type: text/html. But for most people, we use json/jsonp and the browser sees this as a mismatch.
I don’t think there is a solution unless the people at forismatic can set their content-type and/or configure their CORS
I’ve just emailed the API owner and we’ll see what happens
Just got a response back and bad news, the original API owner does not support the API anymore
Sorry to say,
Forismatic is no longer supported. At all.
Please use a different API.
Thank you for figuring this all out! I will go find another API I guess.
Thanks for tracking that down! I already switched to another api, through MASHAPE. You’ve gotta create an API key but it works. Here’s hoping the weather api still works after CodePen changes over completely to secure.
Hi fellow campers!
I just received an email from the forismatic API owner, and they stated that they fixed the issue with their content-type. I just tested it and it is working! Happy coding!
PK
Thank you! I was gna go fix it this weekend so this perfect timing haha!