silk-gui
Version:
GUI for developers and Node OS
32 lines (31 loc) • 814 B
HTML
<html>
<head>
<script src="/bc/jquery" ></script>
<script src="/api.js" ></script>
<script type="text/javascript" >
jQuery(function($){
$("#connect").on("submit",function(e){
e.preventDefault();
var url = $(this).children("[name=url]").val();
var pass = $(this).children("[name=pass]").val();
ApplicationFork
.get("tunnelclient-auth",{url:url,pass:pass})
.then(function(result){
$("ul").append("<li>connected to "+url+" as: "+result+"</li>")
}).catch(alert);
})
})
</script>
</head>
<body>
<h1>Connect</h1>
<form id="connect" action="#" method="post" >
<input type="text" name="url" />
<input type="password" name="pass" />
<button type="submit" >Submit</button>
</form>
<ul>
</ul>
</body>
</html>