#programming #Scala
scalatraのXMLリテラルを利用したコード。パラメータmsg
を表示する。
get("/hello"){
<h1>your message is '{params("msg")}'</h1>
}
シンプルだが、XML縛りで、HTML5には向かないので、素直にhtmlテンプレートエンジンを使ったほうが良さげ。
#programming #Scala
scalatraのXMLリテラルを利用したコード。パラメータmsg
を表示する。
get("/hello"){
<h1>your message is '{params("msg")}'</h1>
}
シンプルだが、XML縛りで、HTML5には向かないので、素直にhtmlテンプレートエンジンを使ったほうが良さげ。
senooken JP Social is a social network, courtesy of senooken. It runs on GNU social, version 2.0.2-beta0, available under the GNU Affero General Public License.
All senooken JP Social content and data are available under the Creative Commons Attribution 3.0 license.