svn path=/trunk/; revision=4
--- /dev/null
+#!/bin/zsh
+
+cat <<EOF
+<!Doctype HTML>
+
+<html>
+ <head>
+ <title>$TITLE</title>
+ <style type="text/css">
+ <!--
+
+
+ $($PAGE css)
+ -->
+ </style>
+ </head>
+ <body>
+ <div class="NAVIGATION">
+ $(NAVIGATION |sed -r 's:^([^ ]+) (.+)$:<a href="\1">\2</a>:g')
+ </div>
+ <div class="MAIN">
+ $($PAGE body)
+ </div>
+ </body>
+</html>
+EOF
--- /dev/null
+#!/bin/sh
+
+case "$1" in
+ title)
+ echo "Teilnehmende"
+ ;;
+ css)
+ ;;
+ body)
+ ;;
+esac
+
--- /dev/null
+#!/bin/sh
+
+case "$1" in
+ title)
+ echo "Kurse"
+ ;;
+ css)
+ ;;
+ body)
+ ;;
+esac
+
--- /dev/null
+#!/bin/sh
+
+case "$1" in
+ title)
+ echo "Email"
+ ;;
+ css)
+ ;;
+ body)
+ ;;
+esac
+
--- /dev/null
+#!/bin/sh
+
+case "$1" in
+ title)
+ ;;
+ css)
+ ;;
+ body)
+cat <<EOF
+Page not found or nevermore<br />
+Quoth the server: 404
+EOF
+ ;;
+esac
+
cgi_get
debug "$_GET"
+. "$_EXEC/page.sh"
--- /dev/null
+#!/bin/zsh
+
+echo "Content-Type: text/html\n\n"
+
+PAGE="$(echo "$_GET['page']" |egrep '^[a-zA-Z0-9_-]+$')"
+PAGE="${_EXEC}/ifcomponent/page_${PAGE}.sh"
+[ -x "$PAGE" ] || PAGE="${_EXEC}/ifcomponent/page_error.sh"
+
+TITLE=$($PAGE title)
+
+NAVIGATION() {
+ for each in "${_EXEC}/ifcomponent"/page_*.sh; do
+ link="$(echo "$each" |sed -r "s:^.*page_(.*)\.sh$:\1:")"
+ title="$($each title)"
+ echo "/?page=$link $title"
+ done
+}
+
+. ${_EXEC}/ifcomponent/frame.sh