X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;f=demo.lisp;h=f2f801a3252e08a1c34265624693a2f839ae94d1;hb=131b7fa77fb2a885efe336da1ae1f05753c0c313;hp=c9e7e0f9125a67e69c4060758a4ee24558af3225;hpb=cb60460c044d8e4c1270b30acd43853ef4ef8f94;p=cl-modlisp.git diff --git a/demo.lisp b/demo.lisp index c9e7e0f..f2f801a 100644 --- a/demo.lisp +++ b/demo.lisp @@ -7,15 +7,15 @@ ;;;; Programmer: Kevin M. Rosenberg ;;;; Date Started: Dec 2002 ;;;; -;;;; $Id: demo.lisp,v 1.2 2003/07/08 06:40:00 kevin Exp $ +;;;; $Id$ ;;;; ************************************************************************* (in-package #:modlisp) -(defun demo-apache-command-processor (command) - "Sample function to process an apache command" - (let ((url (header-value command "url"))) +(defun demo-modlisp-command-processor (command) + "Sample function to process an modlisp command" + (let ((url (header-value command :url))) (cond ((equal url "/fixed.lsp") (output-html-page (fixed-html-string))) @@ -30,14 +30,14 @@ (write-string " -

mod_lisp debug page

" *apache-socket*) - (write-request-counts *apache-socket*) +

mod_lisp debug page

" *modlisp-socket*) + (write-request-counts *modlisp-socket*) (write-string " -" *apache-socket*) +" *modlisp-socket*) (loop for (key . value) in command do - (format *apache-socket* "" key value)) - (write-string "
KeyValue
~a~a
" *apache-socket*)) + (format *modlisp-socket* "~a~a" key value)) + (write-string "" *modlisp-socket*)) (defun fixed-html-string () @@ -53,15 +53,15 @@ (write-string "

mod_lisp precomputed page

-

This is a precomputed string sent by mod_lisp

" *apache-socket*) - (write-request-counts *apache-socket*) - (write-string "" *apache-socket*)) +

This is a precomputed string sent by mod_lisp

" *modlisp-socket*) + (write-request-counts *modlisp-socket*) + (write-string "" *modlisp-socket*)) (defun write-request-counts (s) (format s "

Number of server requests: ~D

" - (get-number-server-requests)) + *number-server-requests*) (format s "

Number of worker requests for this socket: ~D

" - (get-number-worker-requests))) + *number-worker-requests*))