In layout.html, I have
{{response.files.append(URL(r=request,c='static',f='js/xyz.js'))}}

xyz.js contains a function abc(x){ code line1; code line 2;....

In a View, there is -->   ajax('{{=URL("salhead_edit")}}, [],
':eval');

"salhead_edit" returns js function -->  'abc(myvar1)'
But it is not evaluated in View.
(I am sure that the js file is correctly referenced in layout.html)

Note: If I directly return the "code line1; code line 2;..." from the
controller, they ARE evaluated.
But "function abc()" is not evaluated.

Is it expected behaviour of the ajax function?

Regards,
Vineet

Reply via email to