简体   繁体   English

可视化Liferay Portlet

[英]Visualization out of bounds liferay portlet

I have a visualization problem when I deploy my web project on liferay portlet. 在liferay portlet上部署Web项目时,我遇到了可视化问题。 The project is displayed out of the window related to the portlet. 项目显示在与Portlet相关的窗口之外。 No error in the console. 控制台中没有错误。

edit: Visualization of my portlet . 编辑: 我的portlet的可视化 The problem is that the legend that is showed below the window of the portlet and the title Above (logic visualization of the network) i think that they must be also in that window... If I run the project for example on tomcat, i don't have problems in the visualization. 问题是,在portlet窗口下方显示的图例和上方(网络的逻辑可视化)标题,我认为它们也必须也在该窗口中……如果我在tomcat上运行该项目,例如在可视化中没有问题。

Can someone help me? 有人能帮我吗?

There's two options that can lead to this: 有两个选项可以导致此:

  • You have CSS that explicitly allows this (I doubt - you'd probably know this) 您的CSS明确允许这样做(我怀疑-您可能知道这一点)
  • You generate unbalanced HTML that messes with the DOM 您生成的不平衡HTML会与DOM混淆

Your portlet is embedded in the full portal-generated page and better generates proper HTML. 您的Portlet嵌入在门户生成的完整页面中,可以更好地生成正确的HTML。 Any unbalanced tags like 任何不平衡的标签,例如

<div>
    something
  </div>
</div> <!-- note: 2 closing divs, only 1 opening -->

will mess up the DOM and with it the visualization of your page. 会弄乱DOM以及页面的可视化。 When you state that you don't have this problem "when running on tomcat", I'm assuming that you mean that you're running outside of a portal, eg as a servlet. 当您声明“在tomcat上运行时”没有此问题时,我假设您的意思是您正在门户网站之外运行,例如作为servlet。 A servlet doesn't generate all the "containing" HTML and is typically more forgiving of that kind of HTML. servlet不会生成所有“包含”的HTML,通常更宽容此类HTML。

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

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