繁体   English   中英

TYPO3流体模板中的图像映射

[英]image-map in TYPO3 fluid templates

我正在用extbase和fluid为TYPO3编写扩展。 在这里,我想显示一个图像地图。 问题在于,流体引擎将我的<map>-标记及其所有<area>-标记包装在双引号中,并将它们输出到<p>-标记中。

<map></map>

变成

<p class="bodytext">    &lt;map&gt;</p>
<p class="bodytext">    &lt;/map&gt;</p>

我已经尝试过将其包装在以下视图帮助器中

<f:format.{raw,html,...}>
<![CDATA[]]>

有人以前有这个问题吗?

编辑:

<f:layout name="Default" />
This Template is responsible for creating a table of domain objects. If
you modify this template, do not forget to change the overwrite settings
in /Configuration/ExtensionBuilder/settings.yaml: Resources: Private:
Templates: List.html: keep Otherwise your changes will be overwritten
the next time you save the extension in the extension builder

<f:section name="main">
 <f:image src="{f:uri.resource(path:'Images/Basemap.png')}"
  alt="Basemap" class="map" id="map" usemap="#StateLocations" />
 <table id="test"></table>
  <f:format.raw>
   <div id="themap"></div>
  </f:format.raw>
  <f:flashMessages />
  <f:format.raw>
   <map></map>
  </f:format.raw>
 </f:section>

编辑2:

<div class="tx-myext">
 <f:render section="main" />
</div>

您可以使用f:format.html viewhelper,而无需任何parsefunc

<f:layout name="Layout" />
<f:section name="MySection">
    <f:format.html parseFuncTSPath=""><map></map></f:format.html>
</f:section>

我真的不知道为什么要包装map-tag,但是在我的测试用例中,它不需要任何parsefunction。

编辑:

<map></map> <!-- output <map></map> -->
<f:format.html parseFuncTSPath=""><map></map></f:format.html> <!-- output <map></map> -->
<f:format.html><map></map></f:format.html> <!-- output <p class="bodytext">&lt;map&gt;&lt;/map&gt;</p> -->

暂无
暂无

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

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