[web2py] Re: present a wait page to user

2010-10-20 Thread Wikus van de Merwe
There are two options. First is HTML refresh: meta http-equiv=refresh content=5 / which will request your page every 5s and then you show either please wait message or the results of the background processing if it's finished. Second is Javascript + AJAX asynchronous poll, see the examples in the

[web2py] Re: present a wait page to user

2010-10-20 Thread meland
Hi Jason, Thank you for your reply. I think I have tried something similar to your suggestion. The user clicks a link to advance to the wait page from a page I'll call first page... {{extend 'layout.html'}} h3You are playing as a responder in this game.../h3 ul li{{=A(B(T(Click to enter

Re: [web2py] Re: present a wait page to user

2010-10-20 Thread Jason Brower
Let's start with your database query... it should not be in your view. That will help... What you do it you can have a page that is queried with .load (it's ajax jquery stuff)... it will query a page for you every second or so if you use the right kind of js. When the page your looking at every

[web2py] Re: present a wait page to user

2010-10-20 Thread meland
Hi Jason, Thanks for the reply. I think I have tried something similar to your suggestion. From a first page click a link that directs to the wait page... {{extend 'layout.html'}} h3You are playing as a responder in this game.../h3 ul li{{=A(B(T(Click to enter game)),

[web2py] Re: present a wait page to user

2010-10-20 Thread meland
Oh... having the database query in the view was not my first choice :) I originally had it a controller (where it belongs) but the corresponding page would not display until the controller function (the query) completed. I thought if I placed the code in the view, the wait message would display

[web2py] Re: present a wait page to user

2010-10-20 Thread meland
Thanks for the references, Wikus. I will review those as you suggested. Cheers... Mike On Oct 20, 10:02 am, Wikus van de Merwe dupakrop...@googlemail.com wrote: There are two options. First is HTML refresh: meta http-equiv=refresh content=5 / which will request your page every 5s and then