diff options
author | alekseiplusplus <alekseijeaves@protonmail.com> | 2024-06-30 14:48:13 +1000 |
---|---|---|
committer | alekseiplusplus <alekseijeaves@protonmail.com> | 2024-06-30 14:48:13 +1000 |
commit | d5cc926ec6c3020d2d51cacc7d14e59c558c4167 (patch) | |
tree | 7dbc071ee3ecd6c143426984c19b4c73c11a42c7 /html.tcl | |
parent | a61f03cfbf62eb006e6bd845694f18d40101d4e8 (diff) |
beginning draftwork on modules
Diffstat (limited to 'html.tcl')
-rwxr-xr-x | html.tcl | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/html.tcl b/html.tcl new file mode 100755 index 0000000..9a6a946 --- /dev/null +++ b/html.tcl @@ -0,0 +1,16 @@ + +namespace eval html { + + proc start {title} { + return "<!DOCTYPE html><html><head><title>$title</title><link rel='stylesheet' href='/style.css'></head><body>"; + } + + proc end {} { + return "</body></html>" + } + + proc link {name link} { + return "<a href=\"$link\">$name</a>" + } + +} |