-
Notifications
You must be signed in to change notification settings - Fork 0
/
details.html
42 lines (38 loc) · 1.52 KB
/
details.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Neuron Gallery</title>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="Neurons.js"></script>
<script type="text/javascript" src="util.js"></script>
<link rel="stylesheet" type="text/css" href="style_detail.css">
</head>
<body>
<div id="img-detail"></div>
<script>
$(document).ready(function(){
var ID = window.location.search.substr(1);
var res = LoadNeuronData();
var s = res.data;
var count = res.count;
s = s.replaceAll('\\', '\\\\');
var data = JSON.parse(s)
console.log(count)
console.log(data)
var features = Object.keys(data[ID]);
var value;
for(var k=0;k<features.length;k++){
value = data[ID][features[k]];
if(value=="") value = '0';
$("#img-detail").append($("<p></p>").text(features[k]+': '+value));
}
$("#img-detail").append($("<img>").attr("src",data[ID]["ImgPath"]))
var other_img_path = data[ID]["OtherImgPath"].split(';');
for(var k=0;k<other_img_path.length;k++){
$("#img-detail").append($("<img>").attr("src",other_img_path[k]));
}
})
</script>
</body>
</html>