例子:

@{Html.Telerik().Splitter().Name("MainSplitter")
.Orientation(SplitterOrientation.Vertical)
.Panes(vPanes =>
{
vPanes.Add()
.Size("50px")
.Content(
@<text>
Epx Studio
</text>
)
vPanes.Add()
.Content(
@<text>
@{
@Html.Telerik().TabStrip()
.Items(tabstrip =>
{
tabstrip.Add()
.Text("Tab 1")
.Content(
@<text>
@RenderSection("tabOneContents", false);
</text>
);
}
}
</text>
);
})
.Render();
}

嵌套@<text>错误,错误信息Inline markup blocks (@<p>Content</p>) cannot be nested. Only one level of inline markup is allowed

MVC 引擎不允许潜逃@<Text>,@<p> ,@div,

解决方案,用帮助方法,帮助方法(helper function(是在view里定义的方法,使用如下

{Html.Telerik().Splitter().Name("MainSplitter")
.Orientation(SplitterOrientation.Vertical)
.Panes(vPanes =>
{
vPanes.Add()
.Size("50px")
.Content(
@<text>
Epx Studio
</text>
)
vPanes.Add()
.Content(
@<text>
@RenderTabStrip()
</text>
);
})
.Render();
} @helper RenderTabStrip()
{
@{Html.Telerik().TabStrip()
.Items(tabstrip =>
{
tabstrip.Add()
.Text("Tab 1")
.Content(
@<text>
@RenderSection("tabOneContents", false);
</text>
);
}
}
}

嵌套错误Inline markup blocks (@<p>Content</p>) cannot be nested. Only one level of inline markup is allowed的更多相关文章

  1. mybatis 报The content of elements must consist of well-formed character data or markup. 语法格式错误

    最近在写sql的时候 同时使用到了 >= 和 <= 之前只使用一个的时候 没有什么问题,今天同时使用到了两个,结果xml出现了The content of elements must co ...

  2. ibatis配置文件中的XML解析错误The content of elements must consist of well-formed character data or markup.

    在检查过所有的标签名都没有问题的情况下. xml中的小于号属于非法字符. SQL语句中则可能需要小于号,此时就需要用<![CDATA[  ]]>将小于号包裹,如此不会被xml解析器解析. ...

  3. Cause: org.xml.sax.SAXParseException: The content of elements must consist of well-formed character data or markup.

    Caused by: org.apache.ibatis.builder.BuilderException: Error creating document instance.  Cause: org ...

  4. ibatiS启动的异常 The content of elements must consist of well-formed character data or markup

    ibatiS启动的异常 The content of elements must consist of well-formed character data or markup 配置的动态SQL语句里 ...

  5. FreeRTOS 中断优先级嵌套错误引发HardFault异常解决(转)

      最近在使用FreeRTOS的时候,突然发现程序在运行了几分钟之后所有的任务都不再调用了,只有几个中断能正常使用,看来是系统挂掉了,连续测试了几次想找出问题,可是这个真的有点不知所措.      我 ...

  6. FreeRTOS 中断优先级嵌套错误引发HardFault异常解决

          最近在使用FreeRTOS的时候,突然发现程序在运行了几分钟之后所有的任务都不再调用了,只有几个中断能正常使用,看来是系统挂掉了,连续测试了几次想找出问题,可是这个真的有点不知所措.   ...

  7. The content of elements must consist of well-formed character data or markup

    java 中使用dom4j解析含有特殊字符的xml文件出现了如题的错误 这个时候需要在特殊字符外面加上 <![CDATA[ /6169220648+20671/1>7+-47390045& ...

  8. Mybatis 异常: The content of elements must consist of well-formed character data or markup

    原因很简单:在ibatis的配置文件中不能出现小于号(>)     <delete id="deleteByPrimaryKey" parameterType=&quo ...

  9. android switch(String)错误:Cannot switch on a value of type String for source level below 1.7

    switch语句的判断条件可以接受int,byte,char,short,不能接受其他类型只有JDK版本1.7以上才可以支持String 设置如下可解决问题:(若没有JDK1.7版,可下载一下安装)菜 ...

随机推荐

  1. sp_rename

    sp_rename 在当前数据库中更改用户创建对象的名称. 此对象可以是表.索引.列.别名数据类型或 Microsoft .NET Framework 公共语言运行时 (CLR) 用户定义类型. 更改 ...

  2. Error Domain=com.alamofire.error.serialization.response Code=-1016 "Request failed: unacceptable con

    AFHTTPSessionManager * manager = [AFHTTPSessionManager manager]; manager.responseSerializer.acceptab ...

  3. c# 过滤字符串中的重复字符

    有字符串"a,s,d,v,a,v",如果想去除其中重复的字符,怎么做? 下面是一个方法,用Hashtable来记录唯一字符,排除重复字符,仅供参考. 1.过滤方法: public ...

  4. 怎么使用git来管理项目版本?

    怎么使用git来管理项目版本和存放代码? 作者:rongfangliu 转载请注明出处:http://www.cnblogs.com/rongfangliu/p/howuseGit.html 工具: ...

  5. iOS: 实现苹果的内购

    一.介绍: 在个人开发的app上架到AppStore后,苹果官方允许我们将自己的app在appstore上进行付费使用,也就是所谓的内购.其中,支付方式规定的必须是苹果的支付方式:应用内支付. 二.流 ...

  6. dd命令使用详解

    dd命令使用详解 http://www.cnblogs.com/qq78292959/archive/2012/02/23/2364760.html 1.命令简介 dd 的主要选项: 指定数字的地方若 ...

  7. Android中的CharSequence和String

    String 类代表字符串.Java 程序中的所有字符串字面值(如 "abc" )都作为此类的实例来实现. (这个没啥了解的吧,经常用 class)public interface ...

  8. android网络编程--从网络下载图片,并保存到内存卡

    功能1:从网络上取得的图片显示到imageview上面,生成Bitmap时有两种方法,一种是先转换为byte[],再生成bitmap:一种是直接用InputStream生成bitmap.功能2:点击按 ...

  9. frame与bounds的区别

    原来你M,frame.size和bounds.size不总是一样的 在UIViewController的- (void)willAnimateRotationToInterfaceOrientatio ...

  10. UIActivityIndicatorView

    1.    activityIndicatorViewStyle 设置指示器的样式 UIActivityIndicatorViewStyleWhiteLarge UIActivityIndicator ...