summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/rhimportd/uploadWeb.go2
-rw-r--r--web-static/jquery.min.js (renamed from test/jquery.min.js)0
-rw-r--r--web-static/socket.html (renamed from test/socket.html)20
-rw-r--r--web-static/upload-form.html29
4 files changed, 27 insertions, 24 deletions
diff --git a/src/rhimportd/uploadWeb.go b/src/rhimportd/uploadWeb.go
index 6d6e56e..1c53fbc 100644
--- a/src/rhimportd/uploadWeb.go
+++ b/src/rhimportd/uploadWeb.go
@@ -94,7 +94,7 @@ func webUploadHandler(conf *rhimport.Config, db *rddb.DBChan, sessions *rhimport
return
}
if password == "" {
- webUploadErrorResponse(w, http.StatusBadRequest, "missing field LOGIN_NAME")
+ webUploadErrorResponse(w, http.StatusBadRequest, "missing field PASSWORD")
return
}
diff --git a/test/jquery.min.js b/web-static/jquery.min.js
index f2e82ed..f2e82ed 100644
--- a/test/jquery.min.js
+++ b/web-static/jquery.min.js
diff --git a/test/socket.html b/web-static/socket.html
index c179456..fda00e9 100644
--- a/test/socket.html
+++ b/web-static/socket.html
@@ -1,7 +1,7 @@
<!DOCTYPE HTML>
<html>
<head>
- <title>rhimportd - Testclient</title>
+ <title>rhimportd Websocket Testclient</title>
<meta charset="utf-8">
<style type="text/css">
body {
@@ -131,21 +131,21 @@
</head>
<body onload="init()">
- <h1>Radio Helsinki Rivendell Importer:</h1>
+ <h1>rhimportd Websocket Testclient</h1>
- <p>
+ <div>
<table>
- <tr><td>Username</td><td><input id="username" type="text" size="20" value="heslinki"></td></tr>
- <tr><td>Token</td><td><input id="token" type="text" size="20"></td></tr>
+ <tr><td>Username</td><td><input id="username" type="text" size="20" value="heslinki" /></td></tr>
+ <tr><td>Token</td><td><input id="token" type="text" size="20" /></td></tr>
</table>
- </p>
+ </div>
- <p>
+ <div>
<button id="buttonlist" onclick="list()">list</button>
<div id="listmsg" class="data"></div>
- </p>
+ </div>
- <p>
+ <div>
<input id="source" type="text" size="30" value="fake://10000">
<input id="refid" type="text" size="15" value="test-reference-id">
<button id="buttonrun" onclick="run()">start</button>
@@ -154,6 +154,6 @@
<button id="buttonreconnect" onclick="reconnect()">reconnect</button>
<button id="buttoncancel" onclick="cancel()">cancel</button>
<div id="rawmsg" class="data"></div>
- </p>
+ </div>
</body>
</html>
diff --git a/web-static/upload-form.html b/web-static/upload-form.html
index 8d41a6e..8910a37 100644
--- a/web-static/upload-form.html
+++ b/web-static/upload-form.html
@@ -3,23 +3,26 @@
<head>
<meta charset="utf-8">
<title>rhimportd File Upload</title>
+ <style type="text/css">
+ body {
+ background-color: #555;
+ }
+
+ td.label {
+ text-align: right;
+ }
+ </style>
</head>
<body>
<div class="container">
<h1>rhimportd File Upload</h1>
- <form class="form-upload" method="post" action="https://import.helsinki.at/upload" enctype="multipart/form-data">
- <fieldset>
- <label for="LOGIN_NAME">Username:</label>
- <input type="text" name="LOGIN_NAME">
- </br>
- <label for="LOGIN_NAME">Password:</label>
- <input type="password" name="PASSWORD">
- </br>
- <label for="FILENAME">File:</label>
- <input type="file" name="FILENAME">
- </br>
- <input type="submit" name="submit" value="Submit">
- </fieldset>
+ <form class="form-upload" method="post" action="/public/upload" enctype="multipart/form-data">
+ <table>
+ <tr><td class="label">Username</td><td><input type="text" name="LOGIN_NAME" size="20" value="heslinki" /></td></tr>
+ <tr><td class="label">Token</td><td><input type="password" name="PASSWORD" size="20" /></td></tr>
+ <tr><td class="label">File</td><td><input type="file" name="FILENAME" /></td></tr>
+ <tr><td>&nbsp;</td><td><input type="submit" name="submit" value="Submit"></td></tr>
+ </table>
</form>
</div>
</body>