diff --git a/webroot/compare/compare.php b/webroot/compare/compare.php index 98c078a..f52ea55 100644 --- a/webroot/compare/compare.php +++ b/webroot/compare/compare.php @@ -32,6 +32,10 @@ input[type=text] { background-color: #fff; } +.json { + min-height: 100px; +} + .top { z-index: 10; } diff --git a/webroot/js/cimage.js b/webroot/js/cimage.js index 6aa2b7b..8d736e0 100644 --- a/webroot/js/cimage.js +++ b/webroot/js/cimage.js @@ -60,7 +60,11 @@ window.CImage = (function(){ $.getJSON(this.value + "&json", function(data) { json.innerHTML = "filename: " + data.filename + "\ncolors: " + data.colors + "\nsize: " + data.size + "\nwidth: " + data.width + "\nheigh: " + data.height + "\naspect-ratio: " + data.aspectRatio; - }); + }) + .fail(function() { + json.innerHTML = "Details not available." + console.log( "JSON error" ); + }); // Display image in overlay button.removeAttribute("disabled");