in reply to Mason: Please Wait While Generating
my $page = $m->dhandler_arg; # do sanity checking ... unless ($m->comp_exists($page)) { unless ($m->cache->get($page)) { # see if we're building it already $m->cache->set($page,'1','60 sec'); # set a flag to say we're buil +ding it $m->comp("/building_page"); # please wait page $m->flush_buffer; # flush the output # here we begin building the page $m->comp("/build_page", $page); } $m->comp("/building_page"); $m->flush_buffer; } </%init>
The building page, would spit up a simple note saying it's processing, and a meta-refresh tag so the client re-requests it in a moment. A little css/javascript can be used to add some animation to keep them amused.
(code above is untested, but should get you going in the right direction)
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Mason: Please Wait While Generating
by water (Deacon) on Jul 20, 2005 at 21:45 UTC | |
by cowboy (Friar) on Jul 21, 2005 at 16:28 UTC |