isn't this easier?

form = crud.update(... next=request.vars.next or prev)

On Dec 16, 4:56 pm, Wes James <[email protected]> wrote:
> I have a 3 page application.  The first page has Next which is a
> submit and the controller function has and crud.update(....
> next=.....url to page2)
>
> ON the next page there is a Previous and Next.  For these I have a
> hidden input called next.  I use jquery to set input next to prev or
> next.  In the contrller function I have:
>
> if request.vars.next=="next":
>     crud.update(.... next=url to next)
> else:
>     crud.update(... next=url to prev)
>
> But the controller function seems to be called twice and when it
> starts the second pass there is no longer any request.vars.next so it
> always resorts to the "else:"
>
> Can someone explain the process that is happening in the controller -
> why there is a two pass process to this.  I'm seeing this happen with
> wingide.
>
> thx,
>
> -wes

--

You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en.


Reply via email to