Hi All,
I am trying to execute a local (ie: defined in the template)
javascript function from an Ajax
callback. This is the callback:
def testAjax2 (theXhtml : NodeSeq) : NodeSeq =
{
def getWidth () =
{
Call ("getAvailableWidth").cmd;
}
def alert (what : String) =
{
Alert (what);
}
bind ("fgh", theXhtml, "key" -> SHtml.a (() => {alert
(getWidth ());}, Text ("Click me")));
}
The alert is displayed, but the text it shows is "getAvailableWidth
()". I have been trying dozens
of variations, but didn't get the result I am hoping for; it's always
the string...
What am I doing wrong?
--
You received this message because you are subscribed to the Google Groups
"Lift" 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/liftweb?hl=.