mirror of
https://github.com/vbatts/imgsrv.git
synced 2024-12-25 23:36:30 +00:00
layouts: first stub of an index html page
This commit is contained in:
parent
c616327fc6
commit
dadf07877c
1 changed files with 25 additions and 0 deletions
25
layouts.go
Normal file
25
layouts.go
Normal file
|
@ -0,0 +1,25 @@
|
|||
package main
|
||||
|
||||
import (
|
||||
"html/template"
|
||||
"io"
|
||||
)
|
||||
|
||||
var index = `
|
||||
<html>
|
||||
<head>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
`
|
||||
func IndexPage(w io.Writer) (err error) {
|
||||
t, err := template.New("index").Parse(index)
|
||||
if (err != nil) {
|
||||
return err
|
||||
}
|
||||
return t.Execute(w, index)
|
||||
}
|
||||
|
Loading…
Reference in a new issue