0

I'm trying to create this html code:

<input id="RememberMe" type="checkbox" name="RememberMe" />
<label for="RememberMe">
<span></span>
Remmember me.
</label>

with mvc tools. So I'm wrote:

@Html.CheckBoxFor(m => m.RememberMe)
@Html.LabelFor(m => m.RememberMe)

But this not creating the element inside the label.

How I'm can use those mvc tools, without losing this span?

thank you!

Is that possible?

Daniel A. White
  • 187,200
  • 47
  • 362
  • 445
No1Lives4Ever
  • 6,430
  • 19
  • 77
  • 140
  • You can create custom HTML helper. Has already been answered here. http://stackoverflow.com/questions/5196290/how-can-i-override-the-html-labelfor-template?lq=1 – ACS Sep 30 '13 at 18:46

1 Answers1

0

you can try html raw if all you need is to have a span

@Html.Raw(m => m.RememberMe)
COLD TOLD
  • 13,513
  • 3
  • 35
  • 52