first commit
This commit is contained in:
commit
a0cbd1a511
25
server/kimage/logstyle.css
Normal file
25
server/kimage/logstyle.css
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
.c {
|
||||||
|
margin: auto;
|
||||||
|
max-width: 600px;
|
||||||
|
text-align: center;
|
||||||
|
padding: 0px 25px 25px;
|
||||||
|
background: #FFF;
|
||||||
|
box-shadow:
|
||||||
|
0px 0px 0px 5px rgba(255,255,255,0.4),
|
||||||
|
0px 4px 20px rgba(0,0,0,0.33);
|
||||||
|
-moz-border-radius: 5px;
|
||||||
|
-webkit-border-radius: 5px;
|
||||||
|
border-radius: 5px;
|
||||||
|
display: table;
|
||||||
|
position: static;
|
||||||
|
}
|
||||||
|
|
||||||
|
.p {
|
||||||
|
font-size: .9em;
|
||||||
|
padding-top: 140px;
|
||||||
|
}
|
||||||
|
a{
|
||||||
|
color: red;
|
||||||
|
font-size: .9em;
|
||||||
|
}
|
||||||
|
|
114
server/kimage/style.css
Normal file
114
server/kimage/style.css
Normal file
@ -0,0 +1,114 @@
|
|||||||
|
html, body{
|
||||||
|
padding-top: 20px;
|
||||||
|
}
|
||||||
|
body{
|
||||||
|
font-family: Verdana;
|
||||||
|
background-image: url("/stuff/tlog.jpg");
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
h1{
|
||||||
|
color: black;
|
||||||
|
font-family: fantasy;
|
||||||
|
font-style: italic;
|
||||||
|
font-variant: smallcaps;
|
||||||
|
font-size: 30pt;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
#background-image{
|
||||||
|
-webkit-filter: url(.5);
|
||||||
|
filter: url(.5);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#container
|
||||||
|
{
|
||||||
|
width: 1000px;
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
#logo
|
||||||
|
{
|
||||||
|
color: white;
|
||||||
|
text-align:center;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
.menu
|
||||||
|
{
|
||||||
|
width: 960;
|
||||||
|
margin: 20px;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
a.button {
|
||||||
|
font-weight: bold;
|
||||||
|
font: 12pt Arial
|
||||||
|
-webkit-appearance: button;
|
||||||
|
-moz-appearance: button;
|
||||||
|
appearance: button;
|
||||||
|
text-align:center;
|
||||||
|
float: left;
|
||||||
|
width:380px;
|
||||||
|
margin:10px;
|
||||||
|
background-color: #FF8000;
|
||||||
|
text-decoration: none;
|
||||||
|
color: initial;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#lfmenu
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
#cemenu
|
||||||
|
{
|
||||||
|
}
|
||||||
|
#rgmenu
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
#opisowo
|
||||||
|
{
|
||||||
|
background-color: #808080;
|
||||||
|
color: white;
|
||||||
|
text-align:center;
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
width:1000px;
|
||||||
|
height:500px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#stopa
|
||||||
|
{
|
||||||
|
clear:both;
|
||||||
|
background-color: white;
|
||||||
|
color: black;
|
||||||
|
text-align:center;
|
||||||
|
margin-left: auto;
|
||||||
|
margin-right: auto;
|
||||||
|
width:1000px;
|
||||||
|
height:20px;
|
||||||
|
}
|
||||||
|
.bladlogowania
|
||||||
|
{
|
||||||
|
margin: auto;
|
||||||
|
max-width: 600px;
|
||||||
|
text-align: center;
|
||||||
|
padding: 0px 25px 25px;
|
||||||
|
background: #FFF;
|
||||||
|
box-shadow:
|
||||||
|
0px 0px 0px 5px rgba(255,255,255,0.4),
|
||||||
|
0px 4px 20px rgba(0,0,0,0.33);
|
||||||
|
-moz-border-radius: 5px;
|
||||||
|
-webkit-border-radius: 5px;
|
||||||
|
border-radius: 5px;
|
||||||
|
display: table;
|
||||||
|
position: static;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
BIN
server/kimage/tlog.jpg
Normal file
BIN
server/kimage/tlog.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.8 MiB |
40
server/mser.go
Normal file
40
server/mser.go
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
package main
|
||||||
|
|
||||||
|
import (
|
||||||
|
|
||||||
|
"net/http"
|
||||||
|
"html/template"
|
||||||
|
|
||||||
|
)
|
||||||
|
|
||||||
|
var tpl *template.Template
|
||||||
|
|
||||||
|
func init(){
|
||||||
|
tpl = template.Must(template.ParseGlob("templates/*.html"))
|
||||||
|
}
|
||||||
|
|
||||||
|
func historiaWydatkow(w http.ResponseWriter, r *http.Request) {
|
||||||
|
tpl.ExecuteTemplate(w, "historiawydatkow.html", "Bank") //ostatnia "" w nawiasie to nazwa karty
|
||||||
|
}
|
||||||
|
|
||||||
|
func stronaGlowna(w http.ResponseWriter, r *http.Request) {
|
||||||
|
tpl.ExecuteTemplate(w, "strglowna.html", "Strona główna")
|
||||||
|
}
|
||||||
|
|
||||||
|
func zalogujSie(w http.ResponseWriter, r *http.Request) {
|
||||||
|
tpl.ExecuteTemplate(w, "logowanie.html", "Zaloguj się")
|
||||||
|
}
|
||||||
|
|
||||||
|
func bladLogowania(w http.ResponseWriter, r *http.Request) {
|
||||||
|
tpl.ExecuteTemplate(w, "bladlog.html", "Strona dla zalogowanych")
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
func main() {
|
||||||
|
http.HandleFunc("/", stronaGlowna)
|
||||||
|
http.HandleFunc("/historia", historiaWydatkow)
|
||||||
|
http.HandleFunc("/zaloguj", zalogujSie)
|
||||||
|
http.HandleFunc("/blad", bladLogowania)
|
||||||
|
http.Handle("/stuff/", http.StripPrefix("/stuff", http.FileServer(http.Dir("./kimage/"))))
|
||||||
|
http.ListenAndServe(":8075", nil)
|
||||||
|
}
|
42
server/templates/bladlog.html
Normal file
42
server/templates/bladlog.html
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
<!doctype html>
|
||||||
|
<html lang="pl">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8"/>
|
||||||
|
<meta name="viewport"
|
||||||
|
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||||
|
<title>{{.}}</title>
|
||||||
|
<link rel="stylesheet" href="/stuff/style.css">
|
||||||
|
</head>
|
||||||
|
<body>>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="containerg">
|
||||||
|
<div id="logo">
|
||||||
|
<h1>Segregator wydatków</h1>
|
||||||
|
</div>
|
||||||
|
<div id="menu">
|
||||||
|
<div id="lfmenu">
|
||||||
|
<a href="http://127.0.0.1:8075" title="Przejdz do strony głównej">Strona główna</a>
|
||||||
|
</div>
|
||||||
|
<div id="cemenu">
|
||||||
|
<a href="http://127.0.0.1:8075/historia" title="Przejdz do histori wydatków">Historia Wydatków</a>
|
||||||
|
</div>
|
||||||
|
<div id="rgmenu">
|
||||||
|
<a href="http://127.0.0.1:8075/zaloguj" title="Przejdz do logowania">LOGOWANIE</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="bladlogowania">
|
||||||
|
|
||||||
|
<h4>Strona dostępna tylko dla zalogowanych użytkowników </h4>
|
||||||
|
|
||||||
|
<form class="pure-form custom-form" onsubmit="return false;" >
|
||||||
|
<a href="http://127.0.0.1:8075/zaloguj" title="Przejdz do logowania">Przejdz do logowania</a>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
37
server/templates/historiawydatkow.html
Normal file
37
server/templates/historiawydatkow.html
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
<!doctype html>
|
||||||
|
<html lang="pl">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8"/>
|
||||||
|
<meta name="viewport"
|
||||||
|
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||||
|
<title>{{.}}</title>
|
||||||
|
<link rel="stylesheet" href="/stuff/style.css">
|
||||||
|
</head>
|
||||||
|
<body>>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="containerg">
|
||||||
|
<div id="logo">
|
||||||
|
<h1>Segregator wydatków</h1>
|
||||||
|
</div>
|
||||||
|
<div class="menu">
|
||||||
|
<div id="lfmenu">
|
||||||
|
<a href="/" class="button" title="Przejdz do strony głównej">STRONA GŁÓWNA</a>
|
||||||
|
</div>
|
||||||
|
<div id="cemenu">
|
||||||
|
<a href="/historia" class="button" title="Przejdz do histori wydatków">HISTORIA WYDATKÓW</a>
|
||||||
|
</div>
|
||||||
|
<div id="rgmenu">
|
||||||
|
<a href="/zaloguj" class="button" title="Przejdz do logowania">LOGOWANIE</a>
|
||||||
|
</div>
|
||||||
|
<div style="clear:both;"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div id="stopa">
|
||||||
|
<p>© 2019 Amadeusz Jędrzejczak. Wszelkie prawa zastrzeżone. Kontakt: amadeuszjedrzejczak@gmail.com<p>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
|
</html>
|
31
server/templates/logowanie.html
Normal file
31
server/templates/logowanie.html
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
<!doctype html>
|
||||||
|
<html lang="pl">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8"/>
|
||||||
|
<meta name="viewport"
|
||||||
|
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||||
|
<title>{{.}}</title>
|
||||||
|
<link rel="stylesheet" href="/stuff/style.css">
|
||||||
|
<link rel="stylesheet" href="/stuff/logstyle.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<div class="c">
|
||||||
|
|
||||||
|
<h2>Panel logowania </h2>
|
||||||
|
|
||||||
|
<form class="pure-form custom-form" onsubmit="return false;">
|
||||||
|
<fieldset>
|
||||||
|
<input type="email" placeholder="Email">
|
||||||
|
<input type="password" placeholder="Hasło">
|
||||||
|
|
||||||
|
<button class="pure-button">Zaloguj</button>
|
||||||
|
</fieldset>
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
43
server/templates/strglowna.html
Normal file
43
server/templates/strglowna.html
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
<!doctype html>
|
||||||
|
<html lang="pl">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8"/>
|
||||||
|
<meta name="viewport"
|
||||||
|
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="ie=edge">
|
||||||
|
<title>{{.}}</title>
|
||||||
|
<link rel="stylesheet" href="/stuff/style.css">
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
|
||||||
|
|
||||||
|
<div id="containerg">
|
||||||
|
<div id="logo">
|
||||||
|
<h1>Segregator wydatków</h1>
|
||||||
|
</div>
|
||||||
|
<div class="menu">
|
||||||
|
<div id="lfmenu">
|
||||||
|
<a href="/" class="button" title="Przejdz do strony głównej">STRONA GŁÓWNA</a>
|
||||||
|
</div>
|
||||||
|
<div id="cemenu">
|
||||||
|
<a href="/historia" class="button" title="Przejdz do histori wydatków">HISTORIA WYDATKÓW</a>
|
||||||
|
</div>
|
||||||
|
<div id="rgmenu">
|
||||||
|
<a href="/zaloguj" class="button" title="Przejdz do logowania">LOGOWANIE</a>
|
||||||
|
</div>
|
||||||
|
<div style="clear:both;"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="opisowo">
|
||||||
|
<h2>Czym jest segregator wydatków?</h2>
|
||||||
|
<p>opis</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="stopa">
|
||||||
|
<p>© 2019 Amadeusz Jędrzejczak. Wszelkie prawa zastrzeżone. Kontakt: amadeuszjedrzejczak@gmail.com<p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
Loading…
Reference in New Issue
Block a user