mirror of
https://github.com/arnaucube/konstrui.git
synced 2026-02-07 19:46:40 +01:00
implemented generation of pages for each data in json
This commit is contained in:
6
example/webInput/templates/projectTemplate.html
Normal file
6
example/webInput/templates/projectTemplate.html
Normal file
@@ -0,0 +1,6 @@
|
||||
<div class="class1">
|
||||
<div id="{{idAuthor}}" class="class2">Project {{title}}</div>
|
||||
<div class="classAuthor">Developed by: {{author}}</div>
|
||||
<div class="class3">{{description}}</div>
|
||||
<a href="{{link}}" target="_blank">View project page</a>
|
||||
</div>
|
||||
33
example/webInput/templates/projectTemplate.json
Normal file
33
example/webInput/templates/projectTemplate.json
Normal file
@@ -0,0 +1,33 @@
|
||||
[{
|
||||
"title": "Smartphone App",
|
||||
"idAuthor": "author1",
|
||||
"author": "User1",
|
||||
"description": "This is the first project",
|
||||
"link": "https://github.com",
|
||||
"pageName": "smartphoneApp"
|
||||
},
|
||||
{
|
||||
"title": "Botnet",
|
||||
"idAuthor": "author2",
|
||||
"author": "User2",
|
||||
"description": "This project is a botnet",
|
||||
"link": "https://github.com",
|
||||
"pageName": "botnet"
|
||||
},
|
||||
{
|
||||
"title": "Webpage",
|
||||
"idAuthor": "author3",
|
||||
"author": "User1",
|
||||
"description": "This project is a webpage",
|
||||
"link": "https://github.com",
|
||||
"pageName": "webpage"
|
||||
},
|
||||
{
|
||||
"title": "Script",
|
||||
"idAuthor": "author4",
|
||||
"author": "User1",
|
||||
"description": "This project is a script to save time",
|
||||
"link": "https://github.com",
|
||||
"pageName": "script"
|
||||
}
|
||||
]
|
||||
5
example/webInput/templates/userTemplate.html
Normal file
5
example/webInput/templates/userTemplate.html
Normal file
@@ -0,0 +1,5 @@
|
||||
<div class="class1" id="user[[i]]">
|
||||
<div id="username[[i]]" class="class2">{{username}}</div>
|
||||
<div id="description[[i]]" class="class2">{{description}}</div>
|
||||
<div class="class2">{{phone}}</div>
|
||||
</div>
|
||||
16
example/webInput/templates/userTemplate.json
Normal file
16
example/webInput/templates/userTemplate.json
Normal file
@@ -0,0 +1,16 @@
|
||||
[{
|
||||
"username": "Michaela Doe",
|
||||
"description": "Hi, I'm here to code",
|
||||
"phone": "456456456"
|
||||
},
|
||||
{
|
||||
"username": "John Doe",
|
||||
"description": "Hi, I'm here",
|
||||
"phone": "123456789"
|
||||
},
|
||||
{
|
||||
"username": "Myself",
|
||||
"description": "How are you",
|
||||
"phone": "no phone"
|
||||
}
|
||||
]
|
||||
Reference in New Issue
Block a user