2015-05-04 15:14:36 +00:00
|
|
|
<html>
|
|
|
|
<body>
|
2015-07-24 07:33:07 +00:00
|
|
|
<script src="../../static/jquery-2.0.3.min.js"></script>
|
2015-05-04 15:14:36 +00:00
|
|
|
<script type="text/javascript" charset="utf-8">
|
2015-11-12 10:28:04 +00:00
|
|
|
var ipcRenderer = require('electron').ipcRenderer;
|
2015-07-24 07:33:07 +00:00
|
|
|
var port = location.search.substr("?port=".length);
|
2015-05-04 15:14:36 +00:00
|
|
|
$.ajax({
|
|
|
|
type: "GET",
|
2015-07-24 07:33:07 +00:00
|
|
|
url: "http://127.0.0.1:" + port,
|
2015-05-04 15:14:36 +00:00
|
|
|
headers: {
|
|
|
|
"Authorization": "Basic " + btoa("test:test")
|
|
|
|
},
|
2015-07-24 07:33:07 +00:00
|
|
|
success: function(result) {
|
2015-11-12 10:28:04 +00:00
|
|
|
ipcRenderer.sendToHost(result);
|
2015-07-24 07:33:07 +00:00
|
|
|
},
|
|
|
|
error: function(xhr, status, error) {
|
2015-11-12 10:28:04 +00:00
|
|
|
ipcRenderer.sendToHost(error);
|
2015-07-24 07:33:07 +00:00
|
|
|
},
|
2015-05-04 15:14:36 +00:00
|
|
|
});
|
|
|
|
</script>
|
|
|
|
</body>
|
|
|
|
</html>
|