|
@ -15,14 +15,15 @@ $(document).ready(function(){ |
|
|
$("#approve").click(function() { |
|
|
$("#approve").click(function() { |
|
|
server_ip = $("#server_ip").val(); |
|
|
server_ip = $("#server_ip").val(); |
|
|
server_port = $("#server_port").val(); |
|
|
server_port = $("#server_port").val(); |
|
|
alert(server_ip + " " + server_port + ". Started!!!") |
|
|
server_protocol = $("#server_protocol").val(); |
|
|
|
|
|
alert(server_protocol + "://" + server_ip + " " + server_port + ". Started!!!") |
|
|
$("#msg").empty(); |
|
|
$("#msg").empty(); |
|
|
if (server_ip !== "" && server_ip !== null && server_port !== "" && server_port !== null) { |
|
|
if (server_ip !== "" && server_ip !== null && server_port !== "" && server_port !== null && server_protocol !== "" && server_protocol != null) { |
|
|
$("#msg").html("<font color='red'>ok!</font>"); |
|
|
$("#msg").html("<font color='red'>ok!</font>"); |
|
|
|
|
|
|
|
|
setInterval(function () { |
|
|
setInterval(function () { |
|
|
jQuery.ajax({ |
|
|
jQuery.ajax({ |
|
|
url: "http://" + server_ip + ":" + server_port + "/", |
|
|
url: server_protocol + "://" + server_ip + ":" + server_port + "/", |
|
|
type: "GET", |
|
|
type: "GET", |
|
|
|
|
|
|
|
|
contentType: "application/json; charset=utf-8", |
|
|
contentType: "application/json; charset=utf-8", |
|
@ -53,6 +54,13 @@ $(document).ready(function(){ |
|
|
<h1>Parking</h1> |
|
|
<h1>Parking</h1> |
|
|
<h3>Server Settings</h3> |
|
|
<h3>Server Settings</h3> |
|
|
<table> |
|
|
<table> |
|
|
|
|
|
<tr> |
|
|
|
|
|
<td>Server Protocol:</td> |
|
|
|
|
|
<td><select type="text" id="server_protocol"> |
|
|
|
|
|
<option value="http">http</option> |
|
|
|
|
|
<option value="https">https</option> |
|
|
|
|
|
<td> |
|
|
|
|
|
</tr> |
|
|
<tr> |
|
|
<tr> |
|
|
<td>Server IP:</td> |
|
|
<td>Server IP:</td> |
|
|
<td><input type="text" id="server_ip" placeholder="xxx.xxx.xxx.xxx"/></td> |
|
|
<td><input type="text" id="server_ip" placeholder="xxx.xxx.xxx.xxx"/></td> |
|
|