YES!

JAvascript function

eventDrop: function(event, delta, revertFunc) {
                if (!confirm("Sei sicuro di fare questa modifica?")) {
                      revertFunc();
                 }
                else
                {
                    var value = 23;
                    ajax('{{=URL('default', 'test')}}', ['value'], '');
                }
            },


controller
def test():
    valore = request.vars.value
    print valore
    redirect(URL('index'))

It's only a test....not working I don't have inside 'valore' nothing

Il giorno lunedì 13 febbraio 2017 20:47:20 UTC+1, Dave S ha scritto:
>
>
>
> On Monday, February 13, 2017 at 11:13:17 AM UTC-8, Andrea Fae' wrote:
>>
>> I saw....not working
>>
>
> Can you show your code?  ESP is a very inefficient way to debug, and my 
> tarot cards are wet from the weekend rains.
>
> I have one example (I use LOAD for a couple other examples), and if I have 
> hname in the var list, it shows up in the controller as request.vars.hname.
>
> /dps
>
>  
>
>> Il giorno lunedì 13 febbraio 2017 17:34:50 UTC+1, Anthony ha scritto:
>>>
>>> Ajax. See http://web2py.com/books/default/chapter/29/11/jquery-and-ajax.
>>>
>>>
>>> On Monday, February 13, 2017 at 11:24:02 AM UTC-5, Andrea Fae' wrote:
>>>>
>>>> How to pass variables from a view to a controller?
>>>> Ho to pass variables from a Javascript included in a view to a 
>>>> controller?
>>>> Thanks
>>>>
>>>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to