scala-template Questions
2
Solved
I am writing the function that can catch exceptions of the certain type only.
def myFunc[A <: Exception]() {
try {
println("Hello world") // or something else
} catch {
case a: A => // w...
Champignon asked 17/1, 2014 at 8:18
5
Solved
Using Play Framework 2 I've noticed the rendered Scala HTML templates don't like indented @if or @for.
So, for example, something like that:
<ul>
@for(test <- tests) {
<li>@test....
Squawk asked 4/1, 2013 at 9:46
2
I am using scala template with input helper.
The class attribute which i use applies style for the <input> tag.
How do i apply the style specific to the generated <label> tag?
@input...
Overseas asked 17/5, 2013 at 9:46
2
Solved
I am working with Play 2.0.4 and have the following form in my scala template.
@fieldGroup(field: Field, className: String = "field") = {
<div class="twipsies well @className">
<a class...
Tenor asked 16/10, 2012 at 11:35
3
In my form, I've defined a drop-down:
@select(
myForm("category_id"),
options(Category.options()),
'_label -> "Category",
'_default -> "-- Choose a Category --",
'_showConstraints -> fals...
Joyjoya asked 17/5, 2013 at 10:9
2
Solved
I am new to Scala and play 2.1 and I come from a PHP background. I am not able to print the @ symbol in HTML. I am getting the following error:
not found: value Hotmail
Here is my code:
mynam...
Ermentrude asked 3/10, 2013 at 11:6
1
Solved
I need to print some raw HTML in Scala template using newest Play Framework 2.1.1 Messages, variables, simple for loops etc. everything is working fine. But what if I need to to do some logic and p...
Iodism asked 18/4, 2013 at 20:2
4
Is there a simpler way of doing this?
$(document).ready(function () {
var jsArray = []
@if(scalaList != null) {
@for(id <- scalaList) {
jsArray.push('@id');
}
}
...
}
Shanika asked 20/3, 2013 at 10:15
1
© 2022 - 2024 — McMap. All rights reserved.