在动态内容(嵌套标签)中嵌入自定义标签而不呈现。在动态内容(嵌套标签)中嵌入自定义标签而不是呈现
我有一个页面,从javabean中提取动态内容,并将对象列表传递给自定义标签以处理为html。在每个对象中都有一堆要输出的html文件,其中包含我想要呈现的另一个自定义标签。问题是标记调用呈现为明文。
一个例子可能会让我更好。
1从数据库中获取信息并通过javabean将其返回给页面。将此信息发送到自定义标签以进行输出。
这个标签应输出框格,像这样
*SNIP* class for custom tag def and method setup etc
out.println("
out.println(" " + importantNotice.getMessage());
out.println("
out.println("
out.println("
*SNIP*
这使得罚款和预期
This is a very important message. Everyone should pay attenton to it.
2如果在上面的例子,比如,我是来在importantNotice.getMessage()中有一个自定义标签字符串:
*SNIP* "This is a very important message. Everyone should pay attenton to it. Quote this" *SNIP*
重要通知呈现良好,但引号标记不会被处理,只是插入到字符串中并放置为纯文本/ html标记。
This is a very important message. Everyone should pay attenton to it. Quote this
不是
This is a very important message. Everyone should pay attenton to it.
我知道这与处理器和预处理器做,但我不肯定有关如何使这项工作。