Skip to content

Instantly share code, notes, and snippets.

@divarvel
Created March 21, 2012 13:22
Show Gist options
  • Save divarvel/2146847 to your computer and use it in GitHub Desktop.
Save divarvel/2146847 to your computer and use it in GitHub Desktop.
Play2 + Bootstrap2
@(elements: helper.FieldElements)
@**************************************************
* Generate input according twitter bootsrap rules *
**************************************************@
<div class="control-group@if(elements.hasErrors) {" errors"}">
<label for="@elements.id" class="control-label">@elements.label</label>
<div class="controls">
@elements.input
<span class="help-inline">@((elements.errors ++ elements.infos).mkString(", "))</span>
</div>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment