Created
December 15, 2011 01:09
-
-
Save totem3/1479371 to your computer and use it in GitHub Desktop.
ajaxButtonのためのSnippet
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Foo { | |
def foo(xhtml:NodeSeq):NodeSeq = { | |
bind("foo", xhtml, | |
"button" -> ajaxButton("PressMe!", //ボタンに表示される文字列 | |
()=>SetHtml("set-here", Text("FooBarBaz!")) //クリック時の処理。ここではidがset-hereのdiv要素に"FooBarBaz!"をセットする | |
) | |
) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment