diff --git a/contrib/cont-responder/cont-html.factor b/contrib/cont-responder/cont-html.factor index 763c385ccd..1cb00047e5 100644 --- a/contrib/cont-responder/cont-html.factor +++ b/contrib/cont-responder/cont-html.factor @@ -277,5 +277,5 @@ USE: logic "method" "action" "type" "value" "name" "size" "href" "class" "border" "rows" "cols" "id" "onclick" "style" "valign" "accesskey" - "src" "language" "colspan" + "src" "language" "colspan" "onchange" ] [ define-attribute-word ] each \ No newline at end of file diff --git a/contrib/cont-responder/cont-responder.factor b/contrib/cont-responder/cont-responder.factor index b7bf4f063c..ef35d6a7fa 100644 --- a/contrib/cont-responder/cont-responder.factor +++ b/contrib/cont-responder/cont-responder.factor @@ -40,6 +40,7 @@ USE: html USE: kernel USE: logic USE: cont-html +USE: logging : expiry-timeout ( -- timeout-seconds ) #! Number of seconds to timeout continuations in @@ -268,7 +269,7 @@ DEFER: show #! id and calls it with the POST data as an alist on the top #! of the stack. [ - read-post-request post-request>namespace swap resume-continuation + read-post-request dup log post-request>namespace swap resume-continuation ] with-exit-continuation print drop ; diff --git a/contrib/cont-responder/cont-utils.factor b/contrib/cont-responder/cont-utils.factor index 7c71403a07..8c41a02f6b 100644 --- a/contrib/cont-responder/cont-utils.factor +++ b/contrib/cont-responder/cont-utils.factor @@ -29,6 +29,8 @@ USE: cont-responder USE: lists USE: stdio USE: stack +USE: namespaces +USE: html : simple-page ( title quot -- ) #! Call the quotation, with all output going to the @@ -66,3 +68,12 @@ USE: stack : button ( label -- ) #! Output an HTML submit button with the given label. ; + +: with-simple-html-output ( quot -- ) + #! Run the quotation inside an HTML stream wrapped + #! around stdio. +
[ + "stdio" get; diff --git a/contrib/cont-responder/eval-responder.factor b/contrib/cont-responder/eval-responder.factor index 97f1d02531..f8d89b1f4c 100644 --- a/contrib/cont-responder/eval-responder.factor +++ b/contrib/cont-responder/eval-responder.factor @@ -105,15 +105,6 @@ USE: vocabularies [[ + call + ] with-stream + ]
[ - "stdio" get; - : html-for-word-source ( word-string -- ) #! Return an html fragment dispaying the source #! of the given word.[ - call - ] with-stream - ]