0
random quote generator誰かが私にcodepenの引用を得ていない理由を教えてもらえますか?
$(document).ready(function(){
function getQuote(){
var url = "http://api.forismatic.com/api/1.0/?method=getQuote&lang=en&format=jsonp&jsonp=?";
$.getJSON(url,function(data){
$(".quote").html(data.quoteText);
});
};
$("#newQuote").on("click",function(){
getQuote();
});
});
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<div class = "container text-center">
<h3>Random Quote Generator</h3>
<p>Some of greatest quotes for thought.</p>
<div class="quoteBox">
<span class = "quote"></span><br>
<span class="auther"></span>
</div>
<button type = "submit" id = "newQuote" class ="btn btn-default">New quote</button>
</div>
codepenに、ここではなく、実行中にそれが働いています。誰かがなぜ私に教えてくれますか?