diff options
author | lns <matzeton@googlemail.com> | 2021-10-21 14:52:26 +0200 |
---|---|---|
committer | lns <matzeton@googlemail.com> | 2021-10-21 14:59:00 +0200 |
commit | 9266070e51422a71566ee5c04db42feec996c485 (patch) | |
tree | 4ff57de8bfce87bde001c80c7ab9fae3080aa248 /wwwroot | |
parent | 384724a00be9dbb8f40d295f99b9c6bcfb48b387 (diff) |
Improved URI handling and redirection/routing.
* parse and process URI query strings
* remove garbage slashes from URI path / sanitize
* more template examples
Signed-off-by: lns <matzeton@googlemail.com>
Diffstat (limited to 'wwwroot')
-rw-r--r-- | wwwroot/blog/index.html | 27 | ||||
-rw-r--r-- | wwwroot/index.html | 27 | ||||
-rw-r--r-- | wwwroot/index.tmpl | 1 |
3 files changed, 29 insertions, 26 deletions
diff --git a/wwwroot/blog/index.html b/wwwroot/blog/index.html new file mode 100644 index 0000000..554a952 --- /dev/null +++ b/wwwroot/blog/index.html @@ -0,0 +1,27 @@ +<html><body> +<p> +<b>blabla</b> +Test fn....: <b>{{ test_fn }}</b><br> +Test RetFN.: <b>{{ test_return_true }}</b><br><br><br> +{% if exists("blog_listing") and length(blog_listing) > 0 %} +<table> +## for entry in blog_listing + <tr> + <td>{{ loop.index1 }}</td> + <td>{{ entry.content_filename }}</td> + <td>{{ entry.title }}</td> + <td>{{ entry.tags }}</td> + <td>{{ entry.author }}</td> + <td>{{ entry.createDate }}</td> + <td>{{ entry.publishDate }}</td> + <td>{{ entry.published }}</td> + <td> + {{ indent(entry.content, 12, false, false) }} + </td> + <td>{% if loop.is_last == false %}more{% else %}eof{% endif %}<br> + </tr> +## endfor +</table> +{% endif %} +</p> +</body></html> diff --git a/wwwroot/index.html b/wwwroot/index.html index 554a952..9b05eee 100644 --- a/wwwroot/index.html +++ b/wwwroot/index.html @@ -1,27 +1,4 @@ <html><body> -<p> -<b>blabla</b> -Test fn....: <b>{{ test_fn }}</b><br> -Test RetFN.: <b>{{ test_return_true }}</b><br><br><br> -{% if exists("blog_listing") and length(blog_listing) > 0 %} -<table> -## for entry in blog_listing - <tr> - <td>{{ loop.index1 }}</td> - <td>{{ entry.content_filename }}</td> - <td>{{ entry.title }}</td> - <td>{{ entry.tags }}</td> - <td>{{ entry.author }}</td> - <td>{{ entry.createDate }}</td> - <td>{{ entry.publishDate }}</td> - <td>{{ entry.published }}</td> - <td> - {{ indent(entry.content, 12, false, false) }} - </td> - <td>{% if loop.is_last == false %}more{% else %}eof{% endif %}<br> - </tr> -## endfor -</table> -{% endif %} -</p> + <b>INDEX TMPL</b> + {{ content }} </body></html> diff --git a/wwwroot/index.tmpl b/wwwroot/index.tmpl deleted file mode 100644 index b42f18c..0000000 --- a/wwwroot/index.tmpl +++ /dev/null @@ -1 +0,0 @@ -<html><body><b>INDEX TMPL</b></body></html> |