I have a textbox where user can input html snippet
example: user input this in the field
// <![CDATA[
<tr>
<td>
#= Position #
</td>
<td>
#= Description #
</td>
<td>
#= Location #
</td>
<td>
<a href="@Url.Action("Delete")/#= Id #" class="delete-link">Delete</a>
</td>
</tr>
// ]]>
I save it to database and call it by demand in the client ui as KTemplatePart.Script (KendoUI Template)
VIEW
@Html.Script(
@<script id="jobTemplate" type="text/javascript">
@Model.KTemplatePart.Script
</script>
)
Where html.Script is an html helper
My problem is it gets deformed in the Client ui
<script id="jobTemplate" type="text/javascript" >
<![CDATA[
<tr>
<td>
#= Position #
</td>
<td>
#= Description #
</td>
<td>
#= Location #
</td>
<td>
<a href="@Url.Action("Delete")/#= Id #" class="delete-link">Delete</a>
</td>
</tr>
// ]]>
</script>
Is there a workaround on this?