Hi Anthony, 
I used the code which you have suggested but it's not working at all, it is 
not calling record_config() function of controller.

<input value="Save" type="button" name="save_button" 
   onClick='window.location="{{=URL('default', 'record_config') + '/'}}" + 
jQuery('input[name=name_text_field]').val();'>


second point is if the above approach is successful then how would I 
retrieve the value in controller side:

def record_config():
     print 'inside record_config' 
     print request.input['name']

Do I need to use Input list to retrieve the value? OR is there any other 
way to retrieve?


On Wednesday, 29 August 2012 19:50:15 UTC+5:30, Anthony wrote:
>
> <Button type="button" name ="seeting_button"
>> onclick = 'window.location="{{=URL('default', 'record_config', 
>> args=[name_text_field.value])}}";'>
>>
>
> You cannot refer to name_text_field the way you have. Everything inside 
> {{..}} is Python and must be available on the server before the HTML is 
> rendered and sent to the browser. The input field value is available on the 
> client side and must be retrieved via Javascript. You could do:
>
> onclick='window.location="{{=URL('default', 'record_config') + '/'}}" + 
> jQuery('input[name=name_text_field]').val();'
>
> Anthony 
>

-- 



Reply via email to