I'm trying to put a NumericTextBox into a Kendo template.
Here is the code:
<script type="text/x-kendo-template" id="clone-wizard-template">
<p>Bitte wählen Sie, wie viele Male Sie möchten <br />die Aktionsgruppe fortschreiben:
</p>
@(Html.Kendo().NumericTextBox()
.Name("custom")
.Value(10)
.ToClientTemplate())
<br />
/*some other lines*/
</script>
Which is strangely rendered into this:
<script type="text/x-kendo-template" id="clone-wizard-template">
<p>Bitte wählen Sie, wie viele Male Sie möchten <br />die Aktionsgruppe fortschreiben:
</p>
<input class="k-input" id="custom" name="custom" type="number" value="10" /><script>
jQuery(function(){jQuery("\#custom").kendoNumericTextBox({});});
<\/script>
<br />
/*some other lines*/
</script>
I cannot understand from where comes </script> tag...
I'm loading a template into a modal window by using this code:
editAktionsgruppen.kendoWindow = $("<div />").kendoWindow({
title: "Bestätigen",
resizable: false,
visable: false,
modal: true
}).html($("#clone-wizard-template").html()).data("kendoWindow");
Isn't this a correct way to input a control in the template?