简体   繁体   English

剑道更改片段名称 ASP.NET MVC

[英]Kendo change snippets name ASP.NET MVC

I have a kendo editor, I use the snippets feature but I want to change the display text on it, currently it shows "HTML toevoegen" which means "Insert HTML".我有一个剑道编辑器,我使用片段功能,但我想更改其上的显示文本,目前它显示“HTML toevoegen”,意思是“插入 HTML”。 Now I want to change this to "Placeholders".现在我想将其更改为“占位符”。

它显示了什么

This is the code I already have:这是我已经拥有的代码:

<div class="div6 editor-field">
@(Html.Kendo().EditorFor(x => x.MailBodyEN)
.Name("EditorEN")
.Tools(tools => tools
            .Clear()
            .Bold()
            .Italic()
            .Underline()
            .Strikethrough()
            .JustifyLeft()
            .JustifyCenter()
            .JustifyRight()
            .JustifyFull()
            .InsertUnorderedList()
            .InsertOrderedList()
            .Outdent()
            .Indent()
            .CreateLink()
            .Unlink()
            .SubScript()
            .SuperScript()
            .TableEditing()
            .ViewHtml()
            .Formatting()
            .CleanFormatting()
            .FontName()
            .FontSize()
            .BackColor()
            .FontColor()
            .Snippets(snippets => snippets
                .Add("Aanhef", "{{AANHEF}}")
                .Add("Contactpersoon", "{{CONTACTPERSOON}}")
                .Add("Kwartaal", "{{KWARTAAL}}")
                .Add("Jaar", "{{JAAR}}")
                .Add("Declaratielink", "{{DECLARATIELINK}}")
                .Add("Slot", "{{GROET}}"))
            )
.Resizable(true))
@Html.ValidationMessageFor(x => x.MailBodyEN)
Now the problem is, online I can find the Javascript way to do it: which is the way to do it if ou made it the Javascript way, using messages. 现在的问题是,在网上我可以找到 Javascript 的方式来做到这一点:如果你使用消息将其设为 Javascript 方式,那就是这样做的方式。 I want to do it the C# way, I saw it has a.Messages method I can call: 我想用 C# 的方式来做,我看到它有一个我可以调用的.Messages 方法:

消息

But I dont know what to put between the brackets to change the text from "HTML toevoegen" to "Placeholders".但我不知道在括号之间放什么来将文本从“HTML toevoegen”更改为“Placeholders”。

So I figured it out and it works now, I dont now why I didnt think about this before.所以我想通了,它现在有效,我现在不知道为什么我以前没有考虑过这个。 but it was literally like this:但实际上是这样的: 在此处输入图像描述

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM