web/js/site.js in update_repo-0.9.7 vs web/js/site.js in update_repo-0.9.8
- old
+ new
@@ -1,7 +1,15 @@
// Site-specific Javascript
// return the version number of the latest released Gem
-function GetGemVer () {
+function getgemver () {
// URL to the API...
- var APIUrl = 'https://rubygems.org/api/v1/versions/update_repo/latest.json'
+ var APIurl = 'https://rubygems.org/api/v1/versions/update_repo/latest.json?callback=?';
+ jQuery.getJSON( APIurl, function( data ) {
+ console.log(data);
+ jQuery("#version").text(data.version);
+ });
}
+
+jQuery(document).ready(function() {
+ getgemver();
+});