mirror of
https://github.com/kataras/iris.git
synced 2026-02-05 10:15:56 +00:00
MVC Example - you can learn a lot | Asleep for your eyes (again)
Former-commit-id: cd66c00b29c903b724763cb84cae96426934acb5
This commit is contained in:
11
_examples/tutorial/mvc/views/index.html
Normal file
11
_examples/tutorial/mvc/views/index.html
Normal file
@@ -0,0 +1,11 @@
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>{{.title}}</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>{{.message}}</h1>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
17
_examples/tutorial/mvc/views/user/index.html
Normal file
17
_examples/tutorial/mvc/views/user/index.html
Normal file
@@ -0,0 +1,17 @@
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<title>{{.title}}</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1> Hello {{.username}} </h1>
|
||||
|
||||
|
||||
All fields inside a controller that are pointers or they tagged as `iris:"persistence"` are marked as persistence data, meaning
|
||||
that they will not be reset-ed on each new request.
|
||||
<h3>Persistence data from *DB.Connstring: {{.connstring}} </h3>
|
||||
<h3>Persistence data from CreatedAt `iris:"persistence"`: {{.uptime}} seconds </h3>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
Reference in New Issue
Block a user