Skip to content
Snippets Groups Projects
Commit 94fe457e authored by root's avatar root
Browse files

* oprava stylovani

* total scale graf v megasearchi
parent c9b16f49
No related branches found
No related tags found
No related merge requests found
...@@ -10,9 +10,9 @@ ...@@ -10,9 +10,9 @@
function fetchData() { function fetchData() {
<? #TODO: fuj <? #TODO: fuj
if(!isSet($_GET['where'])) { ?> if(!isSet($_GET['where'])) { ?>
$.getJSON('graph_HostnameServiceTypeActivity.php?per=<? print $_GET['per'];?>', drawChart); $.getJSON('graph_HostnameServiceTypeActivityScale.php?per=<? print $_GET['per'];?>', drawChart);
<? } else { ?> <? } else { ?>
$.getJSON('graph_HostnameServiceTypeActivity.php?per=<? print $_GET['per'];?>&where=<?print $_GET['where'];?>', drawChart); $.getJSON('graph_HostnameServiceTypeActivityScale.php?per=<? print $_GET['per'];?>&where=<?print $_GET['where'];?>', drawChart);
<? } ?> <? } ?>
} }
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
vAxis: { logScale: true, title: "totalScale" }, vAxis: { logScale: true, title: "totalScale" },
interpolateNulls: true, interpolateNulls: true,
___colors:['#008000','#ff0000','#FFA500','#FA8072','#AFEEEE','#00A5C6','#DEBDDE','#000000'], ___colors:['#008000','#ff0000','#FFA500','#FA8072','#AFEEEE','#00A5C6','#DEBDDE','#000000'],
chartArea: {'width': '80%', 'height': '90%'}, chartArea: {'width': '80%', 'height': '85%'},
pointSize: 5 pointSize: 5
}; };
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
</script> </script>
</head> </head>
<body> <body>
<div id="chart_div" style="width: 100%; height: 95%;"></div> <div id="chart_div" style="width: 100%; height: 100%;"></div>
</body> </body>
</html> </html>
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
vAxis: { logScale: true, title: "events" }, vAxis: { logScale: true, title: "events" },
interpolateNulls: true, interpolateNulls: true,
___colors:['#008000','#ff0000','#FFA500','#FA8072','#AFEEEE','#00A5C6','#DEBDDE','#000000'], ___colors:['#008000','#ff0000','#FFA500','#FA8072','#AFEEEE','#00A5C6','#DEBDDE','#000000'],
chartArea: {'width': '80%', 'height': '90%'}, chartArea: {'width': '80%', 'height': '85%'},
pointSize: 5 pointSize: 5
}; };
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
</script> </script>
</head> </head>
<body> <body>
<div id="chart_div" style="width: 100%; height: 95%;"></div> <div id="chart_div" style="width: 100%; height: 100%;"></div>
</body> </body>
</html> </html>
...@@ -82,7 +82,6 @@ $renderer->display(); ...@@ -82,7 +82,6 @@ $renderer->display();
?> ?>
</td> </td>
<td width=50%>
<? <?
if( IsSet($_POST["btnSubmit"])) { if( IsSet($_POST["btnSubmit"])) {
...@@ -120,29 +119,50 @@ if( IsSet($_POST["btnSubmit"])) { ...@@ -120,29 +119,50 @@ if( IsSet($_POST["btnSubmit"])) {
} }
?> ?>
<td width=50%>
<? <?
if( IsSet($_POST["btnSubmit"]) and !empty($where)) { if( IsSet($_POST["btnSubmit"]) and !empty($where)) {
print("<iframe src=\"graph_HostnameServiceTypeActivity_html.php?per=day&where=".base64_encode($where)."\" style=\"width:100%; height:500\"></iframe>"); print("<iframe src=\"graph_HostnameServiceTypeActivity_html.php?per=day&where=".base64_encode($where)."\" style=\"width:100%; height:500\"></iframe>");
} }
?> ?>
</td> </td>
</tr> </tr>
</table>
<hr> <tr>
<? <td>
#TODO: strip vsechny superznaky
<?
if( IsSet($_POST["btnSubmit"]) and !empty($where)) { if( IsSet($_POST["btnSubmit"]) and !empty($where)) {
var_dump($_POST);
$q = "SELECT * FROM events WHERE $where ORDER BY detected DESC LIMIT ".$_POST['limit']; $q = "SELECT * FROM events WHERE $where ORDER BY detected DESC LIMIT ".$_POST['limit'];
$res = mysql_query($q, $db); $res = mysql_query($q, $db);
print "Query: ".json_encode($q)."<br>"; print "Query: ".json_encode($q)."<br>";
print "Found: ".mysql_num_rows($res)."<br>"; print "Found: ".mysql_num_rows($res)."<br>";
}
?>
</td>
<td width=50%>
<?
if( IsSet($_POST["btnSubmit"]) and !empty($where)) {
print("<iframe src=\"graph_HostnameServiceTypeActivityScale_html.php?per=day&where=".base64_encode($where)."\" style=\"width:100%; height:500\"></iframe>");
}
?>
</td>
</tr>
</table>
<hr>
<?
#TODO: strip vsechny superznaky
if( $res != FALSE) {
print("<pre>"); print("<pre>");
while ($tmp = mysql_fetch_assoc($res)) { while ($tmp = mysql_fetch_assoc($res)) {
#var_dump($tmp); #var_dump($tmp);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment