unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* How to render raw data using sxml?
@ 2016-07-10 19:58 Jakub Jankiewicz
  2016-07-11  6:48 ` tomas
                   ` (2 more replies)
  0 siblings, 3 replies; 15+ messages in thread
From: Jakub Jankiewicz @ 2016-07-10 19:58 UTC (permalink / raw)
  To: guile-user

Hi,

I want to render scheme code inside script tag to be executed by biwascheme
in the browser so I've try to create simple page using sxml (cgi script):

(display "Content-Type: text/html")
(newline)
(newline)
(display "<!DOCTYPE html>")
(newline)
(sxml->xml `(html
              (head
                 (title "BiwaScheme test")
                 (script (@ (src "biwascheme-min.js")) "(display \"hello\")"))
              (body (p "BiwaScheme test"))))

but the output was:

<!DOCTYPE html>
<html><head><title>BiwaScheme test</title><script
src="biwascheme-min.js">(display
&quot;hello&quot;)</script></head><body><p>BiwaScheme test</p></body></html>

which is invalid scheme code. I've also try this:

(script (@ (src "biwascheme-min.js")) "(display " #\" "hello" #\" ")")

but got the same result. How can I display raw data using sxml->xml

thanks in advance
Jakub

--
Jakub Jankiewicz, Web Developer
http://jcubic.pl



^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2016-07-15 12:44 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-10 19:58 How to render raw data using sxml? Jakub Jankiewicz
2016-07-11  6:48 ` tomas
2016-07-11 20:58 ` Amirouche Boubekki
2016-07-12 20:20   ` Jakub Jankiewicz
2016-07-12 20:23     ` Jakub Jankiewicz
2016-07-13  9:57       ` tomas
2016-07-14 10:29         ` Andy Wingo
2016-07-14 10:47           ` tomas
2016-07-14 13:21           ` Matt Wette
2016-07-14 20:45             ` tomas
2016-07-15 10:40             ` Amirouche Boubekki
2016-07-15 12:44               ` Matt Wette
2016-07-13 12:28 ` Matt Wette
2016-07-13 13:36   ` tomas
2016-07-14 10:23   ` Andy Wingo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).