Megatest

Diff
Login

Differences From Artifact [732291ecba]:

To Artifact [02c28bc9cb]:


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
(use spiffy uri-common intarweb spiffy-request-vars)

(root-path "/var/www")

(vhost-map `(((* any) . ,(lambda (continue)
                           (let (($ (request-vars source: 'both)))
                           (print ($ 'dat))
                           (if (equal? (uri-path (request-uri (current-request))) 
                                       '(/ "hey"))
                               (send-response body: "hey there!\n"
                                              headers: '((content-type text/plain)))
                               (continue)))))))

(start-server port: 12345)








|
|
|
|
|
|




1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
(use spiffy uri-common intarweb spiffy-request-vars)

(root-path "/var/www")

(vhost-map `(((* any) . ,(lambda (continue)
                           (let (($ (request-vars source: 'both)))
			     (print ($ 'dat))
			     (if (equal? (uri-path (request-uri (current-request))) 
					 '(/ "hey"))
				 (send-response body: "hey there!\n"
						headers: '((content-type text/plain)))
				 (continue)))))))

(start-server port: 12345)