Re: [web2py] Re: vars passed to LOAD become strings

2011-12-06 Thread Anthony Bastardi
> > One question related to the A() callback. > > Defining a and adding a target="some_id" to > the A works very well. > > I tried to do session.flash/response.flash inside the callback > function but it didn't work. Is there a way to do it? > > def callback_function(): >it does some stuff...

[web2py] Re: vars passed to LOAD become strings

2011-12-06 Thread thodoris
One question related to the A() callback. Defining a and adding a target="some_id" to the A works very well. I tried to do session.flash/response.flash inside the callback function but it didn't work. Is there a way to do it? def callback_function(): it does some stuff... if s == "1":

[web2py] Re: vars passed to LOAD become strings

2011-12-06 Thread Anthony
On Dec 6, 9:49 am, thodoris wrote: > I didn't know about the callback argument. Thanks a lot for the tip. > In the above case then it is not necessary then. > I was going to use something quite complicated for something simple. > Is it possible for the callback to affect multiple fields, or else >

[web2py] Re: vars passed to LOAD become strings

2011-12-06 Thread thodoris
I didn't know about the callback argument. Thanks a lot for the tip. In the above case then it is not necessary then. I was going to use something quite complicated for something simple. Is it possible for the callback to affect multiple fields, or else what happens if there are fields with the sam

[web2py] Re: vars passed to LOAD become strings

2011-12-06 Thread Anthony
> {{=A("Like", _href=URL('default', 'like', extension=False))}} > > which is a function in another controller ('default') that changes the > value of 'like' (is a field of table like {{=table.key}} in the above > example) > How do i trigger the refresh of the div? The example in the book has a > su

[web2py] Re: vars passed to LOAD become strings

2011-12-06 Thread Anthony
> >   {{=type(table)}} >   {{=table.key}} > Why are you using LOAD at all. If all the LOAD component is doing is creating a single div that contains information from the only thing you pass to the component, why not just do that directly in your for loop in the index.html view: {{for table in m

[web2py] Re: vars passed to LOAD become strings

2011-12-06 Thread thodoris
There is the solution to pass the table.id as an argument and then make an additional query to the database in tables_info to get the table but i don't like this solution because i already have the row from a previous query. An extra question, now in the div i present inside index {{=type(tabl