[plt-scheme] send/suspend/dispatch and javascript?

From: Bob McCormick (bobm at adt.com)
Date: Mon Nov 22 14:51:26 EST 2004

With send/suspend/dispatch  
<http://schemecookbook.org/view/Cookbook/WebDispatchOnLink> , is there  
anyway to include the continuation URL into the arguments to a  
javascript function?   For example, instead of the HTML output like  
this:

<a href="http://localhost/servlets/test2.ss;id58*k1-419981834">Click  
Here</a>

I'd like to be able to output something like this:

<a href="#"  
onclick="liveUpdaterUri(http://localhost/servlets/test2.ss;id58*k1 
-419981834)">Click Here</a>

But I can't get send/suspend/dispatch to expand my function name into a  
continuation url if it's within the quotes for the javascript.


BTW.. Why would I want to do something like this?   I'd like to take  
advantage of the Avi Bryants very cool liveUpdater script  
<http://www.cincomsmalltalk.com/userblogs/avi/blogView? 
showComments=true&entry=3268075684> .  For those of you who haven't  
seen it, it's a javascript that lets you replace elements of the  
current page.  The idea is to create richer, more responsive client  
interfaces by updating just those parts of the page than *need* to  
change instead of reloading the whole page.


Posted on the users mailing list.