mirror of
https://github.com/mosbth/cimage.git
synced 2025-07-22 17:21:36 +02:00
compare deal with images leaving no json information
This commit is contained in:
@@ -32,6 +32,10 @@ input[type=text] {
|
|||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.json {
|
||||||
|
min-height: 100px;
|
||||||
|
}
|
||||||
|
|
||||||
.top {
|
.top {
|
||||||
z-index: 10;
|
z-index: 10;
|
||||||
}
|
}
|
||||||
|
@@ -60,6 +60,10 @@ window.CImage = (function(){
|
|||||||
|
|
||||||
$.getJSON(this.value + "&json", function(data) {
|
$.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;
|
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
|
// Display image in overlay
|
||||||
|
Reference in New Issue
Block a user