将TYPO3从v4升级到v7

时间:2017-11-18 01:45:52

标签: html typo3 typoscript typo3-6.2.x typo3-7.6.x

我已经将TYPO3从版本4.6.16升级到版本7.6.23,似乎有一个突破性的变化或其他东西,这些Typoscript-Rules不再起作用了:

tt_content.stdWrap.innerWrap.cObject {
    #100 < tt_content.stdWrap.innerWrap.cObject.default
    #100.15.value = vtwBlue
}
tt_content.stdWrap.innerWrap.cObject = CASE
tt_content.stdWrap.innerWrap.cObject {
    key.field = section_frame
    100 = TEXT
    100.value = <div class="right-column">|</div><div class="right-column-bottom"></div>
}

tt_content.stdWrap {
     innerWrap.cObject = CASE
     innerWrap.cObject {
         200 =< tt_content.stdWrap.innerWrap.cObject.default
         200.15.value = block
         200.30.value = ><div class="block-inner color-frame">|</div></div>

         210 =< tt_content.stdWrap.innerWrap.cObject.default
         210.15.value = block
         210.30.value = ><div class="block-inner color-frame-right-space">|</div></div>
    }
}

基本上我需要这个结构:

<div class="csc-default">
    ...
</div>

修改为:

<div class="block">
    <div class="block-inner color-frame">
        ...
    </div>
</div>

真正的基础是:

<div id="c1270" class="csc-default">
    <div class="tx-accordion">
      <h1>test headline</h1>
      <span class="imgr">
          <img class="rund" src="..." width="50" height="50">
      </span>
      <p class="acSeminarStart">Test Name</p>
      <div class="clear"></div>
      <p class="bodytext"></p>
      <p class="bodytext">
          <a href="...">Mehr</a>
      </p>
    </div>
</div>

结果应为'csc-default' - &gt; 'block'和另一个包装div'block-inner color-frame':

<div id="c1270" class="block">
    <div class="block-inner color-frame">
        <div class="tx-accordion">
          <h1>test headline</h1>
          <span class="imgr">
              <img class="rund" src="..." width="50" height="50">
          </span>
          <p class="acSeminarStart">Test Name</p>
          <div class="clear"></div>
          <p class="bodytext"></p>
          <p class="bodytext">
              <a href="...">Mehr</a>
          </p>
        </div>
    </div>
</div>

另一个阻止:

 <div id="c2582" class="csc-default">
    <h3>Test title</h3>
    <div class="tx-lightbox">
        <div class="lightboxImage">
            <span class="imgr" style="">
                <img class="rund" alt="Slideshow" src="..." width="300" height="240">
            </span>
        </div>
        <div class="lightboxText">
            <p class="bodytext">Test description</p>
            <span class="counter">23 Pictures</span>
            <a class="group2582 cboxElement rzslideshow" href="...">jetzt anschauen</a>
        </div>

        <a class="group2582 cboxElement rzslideshow" style="display:none;" href="..."></a>
        <a class="group2582 cboxElement rzslideshow" style="display:none;" href="..."></a>
        <div class="clear"></div>
    </div>
</div>

有了这个想要的结果:

<div id="c2582" class="block">
    <div class="block-inner color-frame">
        <h3>Test title</h3>
        <div class="tx-lightbox">
            <div class="lightboxImage">
                <span class="imgr" style="">
                    <img class="rund" alt="Slideshow" src="..." width="300" height="240">
                </span>
            </div>
            <div class="lightboxText">
                <p class="bodytext">Test description</p>
                <span class="counter">23 Pictures</span>
                <a class="group2582 cboxElement rzslideshow" href="...">jetzt anschauen</a>
            </div>
            <a class="group2582 cboxElement rzslideshow" style="display:none;" href="..."></a>
            <a class="group2582 cboxElement rzslideshow" style="display:none;" href="..."></a>
            <div class="clear"></div>
        </div>
    </div>
</div>

我不知道出了什么问题。恰好这个typoscript在TYPO3 V4.6.18中工作:(

1 个答案:

答案 0 :(得分:0)

这里是改变的Typoscript,TYPO3更新后用TYPO3 v6测试后需要什么。

    tt_content.stdWrap {
     innerWrap.cObject = CASE
     innerWrap.cObject {
         200 =< tt_content.stdWrap.innerWrap.cObject.default
         200.20.10.value = block
         200.30.cObject.default.value = ><div class="block-inner color-frame">|</div></div>

         210 =< tt_content.stdWrap.innerWrap.cObject.default
         210.20.10.value = block
         210.30.cObject.default.value = ><div class="block-inner color-frame-right-space">|</div></div>
    }
 }