Implementing a linear sequence of links is straightforward with continuations. The secret to implementing a cycle of links is to use a variation on the recipe WebDispatchOnLink. Each page is a function from request -> response. Now when we want to create a link to another page we make use of send/suspend/callback as described in WebDispatchOnLink. As all the pages are functions this circular code isn't a problem.
Here is a runnable module with three pages, where each page has links to the other two pages.
I would have liked to attach the full module (so people could download it and run it) but only include fragments of the code in the body of the page.
Next to the Edit link at the top of the page is an Attach link. Use this to attach files -- NoelWelsh
ChrisDutchyn wrote the original code.
-- DuckySherwood - 06 Apr 2006
-- NoelWelsh - 07 Apr 2006
Fixed a few things: the ParentTopic should be WebRecipes, made the title a bit more descriptive, hopefully made the text easier to understand.